[Sparc] Treat %fxx registers with value type Other as single precision

They get type Other when used in the clobber list in inline assembly.
This fixes tests fp128.ll and float.ll that failed after r333512.

llvm-svn: 333523
This commit is contained in:
Daniel Cederman 2018-05-30 09:52:18 +00:00
parent a0df7a9a4d
commit 248dae81dc
1 changed files with 1 additions and 1 deletions

View File

@ -3517,7 +3517,7 @@ SparcTargetLowering::getRegForInlineAsmConstraint(const TargetRegisterInfo *TRI,
!name.substr(1).getAsInteger(10, intVal) && intVal <= 63) {
std::string newConstraint;
if (VT == MVT::f32) {
if (VT == MVT::f32 || VT == MVT::Other) {
newConstraint = "{f" + utostr(intVal) + "}";
} else if (VT == MVT::f64 && (intVal % 2 == 0)) {
newConstraint = "{d" + utostr(intVal / 2) + "}";