Merge pull request #12712 from Dentomologist/remove_defined_out_code

Remove defined-out code
This commit is contained in:
Tilka 2024-10-19 19:36:19 +01:00 committed by GitHub
commit fed8220c39
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 1 additions and 116 deletions

View File

@ -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)

View File

@ -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");

View File

@ -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;
}

View File

@ -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;

View File

@ -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));

View File

@ -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)

View File

@ -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.