Quest: optimize compilation rules, adjust stack protection, and increase indirect dispatch cache size

This commit is contained in:
iChris4 committed 2026-09-19 03:18:07 +02:00
1 parent 7f2113dbc5
commit d296b3dcb3
4 files changed
+26 -3

No files matched your search

+4 -1
View File
@@ -303,7 +303,10 @@ struct KnownTypedNativeCpuCall {
// a miss just re-runs the sorted lookup. 512 entries (12 KiB) covers the per-frame indirect
// working set while staying L1/L2 resident, unlike 4096 which would thrash L2. Must stay a
// power of two, the index masks with (size - 1).
inline constexpr size_t kIndirectDispatchCacheEntries = 512;
// Direct-mapped by a hash of the target address. A race keeps a few thousand distinct indirect
// targets live, so 512 entries missed about one call in three on the Quest and fell into the
// table's binary search; 8192 entries are 128 KB per memo and fit the big cores' L2.
inline constexpr size_t kIndirectDispatchCacheEntries = 8192;
// Namespace-scope `inline thread_local`, not function-local `static thread_local`, to avoid a
// thread-static init epoch check on every bctrl (same as g_currentCpuContext in ppc_runtime.h).