various decomp cleanups (#4247)

Removed a bunch of stuff, old scripts, cleaned up some decompiler
errors, added a new tool that should help with a future PR
This commit is contained in:
Tyler Wilding
2026-04-25 23:35:19 -04:00
committed by GitHub
parent 67cd649cb9
commit 6238f7f567
1172 changed files with 27995 additions and 36769 deletions
@@ -18,6 +18,7 @@
#include "fmt/format.h"
#include "third-party/json.hpp"
#include "third-party/zstd/lib/common/xxhash.h"
namespace decompiler {
/*!
@@ -710,6 +711,21 @@ std::string LinkedObjectFile::print_asm_function_disassembly(const std::string&
return result;
}
// Currently, just hashes the contents of every function, this makes it easy to
// compare between games to see if something is identical
void LinkedObjectFile::dump_asm_function_metadata(
std::unordered_map<std::string, std::string>& map) {
ASSERT(segments <= 3);
for (int seg = segments; seg-- > 0;) {
// functions
for (auto& func : functions_by_seg.at(seg)) {
const auto& function_rep = print_function_disassembly(func, seg, false, "");
const auto func_hash = XXH64(function_rep.data(), function_rep.size(), 0);
map.emplace(func.name(), fmt::format("{}", func_hash));
}
}
}
/*!
* Print disassembled functions and data segments.
*/