diff options
Diffstat (limited to 'llvm')
| -rw-r--r-- | llvm/include/llvm/CodeGen/FastISel.h | 6 | ||||
| -rw-r--r-- | llvm/lib/Target/X86/X86FastISel.cpp | 6 |
2 files changed, 7 insertions, 5 deletions
diff --git a/llvm/include/llvm/CodeGen/FastISel.h b/llvm/include/llvm/CodeGen/FastISel.h index 95280c9474a..6ac401d2409 100644 --- a/llvm/include/llvm/CodeGen/FastISel.h +++ b/llvm/include/llvm/CodeGen/FastISel.h @@ -227,8 +227,10 @@ protected: unsigned createResultReg(const TargetRegisterClass *RC); - virtual unsigned TargetSelectConstantPoolLoad(Constant* C, - MachineConstantPool* MCP) { + /// TargetMaterializeConstant - Emit a constant in a register using + /// target-specific logic, such as constant pool loads. + virtual unsigned TargetMaterializeConstant(Constant* C, + MachineConstantPool* MCP) { return 0; } diff --git a/llvm/lib/Target/X86/X86FastISel.cpp b/llvm/lib/Target/X86/X86FastISel.cpp index 37640bb4780..e63120d40e4 100644 --- a/llvm/lib/Target/X86/X86FastISel.cpp +++ b/llvm/lib/Target/X86/X86FastISel.cpp @@ -61,7 +61,7 @@ private: bool X86SelectSelect(Instruction *I); - unsigned TargetSelectConstantPoolLoad(Constant *C, MachineConstantPool* MCP); + unsigned TargetMaterializeConstant(Constant *C, MachineConstantPool* MCP); }; /// X86SelectConstAddr - Select and emit code to materialize constant address. @@ -549,8 +549,8 @@ X86FastISel::TargetSelectInstruction(Instruction *I) { return false; } -unsigned X86FastISel::TargetSelectConstantPoolLoad(Constant *C, - MachineConstantPool* MCP) { +unsigned X86FastISel::TargetMaterializeConstant(Constant *C, + MachineConstantPool* MCP) { unsigned CPLoad = getRegForValue(C); if (CPLoad != 0) return CPLoad; |

