diff --git a/src/Cafe/Account/Account.cpp b/src/Cafe/Account/Account.cpp index d022b604e..f3f11c3af 100644 --- a/src/Cafe/Account/Account.cpp +++ b/src/Cafe/Account/Account.cpp @@ -14,7 +14,6 @@ std::vector Account::s_account_list; Account::Account(uint32 persistent_id) : m_persistent_id(persistent_id) {} - typedef struct { uint32be high; diff --git a/src/Cafe/CafeSystem.cpp b/src/Cafe/CafeSystem.cpp index 30dab1d43..be58f3e8c 100644 --- a/src/Cafe/CafeSystem.cpp +++ b/src/Cafe/CafeSystem.cpp @@ -437,7 +437,6 @@ namespace CafeSystem GameInfo2 sGameInfo_ForegroundTitle; - static void _CheckForWine() { #if BOOST_OS_WINDOWS diff --git a/src/Cafe/Filesystem/FST/fstUtil.h b/src/Cafe/Filesystem/FST/fstUtil.h index 012836847..31880e3e5 100644 --- a/src/Cafe/Filesystem/FST/fstUtil.h +++ b/src/Cafe/Filesystem/FST/fstUtil.h @@ -306,9 +306,3 @@ static void FSTPathUnitTest() cemu_assert_debug(p7.MatchNodeName(1, "content")); cemu_assert_debug(p7.MatchNodeName(2, "..")); } - - - - - - diff --git a/src/Cafe/Filesystem/fsc.h b/src/Cafe/Filesystem/fsc.h index 09c1f5080..f0f8b497a 100644 --- a/src/Cafe/Filesystem/fsc.h +++ b/src/Cafe/Filesystem/fsc.h @@ -86,7 +86,6 @@ class fscDeviceC }; - struct FSCVirtualFile { struct FSCDirIteratorState diff --git a/src/Cafe/GamePatch.cpp b/src/Cafe/GamePatch.cpp index 77eaff322..01ab8bef0 100644 --- a/src/Cafe/GamePatch.cpp +++ b/src/Cafe/GamePatch.cpp @@ -268,7 +268,6 @@ static_assert(sizeof(bayo2_audioQueueFixSignature) == sizeof(bayo2_audioQueueFix uint8 cars3_avro_schema_incref[] = { 0x2C,0x03,0x00,0x00,0x94,0x21,0xFF,0xE8,0x41,0x82,0x00,0x40,0x39,0x03,0x00,0x08,0x39,0x41,0x00,0x08,0x91,0x01,0x00,0x08,0x7D,0x80,0x50,0x28,0x2C,0x0C,0xFF,0xFF,0x41,0x82,0x00,0x28,0x39,0x21,0x00,0x0C,0x38,0x0C,0x00,0x01,0x38,0xE0,0x00,0x01,0x91,0x01,0x00,0x0C,0x7C,0x00,0x49,0x2D }; - sint32 hleIndex_h000000001 = -1; sint32 hleIndex_h000000002 = -1; sint32 hleIndex_h000000003 = -1; diff --git a/src/Cafe/GameProfile/GameProfile.cpp b/src/Cafe/GameProfile/GameProfile.cpp index ee92107a7..6a42f1438 100644 --- a/src/Cafe/GameProfile/GameProfile.cpp +++ b/src/Cafe/GameProfile/GameProfile.cpp @@ -47,7 +47,6 @@ bool gameProfile_loadBooleanOption(IniParser* iniParser, char* optionName, gameP return false; } - bool gameProfile_loadBooleanOption2(IniParser& iniParser, const char* optionName, bool& option) { auto option_value = iniParser.FindOption(optionName); diff --git a/src/Cafe/GraphicPack/GraphicPack2.cpp b/src/Cafe/GraphicPack/GraphicPack2.cpp index 365e6e3ea..029c5abef 100644 --- a/src/Cafe/GraphicPack/GraphicPack2.cpp +++ b/src/Cafe/GraphicPack/GraphicPack2.cpp @@ -1148,7 +1148,6 @@ RendererOutputShader* GraphicPack2::GetDownscalingShader(bool render_upside_down } } - std::vector GraphicPack2::GetActivePresets() const { std::vector result; diff --git a/src/Cafe/GraphicPack/GraphicPackError.h b/src/Cafe/GraphicPack/GraphicPackError.h index 91cdb1307..44aea3e69 100644 --- a/src/Cafe/GraphicPack/GraphicPackError.h +++ b/src/Cafe/GraphicPack/GraphicPackError.h @@ -9,7 +9,6 @@ class PatchErrorHandler APPLY, }; - void setCurrentGraphicPack(class GraphicPack2* gp) { m_gp = gp; diff --git a/src/Cafe/HW/AI/AI.cpp b/src/Cafe/HW/AI/AI.cpp index ffd63a0ea..e77e94f65 100644 --- a/src/Cafe/HW/AI/AI.cpp +++ b/src/Cafe/HW/AI/AI.cpp @@ -1,6 +1,5 @@ #include "Cafe/HW/MMU/MMU.h" - namespace HW_AI { diff --git a/src/Cafe/HW/Espresso/Debugger/DebugSymbolStorage.h b/src/Cafe/HW/Espresso/Debugger/DebugSymbolStorage.h index aba6a9b53..459d28951 100644 --- a/src/Cafe/HW/Espresso/Debugger/DebugSymbolStorage.h +++ b/src/Cafe/HW/Espresso/Debugger/DebugSymbolStorage.h @@ -18,7 +18,6 @@ enum class DEBUG_SYMBOL_TYPE DOUBLE, }; - class DebugSymbolStorage { public: diff --git a/src/Cafe/HW/Espresso/Debugger/Debugger.h b/src/Cafe/HW/Espresso/Debugger/Debugger.h index 717df28a3..f4c57f61a 100644 --- a/src/Cafe/HW/Espresso/Debugger/Debugger.h +++ b/src/Cafe/HW/Espresso/Debugger/Debugger.h @@ -15,7 +15,6 @@ #define DEBUGGER_BP_T_GDBSTUB_TW 0x7C010008 #define DEBUGGER_BP_T_DEBUGGER_TW 0x7C020008 - struct DebuggerBreakpoint { uint32 address; @@ -31,7 +30,6 @@ struct DebuggerBreakpoint next = nullptr; } - bool operator<(const DebuggerBreakpoint& rhs) const { return address < rhs.address; diff --git a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp index ed97288d4..48f31f69d 100644 --- a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp +++ b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterALU.hpp @@ -922,4 +922,3 @@ static void PPCInterpreter_CMPLI(PPCInterpreter_t* hCPU, uint32 opcode) hCPU->cr[cr * 4 + CR_BIT_SO] = 1; PPCInterpreter_nextInstruction(hCPU); } - diff --git a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterHelper.h b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterHelper.h index 6d60b7304..8ac268f9b 100644 --- a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterHelper.h +++ b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterHelper.h @@ -10,7 +10,6 @@ static uint32 ppc_cmp_and_mask[8] = { 0x0fffffff, }; - #define ppc_word_rotl(_data, _n) (std::rotl(_data,(_n)&0x1F)) static inline uint32 ppc_mask(int MB, int ME) diff --git a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterLoadStore.hpp b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterLoadStore.hpp index 694e05e65..0f13101e8 100644 --- a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterLoadStore.hpp +++ b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterLoadStore.hpp @@ -674,7 +674,6 @@ static void PPCInterpreter_STFSUX(PPCInterpreter_t* hCPU, uint32 Opcode) hCPU->gpr[rA] += hCPU->gpr[rB]; } - static void PPCInterpreter_STFD(PPCInterpreter_t* hCPU, uint32 Opcode) { FPUCheckAvailable(); @@ -861,7 +860,6 @@ static void PPCInterpreter_PSQ_STU(PPCInterpreter_t* hCPU, unsigned int opcode) PPCInterpreter_nextInstruction(hCPU); } - static void PPCInterpreter_PSQ_STX(PPCInterpreter_t* hCPU, unsigned int opcode) { FPUCheckAvailable(); diff --git a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterOPC.cpp b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterOPC.cpp index 12f86427b..cab572449 100644 --- a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterOPC.cpp +++ b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterOPC.cpp @@ -172,7 +172,6 @@ void PPCInterpreter_BX(PPCInterpreter_t* hCPU, uint32 Opcode) PPCInterpreter_jumpToInstruction(hCPU, li); } - void PPCInterpreter_BCX(PPCInterpreter_t* hCPU, uint32 Opcode) { uint32 BO, BI, BD; diff --git a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterPS.cpp b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterPS.cpp index 942817a04..526037826 100644 --- a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterPS.cpp +++ b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterPS.cpp @@ -62,7 +62,6 @@ void PPCInterpreter_PS_DIV(PPCInterpreter_t* hCPU, uint32 Opcode) PPCInterpreter_nextInstruction(hCPU); } - void PPCInterpreter_PS_MADD(PPCInterpreter_t* hCPU, uint32 Opcode) { FPUCheckAvailable(); diff --git a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterSPR.hpp b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterSPR.hpp index 2d38e728a..c68148ba4 100644 --- a/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterSPR.hpp +++ b/src/Cafe/HW/Espresso/Interpreter/PPCInterpreterSPR.hpp @@ -846,8 +846,6 @@ static uint32 PPCSpr_get(PPCInterpreter_t* hCPU, uint32 spr) break; } - - //if( spr == SPR_LR || spr == SPR_PVR || spr == SPR_UPIR || spr == SPR_SCR || (spr >= SPR_UGQR0 && spr <= SPR_UGQR7) ) //{ // // readable registers diff --git a/src/Cafe/HW/Espresso/Recompiler/PPCRecompiler.cpp b/src/Cafe/HW/Espresso/Recompiler/PPCRecompiler.cpp index f4d063faa..48773a618 100644 --- a/src/Cafe/HW/Espresso/Recompiler/PPCRecompiler.cpp +++ b/src/Cafe/HW/Espresso/Recompiler/PPCRecompiler.cpp @@ -231,7 +231,6 @@ bool PPCRecompiler_makeRecompiledFunctionActive(uint32 initialEntryPoint, PPCFun ppcRecompilerInstanceData->ppcRecompilerDirectJumpTable[itr.first / 4] = (PPCREC_JUMP_ENTRY)((uint8*)ppcRecFunc->x86Code + itr.second); } - // due to inlining, some entrypoints can get optimized away // therefore we reset all addresses that are still marked as visited (but not recompiled) // we dont remove the points from the queue but any address thats not marked as visited won't get recompiled diff --git a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerIml.h b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerIml.h index 86af33b2d..bfad17b2f 100644 --- a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerIml.h +++ b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerIml.h @@ -262,8 +262,6 @@ void PPCRecompilerImlGen_generateNewInstruction_r_s32(ppcImlGenContext_t* ppcIml void PPCRecompilerImlGen_generateNewInstruction_conditional_r_s32(ppcImlGenContext_t* ppcImlGenContext, PPCRecImlInstruction_t* imlInstruction, uint32 operation, uint8 registerIndex, sint32 immS32, uint32 crRegisterIndex, uint32 crBitIndex, bool bitMustBeSet); void PPCRecompilerImlGen_generateNewInstruction_r_r(ppcImlGenContext_t* ppcImlGenContext, PPCRecImlInstruction_t* imlInstruction, uint32 operation, uint8 registerResult, uint8 registerA, uint8 crRegister = PPC_REC_INVALID_REGISTER, uint8 crMode = 0); - - // IML instruction generation (new style, can generate new instructions but also overwrite existing ones) void PPCRecompilerImlGen_generateNewInstruction_noOp(ppcImlGenContext_t* ppcImlGenContext, PPCRecImlInstruction_t* imlInstruction); @@ -389,7 +387,6 @@ void PPCRecompiler_reorderConditionModifyInstructions(ppcImlGenContext_t* ppcIml void PPCRecompiler_dumpIMLSegment(PPCRecImlSegment_t* imlSegment, sint32 segmentIndex, bool printLivenessRangeInfo = false); - typedef struct { union diff --git a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGen.cpp b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGen.cpp index b96854882..a8f526cab 100644 --- a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGen.cpp +++ b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGen.cpp @@ -143,7 +143,6 @@ void PPCRecompilerImlGen_generateNewInstruction_conditional_r_s32(ppcImlGenConte imlInstruction->op_conditional_r_s32.bitMustBeSet = bitMustBeSet; } - void PPCRecompilerImlGen_generateNewInstruction_jump(ppcImlGenContext_t* ppcImlGenContext, PPCRecImlInstruction_t* imlInstruction, uint32 jumpmarkAddress) { // jump @@ -2774,7 +2773,6 @@ bool PPCRecompilerImlGen_XOR(ppcImlGenContext_t* ppcImlGenContext, uint32 opcode return true; } - bool PPCRecompilerImlGen_EQV(ppcImlGenContext_t* ppcImlGenContext, uint32 opcode) { sint32 rS, rA, rB; diff --git a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGenFPU.cpp b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGenFPU.cpp index 1efc41b89..c9c45862d 100644 --- a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGenFPU.cpp +++ b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlGenFPU.cpp @@ -359,7 +359,6 @@ bool PPCRecompilerImlGen_STFSX(ppcImlGenContext_t* ppcImlGenContext, uint32 opco return true; } - bool PPCRecompilerImlGen_STFSUX(ppcImlGenContext_t* ppcImlGenContext, uint32 opcode) { sint32 rA, frS, rB; diff --git a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlOptimizer.cpp b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlOptimizer.cpp index 45e276641..a53cdf4ed 100644 --- a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlOptimizer.cpp +++ b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerImlOptimizer.cpp @@ -1382,7 +1382,6 @@ bool PPCRecompiler_manageFPRRegisters(ppcImlGenContext_t* ppcImlGenContext) return true; } - /* * Returns true if the loaded value is guaranteed to be overwritten */ diff --git a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64.cpp b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64.cpp index a30295b57..ef0feb27e 100644 --- a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64.cpp +++ b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64.cpp @@ -2181,7 +2181,6 @@ bool PPCRecompilerX64Gen_imlInstruction_cr(PPCRecFunction_t* PPCRecFunction, ppc return false; } - void PPCRecompilerX64Gen_imlInstruction_ppcEnter(PPCRecFunction_t* PPCRecFunction, ppcImlGenContext_t* ppcImlGenContext, x64GenContext_t* x64GenContext, PPCRecImlInstruction_t* imlInstruction) { imlInstruction->op_ppcEnter.x64Offset = x64GenContext->codeBufferIndex; diff --git a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64Gen.cpp b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64Gen.cpp index 19327f465..c98a71240 100644 --- a/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64Gen.cpp +++ b/src/Cafe/HW/Espresso/Recompiler/PPCRecompilerX64Gen.cpp @@ -1779,7 +1779,6 @@ void x64Gen_jmpc_far(x64GenContext_t* x64GenContext, sint32 conditionType, sint3 x64Gen_writeU32(x64GenContext, (uint32)relativeDest); } - void x64Gen_jmpc_near(x64GenContext_t* x64GenContext, sint32 conditionType, sint32 relativeDest) { // near JMPc #+relativeDest diff --git a/src/Cafe/HW/Espresso/Recompiler/x64Emit.hpp b/src/Cafe/HW/Espresso/Recompiler/x64Emit.hpp index e936f1d85..c4a364a83 100644 --- a/src/Cafe/HW/Espresso/Recompiler/x64Emit.hpp +++ b/src/Cafe/HW/Espresso/Recompiler/x64Emit.hpp @@ -1,5 +1,4 @@ - template class x64_opc_1byte { diff --git a/src/Cafe/HW/Latte/Core/FetchShader.cpp b/src/Cafe/HW/Latte/Core/FetchShader.cpp index 6c9893f92..c4137a5d9 100644 --- a/src/Cafe/HW/Latte/Core/FetchShader.cpp +++ b/src/Cafe/HW/Latte/Core/FetchShader.cpp @@ -402,7 +402,6 @@ LatteFetchShader* LatteShaderRecompiler_createFetchShader(LatteFetchShader::Cach newFetchShader->m_isRegistered = true; } - return newFetchShader; } diff --git a/src/Cafe/HW/Latte/Core/FetchShader.h b/src/Cafe/HW/Latte/Core/FetchShader.h index ac57714d0..0cf443514 100644 --- a/src/Cafe/HW/Latte/Core/FetchShader.h +++ b/src/Cafe/HW/Latte/Core/FetchShader.h @@ -50,7 +50,6 @@ struct LatteFetchShader CacheHash m_cacheHash{}; bool m_isRegistered{}; // if true, fetch shader is referenced by cache (RegisterInCache() succeeded) - void CalculateFetchShaderVkHash(); uint64 getVkPipelineHashFragment() const { return vkPipelineHashFragment; }; diff --git a/src/Cafe/HW/Latte/Core/LatteCommandProcessor.cpp b/src/Cafe/HW/Latte/Core/LatteCommandProcessor.cpp index 60e5935cd..80e1774ae 100644 --- a/src/Cafe/HW/Latte/Core/LatteCommandProcessor.cpp +++ b/src/Cafe/HW/Latte/Core/LatteCommandProcessor.cpp @@ -548,7 +548,6 @@ LatteCMDPtr LatteCP_itMemWrite(LatteCMDPtr cmd, uint32 nWords) return cmd; } - LatteCMDPtr LatteCP_itMemSemaphore(LatteCMDPtr cmd, uint32 nWords) { cemu_assert_debug(nWords == 2); diff --git a/src/Cafe/HW/Latte/Core/LatteDefaultShaders.cpp b/src/Cafe/HW/Latte/Core/LatteDefaultShaders.cpp index 7c590dbb5..1b6084996 100644 --- a/src/Cafe/HW/Latte/Core/LatteDefaultShaders.cpp +++ b/src/Cafe/HW/Latte/Core/LatteDefaultShaders.cpp @@ -76,7 +76,6 @@ LatteDefaultShader_t* LatteDefaultShader_getPixelCopyShader_colorToDepth() fCStr_defaultFragShader.add("gl_FragDepth = texture(textureSrc, passUV).r;\r\n"); fCStr_defaultFragShader.add("}\r\n"); - defaultShader->glProgamId = gxShaderDepr_compileRaw(&fCStr_vertexShader, &fCStr_defaultFragShader); defaultShader->copyShaderUniforms.uniformLoc_textureSrc = glGetUniformLocation(defaultShader->glProgamId, "textureSrc"); defaultShader->copyShaderUniforms.uniformLoc_vertexOffsets = glGetUniformLocation(defaultShader->glProgamId, "uf_vertexOffsets"); diff --git a/src/Cafe/HW/Latte/Core/LatteIndices.cpp b/src/Cafe/HW/Latte/Core/LatteIndices.cpp index 6e1d74559..fe6fdf7c7 100644 --- a/src/Cafe/HW/Latte/Core/LatteIndices.cpp +++ b/src/Cafe/HW/Latte/Core/LatteIndices.cpp @@ -266,7 +266,6 @@ void LatteIndices_generateAutoQuadStripIndices(void* indexDataOutput, uint32 cou indexMax = std::max(count, 1u) - 1; } - template void LatteIndices_generateAutoLineLoopIndices(void* indexDataOutput, uint32 count, uint32& indexMin, uint32& indexMax) { diff --git a/src/Cafe/HW/Latte/Core/LatteRenderTarget.cpp b/src/Cafe/HW/Latte/Core/LatteRenderTarget.cpp index abdfda217..02117a78d 100644 --- a/src/Cafe/HW/Latte/Core/LatteRenderTarget.cpp +++ b/src/Cafe/HW/Latte/Core/LatteRenderTarget.cpp @@ -1078,8 +1078,6 @@ void LatteRenderTarget_itHLECopyColorBufferToScanBuffer(MPTR colorBufferPtr, uin LatteRenderTarget_copyToBackbuffer(texView, false); } - - // returns the current size of the virtual viewport (not the same as effective size, which can be influenced by texture rules) void LatteRenderTarget_GetCurrentVirtualViewportSize(sint32* viewportWidth, sint32* viewportHeight) { diff --git a/src/Cafe/HW/Latte/Core/LatteTextureLoader.h b/src/Cafe/HW/Latte/Core/LatteTextureLoader.h index f6de57d68..49291a0f5 100644 --- a/src/Cafe/HW/Latte/Core/LatteTextureLoader.h +++ b/src/Cafe/HW/Latte/Core/LatteTextureLoader.h @@ -292,7 +292,6 @@ class TextureDecoder_R32_G32_UINT : public TextureDecoder, public SingletonClass } }; - class TextureDecoder_R32_UINT : public TextureDecoder, public SingletonClass { public: @@ -723,7 +722,6 @@ class TextureDecoder_R4_G4_B4_A4_UNORM : public TextureDecoder, public Singleton } }; - class TextureDecoder_R4G4B4A4_UNORM_To_RGBA8 : public TextureDecoder, public SingletonClass { public: diff --git a/src/Cafe/HW/Latte/Core/LatteTextureView.cpp b/src/Cafe/HW/Latte/Core/LatteTextureView.cpp index cac5bcce4..ad8fb6911 100644 --- a/src/Cafe/HW/Latte/Core/LatteTextureView.cpp +++ b/src/Cafe/HW/Latte/Core/LatteTextureView.cpp @@ -143,7 +143,6 @@ void LatteTextureViewLookupCache::RemoveAll(LatteTextureView* view) } } - LatteTextureView* LatteTextureViewLookupCache::lookup(MPTR physAddr, sint32 width, sint32 height, sint32 depth, sint32 pitch, sint32 firstMip, sint32 numMip, sint32 firstSlice, sint32 numSlice, Latte::E_GX2SURFFMT format, Latte::E_DIM dim) { // todo - add tileMode param to this and the other lookup functions? diff --git a/src/Cafe/HW/Latte/Core/LatteTiming.cpp b/src/Cafe/HW/Latte/Core/LatteTiming.cpp index 115b60d91..a55a6045d 100644 --- a/src/Cafe/HW/Latte/Core/LatteTiming.cpp +++ b/src/Cafe/HW/Latte/Core/LatteTiming.cpp @@ -131,7 +131,6 @@ void LatteTiming_NotifyHostVSync() auto dif = nowTimePoint - s_lastHostVsync; auto vsyncPeriod = LatteTime_CalculateTimeBetweenVSync(); - if (dif < vsyncPeriod) { // skip diff --git a/src/Cafe/HW/Latte/ISA/LatteReg.h b/src/Cafe/HW/Latte/ISA/LatteReg.h index d571dc6e6..164c8daf1 100644 --- a/src/Cafe/HW/Latte/ISA/LatteReg.h +++ b/src/Cafe/HW/Latte/ISA/LatteReg.h @@ -160,7 +160,6 @@ namespace Latte U_HWFMT_32_32_32 = 0x2F, U_HWFMT_32_32_32_FLOAT = 0x30, - }; enum class E_GX2SURFFMT // GX2 surface format @@ -489,7 +488,6 @@ namespace Latte SQ_TEX_SAMPLER_WORD1_0 = 0xF001, SQ_TEX_SAMPLER_WORD2_0 = 0xF002, - }; inline constexpr int SAMPLER_BASE_INDEX_PIXEL = 0; diff --git a/src/Cafe/HW/Latte/ISA/RegDefines.h b/src/Cafe/HW/Latte/ISA/RegDefines.h index b99c2126c..12da90907 100644 --- a/src/Cafe/HW/Latte/ISA/RegDefines.h +++ b/src/Cafe/HW/Latte/ISA/RegDefines.h @@ -310,7 +310,6 @@ #define mmSQ_GSTMP_RING_BASE 0x2316 #define mmSQ_GSTMP_RING_SIZE 0x2317 - #define mmSQ_TEX_RESOURCE_WORD0 0xE000 #define mmSQ_ALU_CONSTANT0_0 0xC000 diff --git a/src/Cafe/HW/Latte/LatteAddrLib/AddrLibFastDecode.h b/src/Cafe/HW/Latte/LatteAddrLib/AddrLibFastDecode.h index b0e2cfb31..a8dccbd1c 100644 --- a/src/Cafe/HW/Latte/LatteAddrLib/AddrLibFastDecode.h +++ b/src/Cafe/HW/Latte/LatteAddrLib/AddrLibFastDecode.h @@ -111,7 +111,6 @@ void optimizedDecodeLoop_tm04_numSamples1_8x8_optimizedRowCopy(LatteTextureLoade // 6 -> 10 // 7 -> 11 - if ((sizeof(texelBaseType)*texelBaseTypeCount) == 8) { // bpp = 64 diff --git a/src/Cafe/HW/Latte/LegacyShaderDecompiler/LatteDecompilerEmitGLSL.cpp b/src/Cafe/HW/Latte/LegacyShaderDecompiler/LatteDecompilerEmitGLSL.cpp index f3d2c7a82..a00a730c6 100644 --- a/src/Cafe/HW/Latte/LegacyShaderDecompiler/LatteDecompilerEmitGLSL.cpp +++ b/src/Cafe/HW/Latte/LegacyShaderDecompiler/LatteDecompilerEmitGLSL.cpp @@ -2811,7 +2811,6 @@ void _emitTEXGetCompTexLodCode(LatteDecompilerShaderContext* shaderContext, Latt debugBreakpoint(); } - _emitTypeConversionSuffix(shaderContext, LATTE_DECOMPILER_DTYPE_FLOAT, shaderContext->typeTracker.defaultDataType); src->add("."); diff --git a/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRenderer.cpp b/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRenderer.cpp index f09f04f15..e79dd4629 100644 --- a/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRenderer.cpp +++ b/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRenderer.cpp @@ -306,7 +306,6 @@ void OpenGLRenderer::Initialize() if (m_vendor == GfxVendor::Nvidia) glClampColor(GL_CLAMP_FRAGMENT_COLOR, GL_FALSE); - glEnable(GL_PRIMITIVE_RESTART); glPrimitiveRestartIndex(0xFFFFFFFF); @@ -461,7 +460,6 @@ void OpenGLRenderer::ClearColorbuffer(bool padView) glClear(GL_COLOR_BUFFER_BIT); } - void OpenGLRenderer::HandleScreenshotRequest(LatteTextureView* texView, bool padView) { const bool hasScreenshotRequest = gui_hasScreenshotRequest(); @@ -1148,7 +1146,6 @@ void OpenGLRenderer::texture_clearDepthSlice(LatteTexture* hostTexture, uint32 s catchOpenGLError(); } - void OpenGLRenderer::texture_clearSlice(LatteTexture* hostTextureGeneric, sint32 sliceIndex, sint32 mipIndex) { auto hostTexture = (LatteTextureGL*)hostTextureGeneric; diff --git a/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRendererCore.cpp b/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRendererCore.cpp index 51d0d206a..5c1264dbd 100644 --- a/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRendererCore.cpp +++ b/src/Cafe/HW/Latte/Renderer/OpenGL/OpenGLRendererCore.cpp @@ -19,7 +19,6 @@ #include "Cafe/GameProfile/GameProfile.h" #include "config/ActiveSettings.h" - using _INDEX_TYPE = Latte::LATTE_VGT_DMA_INDEX_TYPE::E_INDEX_TYPE; GLenum sGLActiveDrawMode = 0; @@ -368,7 +367,6 @@ void _decodeAndUploadIndexData(indexDataCacheEntry2_t* cacheEntry) } } - void LatteDraw_cleanupAfterFrame() { // drop everything from cache that is older than 30 frames @@ -1262,7 +1260,6 @@ void OpenGLRenderer::bufferCache_copy(uint32 srcOffset, uint32 dstOffset, uint32 glCopyBufferSubData(GL_ARRAY_BUFFER, GL_ARRAY_BUFFER, srcOffset, dstOffset, size); } - GLint glClampTable[] = { GL_REPEAT, diff --git a/src/Cafe/HW/Latte/Renderer/Renderer.cpp b/src/Cafe/HW/Latte/Renderer/Renderer.cpp index 4db883556..9f7db59c3 100644 --- a/src/Cafe/HW/Latte/Renderer/Renderer.cpp +++ b/src/Cafe/HW/Latte/Renderer/Renderer.cpp @@ -37,7 +37,6 @@ bool Renderer::GetVRAMInfo(int& usageInMB, int& totalInMB) const return false; } - void Renderer::Initialize() { // imgui diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.cpp index 66f7ba955..986850c56 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.cpp @@ -98,7 +98,6 @@ void CachedFBOVk::CreateFramebuffer() m_extend = { (uint32)m_size.x, (uint32)m_size.y }; } - void CachedFBOVk::InitDynamicRenderingData() { // init struct for KHR_dynamic_rendering @@ -189,7 +188,6 @@ void CachedFBOVk::InitDynamicRenderingData() m_vkRenderingInfo.layerCount = 1; } - uint32 s_currentCollisionCheckIndex = 1; bool CachedFBOVk::CheckForCollision(VkDescriptorSetInfo* vsDS, VkDescriptorSetInfo* gsDS, VkDescriptorSetInfo* psDS) const diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.h b/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.h index bf72996ea..bbe8abaec 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.h +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/CachedFBOVk.h @@ -34,7 +34,6 @@ class CachedFBOVk : public LatteCachedFBO return &m_vkRenderingInfo; } - void TrackDependency(class PipelineInfo* pipelineInfo) { s_spinlockDependency.lock(); diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.cpp index 14b7a17cb..e414f0d07 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.cpp @@ -32,7 +32,6 @@ void SwapchainInfoVk::Create(VkPhysicalDevice physicalDevice, VkDevice logicalDe if (result != VK_SUCCESS) UnrecoverableError("Error attempting to retrieve the count of swapchain images"); - m_swapchainImages.resize(image_count); result = vkGetSwapchainImagesKHR(logicalDevice, swapchain, &image_count, m_swapchainImages.data()); if (result != VK_SUCCESS) diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.h b/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.h index 26dbc7d15..423fdc5c6 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.h +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/SwapchainInfoVk.h @@ -55,7 +55,6 @@ struct SwapchainInfoVk VkSwapchainCreateInfoKHR CreateSwapchainCreateInfo(VkSurfaceKHR surface, const SwapchainSupportDetails& swapchainSupport, const VkSurfaceFormatKHR& surfaceFormat, uint32 imageCount, const VkExtent2D& extent); - VkExtent2D getExtent() const { return m_actualExtent; @@ -85,7 +84,6 @@ struct SwapchainInfoVk Vector2i m_desiredExtent{}; uint32 swapchainImageIndex = (uint32)-1; - // swapchain image ringbuffer (indexed by swapchainImageIndex) std::vector m_swapchainImages; std::vector m_swapchainImageViews; diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/TextureReadbackVk.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/TextureReadbackVk.cpp index b055fe7eb..ad11f89c2 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/TextureReadbackVk.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/TextureReadbackVk.cpp @@ -87,7 +87,6 @@ uint32 LatteTextureReadbackInfoVk::GetImageSize(LatteTextureView* textureView) } } - void LatteTextureReadbackInfoVk::StartTransfer() { cemu_assert(m_textureView); diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VKRPipelineInfo.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/VKRPipelineInfo.cpp index 72a1be4c2..2c98994ba 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VKRPipelineInfo.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VKRPipelineInfo.cpp @@ -3,6 +3,7 @@ #include "Cafe/HW/Latte/Renderer/Vulkan/LatteTextureVk.h" #include "Cafe/HW/Latte/Renderer/Vulkan/RendererShaderVk.h" +#include #include "Cafe/HW/Latte/LegacyShaderDecompiler/LatteDecompiler.h" #include "Cafe/HW/Latte/Core/LattePerformanceMonitor.h" @@ -47,7 +48,6 @@ PipelineInfo::PipelineInfo(uint64 minimalStateHash, uint64 pipelineHash, LatteFe } } - PipelineInfo::~PipelineInfo() { if (rectEmulationGS) @@ -90,4 +90,4 @@ PipelineInfo::~PipelineInfo() // remove from cache VulkanRenderer::GetInstance()->unregisterGraphicsPipeline(this); -} +} \ No newline at end of file diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanAPI.h b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanAPI.h index 0489bb4e7..ccc89e1c3 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanAPI.h +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanAPI.h @@ -46,8 +46,6 @@ extern bool g_vulkan_available; #endif #endif - - // global functions VKFUNC(vkGetInstanceProcAddr); VKFUNC(vkCreateInstance); diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanPipelineCompiler.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanPipelineCompiler.cpp index ce582b9ac..cdfa8c724 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanPipelineCompiler.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanPipelineCompiler.cpp @@ -635,7 +635,6 @@ bool _IsVkIntegerFormat(VkFormat fmt) fmt == VK_FORMAT_R32G32B32A32_UINT || fmt == VK_FORMAT_R32G32B32A32_SINT; } - void PipelineCompiler::InitBlendState(const LatteContextRegister& latteRegister, PipelineInfo* pipelineInfo, bool& usesBlendConstants, VKRObjectRenderPass* renderPassObj) { const Latte::LATTE_CB_COLOR_CONTROL& colorControlReg = latteRegister.CB_COLOR_CONTROL; diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanQuery.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanQuery.cpp index f9788c9c9..c7c26ed06 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanQuery.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanQuery.cpp @@ -63,7 +63,6 @@ void LatteQueryObjectVk::beginFragment() qf.m_finishCommandBuffer = 0; list_queryFragments.emplace_back(qf); - vkCmdResetQueryPool(m_rendererVk->m_state.currentCommandBuffer, m_rendererVk->m_occlusionQueries.queryPool, newQueryIndex, 1); vkCmdBeginQuery(m_rendererVk->m_state.currentCommandBuffer, m_rendererVk->m_occlusionQueries.queryPool, newQueryIndex, VK_QUERY_CONTROL_PRECISE_BIT); // todo - we already synchronize with command buffers, should we also set wait bits? diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.cpp index 616f57e24..110e4db74 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.cpp @@ -26,7 +26,7 @@ #include "Cafe/HW/Latte/Core/LatteTiming.h" // vsync control -#include +#include #include @@ -1791,7 +1791,6 @@ void VulkanRenderer::DeleteFontTextures() ImGui_ImplVulkan_DestroyFontsTexture(); } - bool VulkanRenderer::BeginFrame(bool mainWindow) { if (!AcquireNextSwapchainImage(mainWindow)) @@ -2994,7 +2993,6 @@ void VulkanRenderer::renderTarget_setViewport(float x, float y, float width, flo vkCmdSetViewport(m_state.currentCommandBuffer, 0, 1, &m_state.currentViewport); } - void VulkanRenderer::renderTarget_setScissor(sint32 scissorX, sint32 scissorY, sint32 scissorWidth, sint32 scissorHeight) { m_state.currentScissorRect.offset.x = scissorX; diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.h b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.h index b61a0b400..f1075855d 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.h +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRenderer.h @@ -288,7 +288,6 @@ class VulkanRenderer : public Renderer void* texture_acquireTextureUploadBuffer(uint32 size) override; void texture_releaseTextureUploadBuffer(uint8* mem) override; - TextureDecoder* texture_chooseDecodedFormat(Latte::E_GX2SURFFMT format, bool isDepth, Latte::E_DIM dim, uint32 width, uint32 height) override; void texture_reserveTextureOnGPU(LatteTexture* hostTexture) override; @@ -942,7 +941,6 @@ class VulkanRenderer : public Renderer vkTexture->SetImageLayout(subresourceRange, newLayout); } - public: bool GetDisableMultithreadedCompilation() const { return m_featureControl.disableMultithreadedCompilation; } bool UseTFViaSSBO() const { return m_featureControl.mode.useTFEmulationViaSSBO; } diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRendererCore.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRendererCore.cpp index 320357f1f..380795d55 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRendererCore.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanRendererCore.cpp @@ -950,7 +950,6 @@ VkDescriptorSetInfo* VulkanRenderer::draw_getOrCreateDescriptorSet(PipelineInfo* } } - VkDescriptorBufferInfo tfStorageBufferInfo{}; if (shader->resourceMapping.tfStorageBindingPoint >= 0) diff --git a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanSurfaceCopy.cpp b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanSurfaceCopy.cpp index 6d5d94025..5170c1bf3 100644 --- a/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanSurfaceCopy.cpp +++ b/src/Cafe/HW/Latte/Renderer/Vulkan/VulkanSurfaceCopy.cpp @@ -315,7 +315,6 @@ CopySurfacePipelineInfo* VulkanRenderer::copySurface_getOrCreateGraphicsPipeline colorBlending.logicOpEnable = VK_FALSE; } - // ########################################################################################################################################## std::vector descriptorSetLayoutBindings; @@ -563,7 +562,6 @@ void VulkanRenderer::surfaceCopy_viaDrawcall(LatteTextureVk* srcTextureVk, sint3 //debug_printf("surfaceCopy_viaDrawcall Src %04d %04d Dst %04d %04d CopySize %04d %04d\n", srcTextureVk->width, srcTextureVk->height, dstTextureVk->width, dstTextureVk->height, effectiveCopyWidth, effectiveCopyHeight); - VkImageSubresourceLayers srcImageSubresource; srcImageSubresource.aspectMask = srcTextureVk->GetImageAspect(); srcImageSubresource.baseArrayLayer = texSrcSlice; diff --git a/src/Cafe/HW/Latte/ShaderInfo/ShaderDescription.cpp b/src/Cafe/HW/Latte/ShaderInfo/ShaderDescription.cpp index 750b4801d..f1a04d176 100644 --- a/src/Cafe/HW/Latte/ShaderInfo/ShaderDescription.cpp +++ b/src/Cafe/HW/Latte/ShaderInfo/ShaderDescription.cpp @@ -7,7 +7,6 @@ namespace Latte { assert_dbg(); - // parse CF flow // we need to parse: // - Export clauses to gather info about exported attributes and written render targets diff --git a/src/Cafe/HW/Latte/Transcompiler/LatteTC.h b/src/Cafe/HW/Latte/Transcompiler/LatteTC.h index 8660deb8d..65300a3e5 100644 --- a/src/Cafe/HW/Latte/Transcompiler/LatteTC.h +++ b/src/Cafe/HW/Latte/Transcompiler/LatteTC.h @@ -190,7 +190,6 @@ class LatteTCGenIR struct ZpIR::ZpIRFunction* irObject; }m_ctx; - // vertex shader info struct { diff --git a/src/Cafe/HW/MMU/MMU.cpp b/src/Cafe/HW/MMU/MMU.cpp index 04ee8877e..1259e5537 100644 --- a/src/Cafe/HW/MMU/MMU.cpp +++ b/src/Cafe/HW/MMU/MMU.cpp @@ -27,7 +27,6 @@ void memory_initPhysicalLayout() //// allocate memory for bootrom //checkMemAlloc(VirtualAlloc(memory_base + 0x00000000, 1024*16, MEM_RESERVE|MEM_COMMIT, PAGE_READWRITE)); - //// allocate memory at 0x016FFFFC (is this some sort of register interface or maybe just temporary storage?) //checkMemAlloc(VirtualAlloc(memory_base + 0x016FF000, 0x1000, MEM_RESERVE | MEM_COMMIT, PAGE_READWRITE)); diff --git a/src/Cafe/HW/MMU/MMU.h b/src/Cafe/HW/MMU/MMU.h index 794785faf..2d65677b6 100644 --- a/src/Cafe/HW/MMU/MMU.h +++ b/src/Cafe/HW/MMU/MMU.h @@ -118,7 +118,6 @@ struct MMURange bool m_isMapped{}; }; - extern MMURange mmuRange_LOW0; extern MMURange mmuRange_TRAMPOLINE_AREA; extern MMURange mmuRange_CODECAVE; diff --git a/src/Cafe/HW/VI/VI.cpp b/src/Cafe/HW/VI/VI.cpp index 0e2a50c51..901124435 100644 --- a/src/Cafe/HW/VI/VI.cpp +++ b/src/Cafe/HW/VI/VI.cpp @@ -1,6 +1,5 @@ #include "Cafe/HW/MMU/MMU.h" - namespace HW_VI { diff --git a/src/Cafe/IOSU/PDM/iosu_pdm.cpp b/src/Cafe/IOSU/PDM/iosu_pdm.cpp index e54529a9c..3b2c35e8a 100644 --- a/src/Cafe/IOSU/PDM/iosu_pdm.cpp +++ b/src/Cafe/IOSU/PDM/iosu_pdm.cpp @@ -13,7 +13,6 @@ namespace chrono_d = date; namespace chrono_d = std::chrono; #endif - namespace iosu { namespace pdm diff --git a/src/Cafe/IOSU/iosu_ipc_common.h b/src/Cafe/IOSU/iosu_ipc_common.h index f9ded224f..108074a73 100644 --- a/src/Cafe/IOSU/iosu_ipc_common.h +++ b/src/Cafe/IOSU/iosu_ipc_common.h @@ -67,7 +67,5 @@ struct IPCCommandBody args[1] = numIn args[2] = numOut args[3] = IPCIoctlVector* - - */ }; diff --git a/src/Cafe/IOSU/legacy/iosu_acp.cpp b/src/Cafe/IOSU/legacy/iosu_acp.cpp index ef5f70833..1832adac3 100644 --- a/src/Cafe/IOSU/legacy/iosu_acp.cpp +++ b/src/Cafe/IOSU/legacy/iosu_acp.cpp @@ -360,7 +360,6 @@ namespace iosu sprintf(titlePath, "/vol/storage_mlc01/usr/title/%08x/%08x/", (uint32)(titleId >> 32), (uint32)(titleId & 0xFFFFFFFF)); } - char filePath[FSA_CMD_PATH_MAX_LENGTH]; sprintf(filePath, "%smeta/bootMovie.h264", titlePath); @@ -405,7 +404,6 @@ namespace iosu sprintf(titlePath, "/vol/storage_mlc01/usr/title/%08x/%08x/", (uint32)(titleId >> 32), (uint32)(titleId & 0xFFFFFFFF)); } - char filePath[FSA_CMD_PATH_MAX_LENGTH]; sprintf(filePath, "%smeta/meta.xml", titlePath); diff --git a/src/Cafe/IOSU/legacy/iosu_acp.h b/src/Cafe/IOSU/legacy/iosu_acp.h index 18197bd8e..d13e631dd 100644 --- a/src/Cafe/IOSU/legacy/iosu_acp.h +++ b/src/Cafe/IOSU/legacy/iosu_acp.h @@ -141,7 +141,6 @@ typedef struct // size is 0x80, but actual content size is only 0x60 and padded to 0x80? }acpSaveDirInfo_t; - // custom dev/acp_main protocol (Cemu only) #define IOSU_ACP_REQUEST_CEMU (0xEE) diff --git a/src/Cafe/IOSU/legacy/iosu_act.cpp b/src/Cafe/IOSU/legacy/iosu_act.cpp index ed3a69bdc..f6bdab29a 100644 --- a/src/Cafe/IOSU/legacy/iosu_act.cpp +++ b/src/Cafe/IOSU/legacy/iosu_act.cpp @@ -267,7 +267,6 @@ namespace iosu } } - // IOSU act IO typedef struct diff --git a/src/Cafe/IOSU/legacy/iosu_boss.cpp b/src/Cafe/IOSU/legacy/iosu_boss.cpp index c2c1eb51f..a429f9b10 100644 --- a/src/Cafe/IOSU/legacy/iosu_boss.cpp +++ b/src/Cafe/IOSU/legacy/iosu_boss.cpp @@ -189,7 +189,6 @@ namespace iosu static_assert(sizeof(BossNbdlHeader) == 0x40, "BossNbdlHeader has invalid size"); static_assert(offsetof(BossNbdlHeader, encryptedHeader) == 0x20, "offsetof(BossNbdlHeader, encryptedHeader)"); - struct { bool is_initialized; @@ -638,7 +637,6 @@ namespace iosu break; } - if (!it->queued_files.empty()) { curl_easy_setopt(curl, CURLOPT_HEADERFUNCTION, task_download_header_callback); diff --git a/src/Cafe/IOSU/legacy/iosu_crypto.cpp b/src/Cafe/IOSU/legacy/iosu_crypto.cpp index 80eb2f017..239d3dc2d 100644 --- a/src/Cafe/IOSU/legacy/iosu_crypto.cpp +++ b/src/Cafe/IOSU/legacy/iosu_crypto.cpp @@ -238,7 +238,6 @@ void iosuCrypto_generateDeviceCertificate() g_wiiuDeviceCert.ukn0C0[2] = 0x00; g_wiiuDeviceCert.ukn0C0[3] = 0x02; - iosuCrypto_readOtpData(g_wiiuDeviceCert.signature, 0xA3, 0x3C); uint32be caValue; @@ -254,7 +253,6 @@ void iosuCrypto_generateDeviceCertificate() iosuCrypto_readOtpData(&g_wiiuDeviceCert.ngKeyId, 0xA2, sizeof(uint32)); - uint8 privateKey[0x20]; memset(privateKey, 0, sizeof(privateKey)); iosuCrypto_readOtpData(privateKey, 0x88, 0x1E); diff --git a/src/Cafe/IOSU/legacy/iosu_crypto.h b/src/Cafe/IOSU/legacy/iosu_crypto.h index 9f1429c76..02b2e2ba5 100644 --- a/src/Cafe/IOSU/legacy/iosu_crypto.h +++ b/src/Cafe/IOSU/legacy/iosu_crypto.h @@ -45,7 +45,6 @@ struct CertECC_t /* +0x108 */ uint8 publicKey[0x3C]; /* +0x144 */ uint8 padding[0x180 - 0x144]; - }; static_assert(sizeof(CertECC_t) == 0x180); diff --git a/src/Cafe/IOSU/legacy/iosu_fpd.cpp b/src/Cafe/IOSU/legacy/iosu_fpd.cpp index 9130b28d2..01b020657 100644 --- a/src/Cafe/IOSU/legacy/iosu_fpd.cpp +++ b/src/Cafe/IOSU/legacy/iosu_fpd.cpp @@ -1446,7 +1446,6 @@ namespace iosu private: - }; FPDService gFPDService; diff --git a/src/Cafe/IOSU/legacy/iosu_ioctl.h b/src/Cafe/IOSU/legacy/iosu_ioctl.h index c1fcaee70..1dd576021 100644 --- a/src/Cafe/IOSU/legacy/iosu_ioctl.h +++ b/src/Cafe/IOSU/legacy/iosu_ioctl.h @@ -29,7 +29,6 @@ typedef struct uint32 returnValue; }ioQueueEntry_t; - #define IOS_PATH_SOCKET "/dev/socket" #define IOS_PATH_ODM "/dev/odm" #define IOS_PATH_ACT "/dev/act" @@ -54,7 +53,6 @@ typedef struct void iosuIoctl_init(); - // for use by IOSU ioQueueEntry_t* iosuIoctl_getNextWithWait(uint32 deviceIndex); ioQueueEntry_t* iosuIoctl_getNextWithTimeout(uint32 deviceIndex, sint32 ms); diff --git a/src/Cafe/IOSU/legacy/iosu_nim.cpp b/src/Cafe/IOSU/legacy/iosu_nim.cpp index e7cf97ef0..ca0893613 100644 --- a/src/Cafe/IOSU/legacy/iosu_nim.cpp +++ b/src/Cafe/IOSU/legacy/iosu_nim.cpp @@ -272,7 +272,6 @@ namespace iosu std::this_thread::sleep_for(std::chrono::milliseconds(200)); } - void iosuNim_thread() { SetThreadName("iosuNim_thread"); diff --git a/src/Cafe/OS/RPL/rpl_debug_symbols.h b/src/Cafe/OS/RPL/rpl_debug_symbols.h index 9c87eed47..6216648eb 100644 --- a/src/Cafe/OS/RPL/rpl_debug_symbols.h +++ b/src/Cafe/OS/RPL/rpl_debug_symbols.h @@ -17,7 +17,6 @@ struct rplDebugSymbolComment : rplDebugSymbolBase std::wstring comment; }; - void rplDebugSymbol_createComment(MPTR address, const wchar_t* comment); rplDebugSymbolBase* rplDebugSymbol_getForAddress(MPTR address); const std::map& rplDebugSymbol_getSymbols(); \ No newline at end of file diff --git a/src/Cafe/OS/RPL/rpl_structs.h b/src/Cafe/OS/RPL/rpl_structs.h index 998ec8d7d..d6d696199 100644 --- a/src/Cafe/OS/RPL/rpl_structs.h +++ b/src/Cafe/OS/RPL/rpl_structs.h @@ -97,7 +97,6 @@ typedef struct static_assert(offsetof(rplHeaderNew_t, dataRegionSize) == 0xC); static_assert(offsetof(rplHeaderNew_t, programHeaderTableEntrySize) == 0x2A); - typedef struct { /* +0x00 */ uint32be fileInfoMagic; // always 0xCAFE0402 @@ -127,7 +126,6 @@ typedef struct static_assert(offsetof(RPLFileInfoData, tlsModuleIndex) == 0x58); - typedef struct { //uint32 address; diff --git a/src/Cafe/OS/common/OSCommon.h b/src/Cafe/OS/common/OSCommon.h index 4fb65a472..d3280effc 100644 --- a/src/Cafe/OS/common/OSCommon.h +++ b/src/Cafe/OS/common/OSCommon.h @@ -2,7 +2,6 @@ struct PPCInterpreter_t; - #define OSLIB_FUNCTIONTABLE_TYPE_FUNCTION (1) #define OSLIB_FUNCTIONTABLE_TYPE_POINTER (2) diff --git a/src/Cafe/OS/libs/camera/camera.cpp b/src/Cafe/OS/libs/camera/camera.cpp index 4debb37fe..70f5f790d 100644 --- a/src/Cafe/OS/libs/camera/camera.cpp +++ b/src/Cafe/OS/libs/camera/camera.cpp @@ -50,7 +50,6 @@ namespace camera /* +0xC */ uint32be field3; }; - #define CAM_ERROR_SUCCESS 0 #define CAM_ERROR_INVALID_HANDLE -8 @@ -177,7 +176,6 @@ namespace camera osLib_returnFromFunction(hCPU, 0); } - sint32 CAMInit(uint32 cameraId, CAMInitInfo_t* camInitInfo, uint32be* error) { CameraInstance* camInstance = new CameraInstance(camInitInfo->width, camInitInfo->height, camInitInfo->handlerFuncPtr); diff --git a/src/Cafe/OS/libs/dmae/dmae.cpp b/src/Cafe/OS/libs/dmae/dmae.cpp index 6b3e8d0d4..dd43e4b91 100644 --- a/src/Cafe/OS/libs/dmae/dmae.cpp +++ b/src/Cafe/OS/libs/dmae/dmae.cpp @@ -108,7 +108,6 @@ void dmaeExport_DMAEGetRetiredTimeStamp(PPCInterpreter_t* hCPU) osLib_returnFromFunction64(hCPU, dmaeRetiredTimestamp); } - void dmae_load() { osLib_addFunction("dmae", "DMAECopyMem", dmaeExport_DMAECopyMem); diff --git a/src/Cafe/OS/libs/erreula/erreula.cpp b/src/Cafe/OS/libs/erreula/erreula.cpp index c95816b66..fd0925b17 100644 --- a/src/Cafe/OS/libs/erreula/erreula.cpp +++ b/src/Cafe/OS/libs/erreula/erreula.cpp @@ -96,8 +96,6 @@ namespace erreula std::chrono::steady_clock::time_point stateTimer{}; } g_errEula = {}; - - std::wstring GetText(uint16be* text) { @@ -111,7 +109,6 @@ namespace erreula return result.str(); } - void export_ErrEulaCreate(PPCInterpreter_t* hCPU) { diff --git a/src/Cafe/OS/libs/h264_avc/H264Dec.cpp b/src/Cafe/OS/libs/h264_avc/H264Dec.cpp index 024965fd0..a2dd719be 100644 --- a/src/Cafe/OS/libs/h264_avc/H264Dec.cpp +++ b/src/Cafe/OS/libs/h264_avc/H264Dec.cpp @@ -648,7 +648,6 @@ namespace H264 status = ih264d_api_function(m_codecCtx, &s_set_display_frame_ip, &s_set_display_frame_op); cemu_assert(!status); - // mark all as released (available) for (uint32 i = 0; i < s_ctl_op.u4_num_disp_bufs; i++) { diff --git a/src/Cafe/OS/libs/h264_avc/parser/H264Parser.cpp b/src/Cafe/OS/libs/h264_avc/parser/H264Parser.cpp index d77e551fa..0d70d9194 100644 --- a/src/Cafe/OS/libs/h264_avc/parser/H264Parser.cpp +++ b/src/Cafe/OS/libs/h264_avc/parser/H264Parser.cpp @@ -707,8 +707,6 @@ void _calculateFrameOrder(h264ParserState_t* h264ParserState, const h264State_se else FrameNumOffset = prevFrameNumOffset; - - } uint32 tempPicOrderCnt; diff --git a/src/Cafe/OS/libs/h264_avc/parser/H264Parser.h b/src/Cafe/OS/libs/h264_avc/parser/H264Parser.h index ee32ca8bb..6c5cafe40 100644 --- a/src/Cafe/OS/libs/h264_avc/parser/H264Parser.h +++ b/src/Cafe/OS/libs/h264_avc/parser/H264Parser.h @@ -332,7 +332,6 @@ struct h264State_pic_parameter_set_t sint32 second_chroma_qp_index_offset; }; - struct h264State_seq_parameter_set_t { uint8 profile_idc; // 0x64 = high profile diff --git a/src/Cafe/OS/libs/nlibcurl/nlibcurl.cpp b/src/Cafe/OS/libs/nlibcurl/nlibcurl.cpp index 53981a5a8..fd8008564 100644 --- a/src/Cafe/OS/libs/nlibcurl/nlibcurl.cpp +++ b/src/Cafe/OS/libs/nlibcurl/nlibcurl.cpp @@ -110,7 +110,6 @@ struct MEMPTR calloc; } g_nlibcurl = {}; - #pragma pack(1) struct CURL_t @@ -340,7 +339,6 @@ void export_realloc(PPCInterpreter_t* hCPU) osLib_returnFromFunction(hCPU, result.GetMPTR()); } - CURLcode curl_global_init(uint32 flags) { if (g_nlibcurl.initialized++) @@ -938,7 +936,6 @@ size_t read_callback(char* buffer, size_t size, size_t nitems, void* instream) return msg.result; } - int progress_callback(void* clientp, double dltotal, double dlnow, double ultotal, double ulnow) { //peterBreak(); @@ -1246,8 +1243,6 @@ void export_curl_easy_getinfo(PPCInterpreter_t* hCPU) osLib_returnFromFunction(hCPU, result); } - - void export_curl_global_init(PPCInterpreter_t* hCPU) { ppcDefineParamU32(flags, 0); diff --git a/src/Cemu/PPCAssembler/ppcAssembler.cpp b/src/Cemu/PPCAssembler/ppcAssembler.cpp index 5bab7b8b1..02f8328e8 100644 --- a/src/Cemu/PPCAssembler/ppcAssembler.cpp +++ b/src/Cemu/PPCAssembler/ppcAssembler.cpp @@ -320,7 +320,6 @@ const char* ppcAssembler_getInstructionName(uint32 ppcAsmOp) case PPCASM_OP_CRMOVE: return "CRMOVE"; case PPCASM_OP_CRNOT: return "CRNOT"; - default: return "UNDEF"; } diff --git a/src/Cemu/napi/napi.h b/src/Cemu/napi/napi.h index ab17a7b30..c41bbf671 100644 --- a/src/Cemu/napi/napi.h +++ b/src/Cemu/napi/napi.h @@ -43,7 +43,6 @@ namespace NAPI // ACT token (for account.nintendo.net requests) - }; bool NAPI_MakeAuthInfoFromCurrentAccount(AuthInfo& authInfo); // helper function. Returns false if online credentials/dumped files are not available diff --git a/src/Cemu/napi/napi_ec.cpp b/src/Cemu/napi/napi_ec.cpp index 9bc4bfbfb..2eb16eca8 100644 --- a/src/Cemu/napi/napi_ec.cpp +++ b/src/Cemu/napi/napi_ec.cpp @@ -273,7 +273,6 @@ namespace NAPI EUR */ - return result; } diff --git a/src/Cemu/napi/napi_helper.cpp b/src/Cemu/napi/napi_helper.cpp index 776baf339..cce0b8470 100644 --- a/src/Cemu/napi/napi_helper.cpp +++ b/src/Cemu/napi/napi_helper.cpp @@ -341,14 +341,12 @@ void CurlSOAPHelper::SOAP_generateEnvelope() //m_envelopeStr.append(fmt::format("<{}:Region>EUR", serviceType, serviceType)); //m_envelopeStr.append(fmt::format("<{}:Country>AT", serviceType, serviceType)); - // device token format: // WT- // unknown fields: // VirtualDeviceType (shared but optional?) - // device cert not needed for ECS:GetAccountStatus ? (it complains if present) //char deviceCertStr[1024 * 4]; //iosuCrypto_getDeviceCertificateBase64Encoded(deviceCertStr); @@ -362,7 +360,6 @@ void CurlSOAPHelper::SOAP_generateEnvelope() m_envelopeStr.append("\n"); m_envelopeStr.append("\n"); - } sint32 iosuCrypto_getDeviceCertificateBase64Encoded(char* output); diff --git a/src/Cemu/ncrypto/ncrypto.h b/src/Cemu/ncrypto/ncrypto.h index 51f3d9cb4..7132294b7 100644 --- a/src/Cemu/ncrypto/ncrypto.h +++ b/src/Cemu/ncrypto/ncrypto.h @@ -100,7 +100,6 @@ namespace NCrypto static_assert(sizeof(CertECC) == 0x180); - /* ETicket */ class ETicketParser // .tik parser diff --git a/src/Cemu/nex/nexFriends.cpp b/src/Cemu/nex/nexFriends.cpp index 4fae81438..898ef07bc 100644 --- a/src/Cemu/nex/nexFriends.cpp +++ b/src/Cemu/nex/nexFriends.cpp @@ -645,7 +645,6 @@ int NexFriends::getPendingFriendRequestCount() return (int)this->list_friendReqIncoming.size(); } - bool NexFriends::getFriendByPID(nexFriend& friendData, uint32 searchedPid) { std::unique_lock listLock(this->mtx_lists); diff --git a/src/asm/x64util_masm.asm b/src/asm/x64util_masm.asm index 2587c786d..161453eea 100644 --- a/src/asm/x64util_masm.asm +++ b/src/asm/x64util_masm.asm @@ -228,6 +228,4 @@ DD 01f12000h, 0332h DD 01d79000h, 030ah DD 01bf4000h, 02e6h - - END \ No newline at end of file diff --git a/src/input/api/Wiimote/hidapi/HidapiWiimote.cpp b/src/input/api/Wiimote/hidapi/HidapiWiimote.cpp index db1856754..a5701f56b 100644 --- a/src/input/api/Wiimote/hidapi/HidapiWiimote.cpp +++ b/src/input/api/Wiimote/hidapi/HidapiWiimote.cpp @@ -1,11 +1,9 @@ #include "HidapiWiimote.h" -#include static constexpr uint16 WIIMOTE_VENDOR_ID = 0x057e; static constexpr uint16 WIIMOTE_PRODUCT_ID = 0x0306; static constexpr uint16 WIIMOTE_MP_PRODUCT_ID = 0x0330; static constexpr uint16 WIIMOTE_MAX_INPUT_REPORT_LENGTH = 22; -static constexpr auto PRO_CONTROLLER_NAME = L"Nintendo RVL-CNT-01-UC"; HidapiWiimote::HidapiWiimote(hid_device* dev, std::string_view path) : m_handle(dev), m_path(path) { @@ -32,8 +30,6 @@ std::vector HidapiWiimote::get_devices() { for (auto it = device_enumeration; it != nullptr; it = it->next){ if (it->product_id != WIIMOTE_PRODUCT_ID && it->product_id != WIIMOTE_MP_PRODUCT_ID) continue; - if (std::wcscmp(it->product_string, PRO_CONTROLLER_NAME) == 0) - continue; auto dev = hid_open_path(it->path); if (!dev){ cemuLog_logDebug(LogType::Force, "Unable to open Wiimote device at {}: {}", it->path, boost::nowide::narrow(hid_error(nullptr)));