mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-04 22:19:02 +00:00
Update LLVM to 18.1.8
This commit is contained in:
parent
ad6eba1670
commit
67703b49d8
16 changed files with 39 additions and 109 deletions
|
|
@ -40,19 +40,10 @@
|
|||
#endif
|
||||
#include <llvm/IR/Verifier.h>
|
||||
#include <llvm/Transforms/Utils/BasicBlockUtils.h>
|
||||
#if LLVM_VERSION_MAJOR < 17
|
||||
#include <llvm/Support/FormattedStream.h>
|
||||
#include <llvm/TargetParser/Host.h>
|
||||
#include <llvm/Object/ObjectFile.h>
|
||||
#include <llvm/IR/InstIterator.h>
|
||||
#include <llvm/IR/LegacyPassManager.h>
|
||||
#include <llvm/Transforms/Scalar.h>
|
||||
#else
|
||||
#include <llvm/Analysis/CGSCCPassManager.h>
|
||||
#include <llvm/Analysis/LoopAnalysisManager.h>
|
||||
#include <llvm/Passes/PassBuilder.h>
|
||||
#include <llvm/Transforms/Scalar/EarlyCSE.h>
|
||||
#endif
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(pop)
|
||||
#else
|
||||
|
|
@ -5615,29 +5606,6 @@ static void ppu_initialize2(jit_compiler& jit, const ppu_module<lv2_obj>& module
|
|||
translator.build_interpreter();
|
||||
}
|
||||
|
||||
#if LLVM_VERSION_MAJOR < 17
|
||||
legacy::FunctionPassManager pm(_module.get());
|
||||
|
||||
// Basic optimizations
|
||||
//pm.add(createCFGSimplificationPass());
|
||||
//pm.add(createPromoteMemoryToRegisterPass());
|
||||
pm.add(createEarlyCSEPass());
|
||||
//pm.add(createTailCallEliminationPass());
|
||||
//pm.add(createInstructionCombiningPass());
|
||||
//pm.add(createBasicAAWrapperPass());
|
||||
//pm.add(new MemoryDependenceAnalysis());
|
||||
//pm.add(createLICMPass());
|
||||
//pm.add(createLoopInstSimplifyPass());
|
||||
//pm.add(createNewGVNPass());
|
||||
//pm.add(createDeadStoreEliminationPass());
|
||||
//pm.add(createSCCPPass());
|
||||
//pm.add(createReassociatePass());
|
||||
//pm.add(createInstructionCombiningPass());
|
||||
//pm.add(createInstructionSimplifierPass());
|
||||
//pm.add(createAggressiveDCEPass());
|
||||
//pm.add(createCFGSimplificationPass());
|
||||
//pm.add(createLintPass()); // Check
|
||||
#else
|
||||
// Create the analysis managers.
|
||||
// These must be declared in this order so that they are destroyed in the
|
||||
// correct order due to inter-analysis-manager references.
|
||||
|
|
@ -5662,7 +5630,6 @@ static void ppu_initialize2(jit_compiler& jit, const ppu_module<lv2_obj>& module
|
|||
FunctionPassManager fpm;
|
||||
// Basic optimizations
|
||||
fpm.addPass(EarlyCSEPass());
|
||||
#endif
|
||||
|
||||
u32 guest_code_size = 0;
|
||||
u32 min_addr = umax;
|
||||
|
|
@ -5691,11 +5658,7 @@ static void ppu_initialize2(jit_compiler& jit, const ppu_module<lv2_obj>& module
|
|||
{
|
||||
#ifdef ARCH_X64 // TODO
|
||||
// Run optimization passes
|
||||
#if LLVM_VERSION_MAJOR < 17
|
||||
pm.run(*func);
|
||||
#else
|
||||
fpm.run(*func, fam);
|
||||
#endif
|
||||
#endif // ARCH_X64
|
||||
}
|
||||
else
|
||||
|
|
@ -5713,11 +5676,7 @@ static void ppu_initialize2(jit_compiler& jit, const ppu_module<lv2_obj>& module
|
|||
{
|
||||
#ifdef ARCH_X64 // TODO
|
||||
// Run optimization passes
|
||||
#if LLVM_VERSION_MAJOR < 17
|
||||
pm.run(*func);
|
||||
#else
|
||||
fpm.run(*func, fam);
|
||||
#endif
|
||||
#endif // ARCH_X64
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue