diff --git a/src/core/dma.h b/src/core/dma.h index 80c0c5863..63109cc95 100644 --- a/src/core/dma.h +++ b/src/core/dma.h @@ -94,7 +94,7 @@ private: struct ChannelState { std::unique_ptr transfer_event; - u32 base_address; + u32 base_address = 0; union BlockControl { @@ -113,7 +113,7 @@ private: u32 GetBlockSize() const { return (block_size == 0) ? 0x10000 : block_size; } u32 GetBlockCount() const { return (block_count == 0) ? 0x10000 : block_count; } } request; - } block_control; + } block_control = {}; union ChannelControl { @@ -128,12 +128,12 @@ private: BitField start_trigger; static constexpr u32 WRITE_MASK = 0b01110001'01110111'00000111'00000011; - } channel_control; + } channel_control = {}; bool request = false; }; - std::array m_state = {}; + std::array m_state; union DPCR { @@ -161,7 +161,7 @@ private: { return ConvertToBoolUnchecked((bits >> (static_cast(channel) * 4 + 3)) & u32(1)); } - } m_DPCR; + } m_DPCR = {}; static constexpr u32 DICR_WRITE_MASK = 0b00000000'11111111'10000000'00111111; static constexpr u32 DICR_RESET_MASK = 0b01111111'00000000'00000000'00000000; diff --git a/src/core/spu.h b/src/core/spu.h index 4eb5130f5..8ac653d8a 100644 --- a/src/core/spu.h +++ b/src/core/spu.h @@ -290,7 +290,7 @@ private: System* m_system = nullptr; DMA* m_dma = nullptr; InterruptController* m_interrupt_controller = nullptr; - std::unique_ptr m_sample_event = nullptr; + std::unique_ptr m_sample_event; SPUCNT m_SPUCNT = {}; SPUSTAT m_SPUSTAT = {}; diff --git a/src/core/timers.h b/src/core/timers.h index ace159a91..2d05af747 100644 --- a/src/core/timers.h +++ b/src/core/timers.h @@ -86,7 +86,7 @@ private: System* m_system = nullptr; InterruptController* m_interrupt_controller = nullptr; GPU* m_gpu = nullptr; - std::unique_ptr m_sysclk_event = nullptr; + std::unique_ptr m_sysclk_event; std::array m_states{}; u32 m_sysclk_div_8_carry = 0; // partial ticks for timer 3 with sysclk/8