mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-14 14:24:05 +00:00
Add a floating point killer pass. This pass runs before register
allocaton on the X86 to add information to the machine code denoting that our floating point stackifier cannot handle virtual point register that are alive across basic blocks. This pass adds an implicit def of all virtual floating point register at the end of each basic block. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10446 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -76,6 +76,11 @@ bool X86TargetMachine::addPassesToEmitAssembly(PassManager &PM,
|
||||
if (PrintCode)
|
||||
PM.add(createMachineFunctionPrinterPass());
|
||||
|
||||
// kill floating point registers at the end of basic blocks. this is
|
||||
// done because the floating point register stackifier cannot handle
|
||||
// floating point regs that are live across basic blocks.
|
||||
PM.add(createX86FloatingPointKillerPass());
|
||||
|
||||
// Perform register allocation to convert to a concrete x86 representation
|
||||
PM.add(createRegisterAllocator());
|
||||
|
||||
@ -129,6 +134,11 @@ bool X86TargetMachine::addPassesToJITCompile(FunctionPassManager &PM) {
|
||||
if (PrintCode)
|
||||
PM.add(createMachineFunctionPrinterPass());
|
||||
|
||||
// kill floating point registers at the end of basic blocks. this is
|
||||
// done because the floating point register stackifier cannot handle
|
||||
// floating point regs that are live across basic blocks.
|
||||
PM.add(createX86FloatingPointKillerPass());
|
||||
|
||||
// Perform register allocation to convert to a concrete x86 representation
|
||||
PM.add(createRegisterAllocator());
|
||||
|
||||
|
Reference in New Issue
Block a user