summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorTilka <tilkax@gmail.com>2024-10-19 19:36:19 +0100
committerGitHub <noreply@github.com>2024-10-19 19:36:19 +0100
commitfed8220c39f58d7e50f6abf15002a46da77f45af (patch)
tree7e05b39b94761c371f32022c5f4e88b056221f37 /Source/Core
parent88cf25e9156e9bf47e6bb25f82baf362ec41d256 (diff)
parentdbaa844e576acb48168d36d81fb4ca1e4a96d0b2 (diff)
Merge pull request #12712 from Dentomologist/remove_defined_out_code
Remove defined-out code
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Core/HW/DSPHLE/UCodes/AX.cpp7
-rw-r--r--Source/Core/Core/HW/Sram.cpp27
-rw-r--r--Source/Core/Core/HW/WiimoteReal/IOWin.cpp44
-rw-r--r--Source/Core/Core/HW/WiimoteReal/IOWin.h1
-rw-r--r--Source/Core/Core/PowerPC/Jit64/JitAsm.cpp7
-rw-r--r--Source/Core/VideoCommon/TextureDecoder_Generic.cpp18
-rw-r--r--Source/Core/VideoCommon/VertexManagerBase.cpp13
7 files changed, 1 insertions, 116 deletions
diff --git a/Source/Core/Core/HW/DSPHLE/UCodes/AX.cpp b/Source/Core/Core/HW/DSPHLE/UCodes/AX.cpp
index 426a0517d0..f82abf5d23 100644
--- a/Source/Core/Core/HW/DSPHLE/UCodes/AX.cpp
+++ b/Source/Core/Core/HW/DSPHLE/UCodes/AX.cpp
@@ -119,13 +119,6 @@ void AXUCode::HandleCommandList()
u32 pb_addr = 0;
-#if 0
- INFO_LOG_FMT(DSPHLE, "Command list:");
- for (u32 i = 0; m_cmdlist[i] != CMD_END; ++i)
- INFO_LOG_FMT(DSPHLE, "{:04x}", m_cmdlist[i]);
- INFO_LOG_FMT(DSPHLE, "-------------");
-#endif
-
u32 curr_idx = 0;
bool end = false;
while (!end)
diff --git a/Source/Core/Core/HW/Sram.cpp b/Source/Core/Core/HW/Sram.cpp
index b177ed6443..db3013465f 100644
--- a/Source/Core/Core/HW/Sram.cpp
+++ b/Source/Core/Core/HW/Sram.cpp
@@ -30,33 +30,6 @@ const Sram sram_dump = {Common::BigEndianValue<u32>{0},
{}}};
// clang-format on
-#if 0
-// german
-const SRAM sram_dump_german = {{
- 0x1F, 0x66,
- 0xE0, 0x96,
- 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00,
- 0x04, 0xEA, 0x19, 0x40,
- 0x00,
- 0x00,
- 0x01,
- 0x3C,
- 0x12, 0xD5, 0xEA, 0xD3, 0x00, 0xFA, 0x2D, 0x33, 0x13, 0x41, 0x26, 0x03,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00,
- 0x00, 0x00,
- 0x00, 0x00,
- 0x00, 0x00,
- 0x00,
- 0x00,
- 0x84, 0xFF,
- 0x00, 0x00,
- 0x00, 0x00
-}};
-#endif
-
void InitSRAM(Sram* sram, const std::string& filename)
{
File::IOFile file(filename, "rb");
diff --git a/Source/Core/Core/HW/WiimoteReal/IOWin.cpp b/Source/Core/Core/HW/WiimoteReal/IOWin.cpp
index 4cc4122dd5..aba73dfc3a 100644
--- a/Source/Core/Core/HW/WiimoteReal/IOWin.cpp
+++ b/Source/Core/Core/HW/WiimoteReal/IOWin.cpp
@@ -497,17 +497,6 @@ WiimoteScannerWindows::WiimoteScannerWindows()
init_lib();
}
-WiimoteScannerWindows::~WiimoteScannerWindows()
-{
-// TODO: what do we want here?
-#if 0
- ProcessWiimotes(false, [](HANDLE, BLUETOOTH_RADIO_INFO&, BLUETOOTH_DEVICE_INFO_STRUCT& btdi)
- {
- RemoveWiimote(btdi);
- });
-#endif
-}
-
void WiimoteScannerWindows::Update()
{
if (!s_loaded_ok)
@@ -637,39 +626,6 @@ bool WiimoteWindows::ConnectInternal()
return false;
}
-#if 0
- TCHAR name[128] = {};
- pHidD_GetProductString(dev_handle, name, 128);
-
- if (!IsValidBluetoothName(TStrToUTF8(name)))
- {
- CloseHandle(dev_handle);
- dev_handle = 0;
- return false;
- }
-#endif
-
-#if 0
- HIDD_ATTRIBUTES attr;
- attr.Size = sizeof(attr);
- if (!pHidD_GetAttributes(dev_handle, &attr))
- {
- CloseHandle(dev_handle);
- dev_handle = 0;
- return false;
- }
-#endif
-
- // TODO: thread isn't started here now, do this elsewhere
- // This isn't as drastic as it sounds, since the process in which the threads
- // reside is normal priority. Needed for keeping audio reports at a decent rate
- /*
- if (!SetThreadPriority(m_wiimote_thread.native_handle(), THREAD_PRIORITY_TIME_CRITICAL))
- {
- ERROR_LOG_FMT(WIIMOTE, "Failed to set Wiimote thread priority");
- }
- */
-
return true;
}
diff --git a/Source/Core/Core/HW/WiimoteReal/IOWin.h b/Source/Core/Core/HW/WiimoteReal/IOWin.h
index dd8be06ed2..a24667256c 100644
--- a/Source/Core/Core/HW/WiimoteReal/IOWin.h
+++ b/Source/Core/Core/HW/WiimoteReal/IOWin.h
@@ -47,7 +47,6 @@ class WiimoteScannerWindows final : public WiimoteScannerBackend
{
public:
WiimoteScannerWindows();
- ~WiimoteScannerWindows() override;
bool IsReady() const override;
void FindWiimotes(std::vector<Wiimote*>&, Wiimote*&) override;
void Update() override;
diff --git a/Source/Core/Core/PowerPC/Jit64/JitAsm.cpp b/Source/Core/Core/PowerPC/Jit64/JitAsm.cpp
index e5afb50e07..29841d1ada 100644
--- a/Source/Core/Core/PowerPC/Jit64/JitAsm.cpp
+++ b/Source/Core/Core/PowerPC/Jit64/JitAsm.cpp
@@ -81,13 +81,6 @@ void Jit64AsmRoutineManager::Generate()
dispatcher_mispredicted_blr = GetCodePtr();
AND(32, PPCSTATE(pc), Imm32(0xFFFFFFFC));
-#if 0 // debug mispredicts
- MOV(32, R(ABI_PARAM1), MDisp(RSP, 8)); // guessed_pc
- ABI_PushRegistersAndAdjustStack(1 << RSCRATCH2, 0);
- CALL(reinterpret_cast<void *>(&ReportMispredict));
- ABI_PopRegistersAndAdjustStack(1 << RSCRATCH2, 0);
-#endif
-
ResetStack(*this);
SUB(32, PPCSTATE(downcount), R(RSCRATCH2));
diff --git a/Source/Core/VideoCommon/TextureDecoder_Generic.cpp b/Source/Core/VideoCommon/TextureDecoder_Generic.cpp
index 46a2252b7d..8b70faee50 100644
--- a/Source/Core/VideoCommon/TextureDecoder_Generic.cpp
+++ b/Source/Core/VideoCommon/TextureDecoder_Generic.cpp
@@ -115,30 +115,14 @@ static inline void DecodeBytes_IA4(u32* dst, const u8* src)
static inline void DecodeBytes_RGB5A3(u32* dst, const u16* src)
{
-#if 0
for (int x = 0; x < 4; x++)
dst[x] = DecodePixel_RGB5A3(Common::swap16(src[x]));
-#else
- dst[0] = DecodePixel_RGB5A3(Common::swap16(src[0]));
- dst[1] = DecodePixel_RGB5A3(Common::swap16(src[1]));
- dst[2] = DecodePixel_RGB5A3(Common::swap16(src[2]));
- dst[3] = DecodePixel_RGB5A3(Common::swap16(src[3]));
-#endif
}
static inline void DecodeBytes_RGBA8(u32* dst, const u16* src, const u16* src2)
{
-#if 0
for (int x = 0; x < 4; x++)
- {
- dst[x] = ((src[x] & 0xFF) << 24) | ((src[x] & 0xFF00)>>8) | (src2[x] << 8);
- }
-#else
- dst[0] = ((src[0] & 0xFF) << 24) | ((src[0] & 0xFF00) >> 8) | (src2[0] << 8);
- dst[1] = ((src[1] & 0xFF) << 24) | ((src[1] & 0xFF00) >> 8) | (src2[1] << 8);
- dst[2] = ((src[2] & 0xFF) << 24) | ((src[2] & 0xFF00) >> 8) | (src2[2] << 8);
- dst[3] = ((src[3] & 0xFF) << 24) | ((src[3] & 0xFF00) >> 8) | (src2[3] << 8);
-#endif
+ dst[x] = ((src[x] & 0xFF) << 24) | ((src[x] & 0xFF00) >> 8) | (src2[x] << 8);
}
static void DecodeDXTBlock(u32* dst, const DXTBlock* src, int pitch)
diff --git a/Source/Core/VideoCommon/VertexManagerBase.cpp b/Source/Core/VideoCommon/VertexManagerBase.cpp
index b08e413e24..b53cb3d2ed 100644
--- a/Source/Core/VideoCommon/VertexManagerBase.cpp
+++ b/Source/Core/VideoCommon/VertexManagerBase.cpp
@@ -1051,19 +1051,6 @@ void VertexManagerBase::OnEndFrame()
}
}
-#if 0
- {
- std::ostringstream ss;
- std::for_each(m_cpu_accesses_this_frame.begin(), m_cpu_accesses_this_frame.end(), [&ss](u32 idx) { ss << idx << ","; });
- WARN_LOG_FMT(VIDEO, "CPU EFB accesses in last frame: {}", ss.str());
- }
- {
- std::ostringstream ss;
- std::for_each(m_scheduled_command_buffer_kicks.begin(), m_scheduled_command_buffer_kicks.end(), [&ss](u32 idx) { ss << idx << ","; });
- WARN_LOG_FMT(VIDEO, "Scheduled command buffer kicks: {}", ss.str());
- }
-#endif
-
m_cpu_accesses_this_frame.clear();
// We invalidate the pipeline object at the start of the frame.