diff options
| author | Eric Christopher <echristo@gmail.com> | 2016-03-24 21:04:52 +0000 |
|---|---|---|
| committer | Eric Christopher <echristo@gmail.com> | 2016-03-24 21:04:52 +0000 |
| commit | b979d51afae8d9684e29884b8d12080399e0bbfa (patch) | |
| tree | f3531e6771b60bbd397cb0de948c279224f667bd /llvm/lib | |
| parent | 8c95d53d45961d1e0d9463b1c6285d01d96fe761 (diff) | |
| download | bcm5719-llvm-b979d51afae8d9684e29884b8d12080399e0bbfa.tar.gz bcm5719-llvm-b979d51afae8d9684e29884b8d12080399e0bbfa.zip | |
Finish the incomplete 'd' inline asm constraint support for PPC by
making sure we give it a register and mark it as a register constraint.
llvm-svn: 264340
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp index 70a22af9963..ac3523537a5 100644 --- a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp +++ b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp @@ -10828,6 +10828,7 @@ PPCTargetLowering::getConstraintType(StringRef Constraint) const { case 'b': case 'r': case 'f': + case 'd': case 'v': case 'y': return C_RegisterClass; @@ -10919,6 +10920,10 @@ PPCTargetLowering::getRegForInlineAsmConstraint(const TargetRegisterInfo *TRI, if (VT == MVT::i64 && Subtarget.isPPC64()) return std::make_pair(0U, &PPC::G8RCRegClass); return std::make_pair(0U, &PPC::GPRCRegClass); + // 'd' and 'f' constraints are both defined to be "the floating point + // registers", where one is for 32-bit and the other for 64-bit. We don't + // really care overly much here so just give them all the same reg classes. + case 'd': case 'f': if (VT == MVT::f32 || VT == MVT::i32) return std::make_pair(0U, &PPC::F4RCRegClass); |

