Add proper transform pass management

This commit is contained in:
kd-11 2024-08-24 02:08:48 +03:00 committed by kd-11
parent 09ea858dbf
commit 4da30e9eca
4 changed files with 32 additions and 4 deletions

View file

@ -35,6 +35,8 @@ PPUTranslator::PPUTranslator(LLVMContext& context, Module* _module, const ppu_mo
cpu_translator::initialize(context, engine);
// Initialize transform passes
clear_transforms();
#ifdef ARCH_ARM64
{
// Base reg table definition
@ -63,6 +65,8 @@ PPUTranslator::PPUTranslator(LLVMContext& context, Module* _module, const ppu_mo
}
#endif
reset_transforms();
// Thread context struct (TODO: safer member access)
const u32 off0 = offset32(&ppu_thread::state);
const u32 off1 = offset32(&ppu_thread::gpr);