[llvm] c2bcb21 - [RISCV] Print Zfa fli instruction FP values in a more adaptive way.
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 10 07:58:17 PST 2023
Author: Craig Topper
Date: 2023-03-10T07:57:44-08:00
New Revision: c2bcb21cc6be5dabaadd3bc2ecc5df98ab77b59e
URL: https://github.com/llvm/llvm-project/commit/c2bcb21cc6be5dabaadd3bc2ecc5df98ab77b59e
DIFF: https://github.com/llvm/llvm-project/commit/c2bcb21cc6be5dabaadd3bc2ecc5df98ab77b59e.diff
LOG: [RISCV] Print Zfa fli instruction FP values in a more adaptive way.
Previously, we printed all constants in scientific notation with
6 digits of precision. This is not enough to accurately display
the smallest value, but increasing the precision would be too much
for other values.
This patch prints values with fractional bits using only as many digits as
needed. 1*2^-15 and 1*2^-16 will be printed in scientific notation while
the others are printed without scientific notation. The integer values
are printed with a single 0 after the decimal point.
Reviewed By: reames
Differential Revision: https://reviews.llvm.org/D145645
Added:
Modified:
llvm/lib/Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp
llvm/test/CodeGen/RISCV/double-zfa.ll
llvm/test/CodeGen/RISCV/float-zfa.ll
llvm/test/CodeGen/RISCV/half-zfa-fli.ll
llvm/test/MC/RISCV/zfa-valid.s
Removed:
################################################################################
diff --git a/llvm/lib/Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp b/llvm/lib/Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp
index e54f71279e7e9..becd8aaf6bb91 100644
--- a/llvm/lib/Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp
+++ b/llvm/lib/Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp
@@ -157,15 +157,24 @@ void RISCVInstPrinter::printFRMArg(const MCInst *MI, unsigned OpNo,
void RISCVInstPrinter::printFPImmOperand(const MCInst *MI, unsigned OpNo,
const MCSubtargetInfo &STI,
raw_ostream &O) {
- const MCOperand &MO = MI->getOperand(OpNo);
- if (MO.getImm() == 1)
+ unsigned Imm = MI->getOperand(OpNo).getImm();
+ if (Imm == 1) {
O << "min";
- else if (MO.getImm() == 30)
+ } else if (Imm == 30) {
O << "inf";
- else if (MO.getImm() == 31)
+ } else if (Imm == 31) {
O << "nan";
- else
- O << RISCVLoadFPImm::getFPImm(MO.getImm());
+ } else {
+ float FPVal = RISCVLoadFPImm::getFPImm(Imm);
+ // If the value is an integer, print a .0 fraction. Otherwise, use %g to
+ // which will not print trailing zeros and will use scientific notation
+ // if it is shorter than printing as a decimal. The smallest value requires
+ // 12 digits of precision including the decimal.
+ if (FPVal == (int)(FPVal))
+ O << format("%.1f", FPVal);
+ else
+ O << format("%.12g", FPVal);
+ }
}
void RISCVInstPrinter::printZeroOffsetMemOp(const MCInst *MI, unsigned OpNo,
diff --git a/llvm/test/CodeGen/RISCV/double-zfa.ll b/llvm/test/CodeGen/RISCV/double-zfa.ll
index 8bbe5e59ccbbc..eb077b3a144cc 100644
--- a/llvm/test/CodeGen/RISCV/double-zfa.ll
+++ b/llvm/test/CodeGen/RISCV/double-zfa.ll
@@ -7,7 +7,7 @@
define double @loadfpimm1() {
; CHECK-LABEL: loadfpimm1:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.d fa0, 6.250000e-02
+; CHECK-NEXT: fli.d fa0, 0.0625
; CHECK-NEXT: ret
ret double 0.0625
}
@@ -15,7 +15,7 @@ define double @loadfpimm1() {
define double @loadfpimm2() {
; CHECK-LABEL: loadfpimm2:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.d fa0, 7.500000e-01
+; CHECK-NEXT: fli.d fa0, 0.75
; CHECK-NEXT: ret
ret double 0.75
}
@@ -23,7 +23,7 @@ define double @loadfpimm2() {
define double @loadfpimm3() {
; CHECK-LABEL: loadfpimm3:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.d fa0, 1.250000e+00
+; CHECK-NEXT: fli.d fa0, 1.25
; CHECK-NEXT: ret
ret double 1.25
}
@@ -31,7 +31,7 @@ define double @loadfpimm3() {
define double @loadfpimm4() {
; CHECK-LABEL: loadfpimm4:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.d fa0, 3.000000e+00
+; CHECK-NEXT: fli.d fa0, 3.0
; CHECK-NEXT: ret
ret double 3.0
}
@@ -39,7 +39,7 @@ define double @loadfpimm4() {
define double @loadfpimm5() {
; CHECK-LABEL: loadfpimm5:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.d fa0, 2.560000e+02
+; CHECK-NEXT: fli.d fa0, 256.0
; CHECK-NEXT: ret
ret double 256.0
}
diff --git a/llvm/test/CodeGen/RISCV/float-zfa.ll b/llvm/test/CodeGen/RISCV/float-zfa.ll
index ab85ad0a8b38d..f6066041be3f8 100644
--- a/llvm/test/CodeGen/RISCV/float-zfa.ll
+++ b/llvm/test/CodeGen/RISCV/float-zfa.ll
@@ -7,7 +7,7 @@
define float @loadfpimm1() {
; CHECK-LABEL: loadfpimm1:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.s fa0, 6.250000e-02
+; CHECK-NEXT: fli.s fa0, 0.0625
; CHECK-NEXT: ret
ret float 0.0625
}
@@ -15,7 +15,7 @@ define float @loadfpimm1() {
define float @loadfpimm2() {
; CHECK-LABEL: loadfpimm2:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.s fa0, 7.500000e-01
+; CHECK-NEXT: fli.s fa0, 0.75
; CHECK-NEXT: ret
ret float 0.75
}
@@ -23,7 +23,7 @@ define float @loadfpimm2() {
define float @loadfpimm3() {
; CHECK-LABEL: loadfpimm3:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.s fa0, 1.250000e+00
+; CHECK-NEXT: fli.s fa0, 1.25
; CHECK-NEXT: ret
ret float 1.25
}
@@ -31,7 +31,7 @@ define float @loadfpimm3() {
define float @loadfpimm4() {
; CHECK-LABEL: loadfpimm4:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.s fa0, 3.000000e+00
+; CHECK-NEXT: fli.s fa0, 3.0
; CHECK-NEXT: ret
ret float 3.0
}
@@ -39,7 +39,7 @@ define float @loadfpimm4() {
define float @loadfpimm5() {
; CHECK-LABEL: loadfpimm5:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.s fa0, 2.560000e+02
+; CHECK-NEXT: fli.s fa0, 256.0
; CHECK-NEXT: ret
ret float 256.0
}
diff --git a/llvm/test/CodeGen/RISCV/half-zfa-fli.ll b/llvm/test/CodeGen/RISCV/half-zfa-fli.ll
index c1445ab638f58..36c49da75d900 100644
--- a/llvm/test/CodeGen/RISCV/half-zfa-fli.ll
+++ b/llvm/test/CodeGen/RISCV/half-zfa-fli.ll
@@ -11,7 +11,7 @@
define half @loadfpimm1() {
; CHECK-LABEL: loadfpimm1:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.h fa0, 6.250000e-02
+; CHECK-NEXT: fli.h fa0, 0.0625
; CHECK-NEXT: ret
;
; ZFHMIN-LABEL: loadfpimm1:
@@ -25,7 +25,7 @@ define half @loadfpimm1() {
define half @loadfpimm2() {
; CHECK-LABEL: loadfpimm2:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.h fa0, 7.500000e-01
+; CHECK-NEXT: fli.h fa0, 0.75
; CHECK-NEXT: ret
;
; ZFHMIN-LABEL: loadfpimm2:
@@ -39,7 +39,7 @@ define half @loadfpimm2() {
define half @loadfpimm3() {
; CHECK-LABEL: loadfpimm3:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.h fa0, 1.250000e+00
+; CHECK-NEXT: fli.h fa0, 1.25
; CHECK-NEXT: ret
;
; ZFHMIN-LABEL: loadfpimm3:
@@ -53,7 +53,7 @@ define half @loadfpimm3() {
define half @loadfpimm4() {
; CHECK-LABEL: loadfpimm4:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.h fa0, 3.000000e+00
+; CHECK-NEXT: fli.h fa0, 3.0
; CHECK-NEXT: ret
;
; ZFHMIN-LABEL: loadfpimm4:
@@ -67,7 +67,7 @@ define half @loadfpimm4() {
define half @loadfpimm5() {
; CHECK-LABEL: loadfpimm5:
; CHECK: # %bb.0:
-; CHECK-NEXT: fli.h fa0, 2.560000e+02
+; CHECK-NEXT: fli.h fa0, 256.0
; CHECK-NEXT: ret
;
; ZFHMIN-LABEL: loadfpimm5:
diff --git a/llvm/test/MC/RISCV/zfa-valid.s b/llvm/test/MC/RISCV/zfa-valid.s
index 3ee736cd507f6..6892a7a5b0b0e 100644
--- a/llvm/test/MC/RISCV/zfa-valid.s
+++ b/llvm/test/MC/RISCV/zfa-valid.s
@@ -16,7 +16,7 @@
# RUN: -riscv-no-aliases -show-encoding < %s 2>&1 \
# RUN: | FileCheck -check-prefixes=CHECK-NO-EXT %s
-# CHECK-ASM-AND-OBJ: fli.s ft1, -1.000000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, -1.0
# CHECK-ASM: encoding: [0xd3,0x00,0x10,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, -1.000000e+00
@@ -26,142 +26,142 @@ fli.s ft1, -1.000000e+00
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, min
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.525879e-05
+# CHECK-ASM-AND-OBJ: fli.s ft1, 1.52587890625e-05
# CHECK-ASM: encoding: [0xd3,0x00,0x11,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.52587890625e-05
-# CHECK-ASM-AND-OBJ: fli.s ft1, 3.051758e-05
+# CHECK-ASM-AND-OBJ: fli.s ft1, 3.0517578125e-05
# CHECK-ASM: encoding: [0xd3,0x80,0x11,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 3.0517578125e-05
-# CHECK-ASM-AND-OBJ: fli.s ft1, 3.906250e-03
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.00390625
# CHECK-ASM: encoding: [0xd3,0x00,0x12,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 3.906250e-03
-# CHECK-ASM-AND-OBJ: fli.s ft1, 7.812500e-03
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.0078125
# CHECK-ASM: encoding: [0xd3,0x80,0x12,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 7.812500e-03
-# CHECK-ASM-AND-OBJ: fli.s ft1, 6.250000e-02
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.0625
# CHECK-ASM: encoding: [0xd3,0x00,0x13,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 6.250000e-02
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.250000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.125
# CHECK-ASM: encoding: [0xd3,0x80,0x13,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.250000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 2.500000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.25
# CHECK-ASM: encoding: [0xd3,0x00,0x14,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 2.500000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 3.125000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.3125
# CHECK-ASM: encoding: [0xd3,0x80,0x14,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 3.125000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 3.750000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.375
# CHECK-ASM: encoding: [0xd3,0x00,0x15,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 3.750000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 4.375000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.4375
# CHECK-ASM: encoding: [0xd3,0x80,0x15,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 4.375000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 5.000000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.5
# CHECK-ASM: encoding: [0xd3,0x00,0x16,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 5.000000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 6.250000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.625
# CHECK-ASM: encoding: [0xd3,0x80,0x16,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 6.250000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 7.500000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.75
# CHECK-ASM: encoding: [0xd3,0x00,0x17,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 7.500000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 8.750000e-01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 0.875
# CHECK-ASM: encoding: [0xd3,0x80,0x17,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 8.750000e-01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.000000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 1.0
# CHECK-ASM: encoding: [0xd3,0x00,0x18,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.000000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.250000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 1.25
# CHECK-ASM: encoding: [0xd3,0x80,0x18,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.250000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.500000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 1.5
# CHECK-ASM: encoding: [0xd3,0x00,0x19,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.500000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.750000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 1.75
# CHECK-ASM: encoding: [0xd3,0x80,0x19,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.750000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 2.000000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 2.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1a,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 2.000000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 2.500000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 2.5
# CHECK-ASM: encoding: [0xd3,0x80,0x1a,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 2.500000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 3.000000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 3.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1b,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 3.000000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 4.000000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 4.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1b,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 4.000000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 8.000000e+00
+# CHECK-ASM-AND-OBJ: fli.s ft1, 8.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1c,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 8.000000e+00
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.600000e+01
+# CHECK-ASM-AND-OBJ: fli.s ft1, 16.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1c,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.600000e+01
-# CHECK-ASM-AND-OBJ: fli.s ft1, 1.280000e+02
+# CHECK-ASM-AND-OBJ: fli.s ft1, 128.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1d,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 1.280000e+02
-# CHECK-ASM-AND-OBJ: fli.s ft1, 2.560000e+02
+# CHECK-ASM-AND-OBJ: fli.s ft1, 256.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1d,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 2.560000e+02
-# CHECK-ASM-AND-OBJ: fli.s ft1, 3.276800e+04
+# CHECK-ASM-AND-OBJ: fli.s ft1, 32768.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1e,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 3.276800e+04
-# CHECK-ASM-AND-OBJ: fli.s ft1, 6.553600e+04
+# CHECK-ASM-AND-OBJ: fli.s ft1, 65536.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1e,0xf0]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, 6.553600e+04
@@ -176,7 +176,7 @@ fli.s ft1, INF
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.s ft1, nan
-# CHECK-ASM-AND-OBJ: fli.d ft1, -1.000000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, -1.0
# CHECK-ASM: encoding: [0xd3,0x00,0x10,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, -1.000000e+00
@@ -186,142 +186,142 @@ fli.d ft1, -1.000000e+00
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, min
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.525879e-05
+# CHECK-ASM-AND-OBJ: fli.d ft1, 1.52587890625e-05
# CHECK-ASM: encoding: [0xd3,0x00,0x11,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.52587890625e-05
-# CHECK-ASM-AND-OBJ: fli.d ft1, 3.051758e-05
+# CHECK-ASM-AND-OBJ: fli.d ft1, 3.0517578125e-05
# CHECK-ASM: encoding: [0xd3,0x80,0x11,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 3.0517578125e-05
-# CHECK-ASM-AND-OBJ: fli.d ft1, 3.906250e-03
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.00390625
# CHECK-ASM: encoding: [0xd3,0x00,0x12,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 3.906250e-03
-# CHECK-ASM-AND-OBJ: fli.d ft1, 7.812500e-03
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.0078125
# CHECK-ASM: encoding: [0xd3,0x80,0x12,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 7.812500e-03
-# CHECK-ASM-AND-OBJ: fli.d ft1, 6.250000e-02
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.0625
# CHECK-ASM: encoding: [0xd3,0x00,0x13,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 6.250000e-02
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.250000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.125
# CHECK-ASM: encoding: [0xd3,0x80,0x13,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.250000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 2.500000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.25
# CHECK-ASM: encoding: [0xd3,0x00,0x14,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 2.500000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 3.125000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.3125
# CHECK-ASM: encoding: [0xd3,0x80,0x14,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 3.125000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 3.750000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.375
# CHECK-ASM: encoding: [0xd3,0x00,0x15,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 3.750000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 4.375000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.4375
# CHECK-ASM: encoding: [0xd3,0x80,0x15,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 4.375000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 5.000000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.5
# CHECK-ASM: encoding: [0xd3,0x00,0x16,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 5.000000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 6.250000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.625
# CHECK-ASM: encoding: [0xd3,0x80,0x16,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 6.250000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 7.500000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.75
# CHECK-ASM: encoding: [0xd3,0x00,0x17,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 7.500000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 8.750000e-01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 0.875
# CHECK-ASM: encoding: [0xd3,0x80,0x17,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 8.750000e-01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.000000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 1.0
# CHECK-ASM: encoding: [0xd3,0x00,0x18,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.000000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.250000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 1.25
# CHECK-ASM: encoding: [0xd3,0x80,0x18,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.250000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.500000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 1.5
# CHECK-ASM: encoding: [0xd3,0x00,0x19,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.500000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.750000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 1.75
# CHECK-ASM: encoding: [0xd3,0x80,0x19,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.750000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 2.000000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 2.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1a,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 2.000000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 2.500000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 2.5
# CHECK-ASM: encoding: [0xd3,0x80,0x1a,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 2.500000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 3.000000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 3.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1b,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 3.000000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 4.000000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 4.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1b,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 4.000000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 8.000000e+00
+# CHECK-ASM-AND-OBJ: fli.d ft1, 8.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1c,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 8.000000e+00
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.600000e+01
+# CHECK-ASM-AND-OBJ: fli.d ft1, 16.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1c,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.600000e+01
-# CHECK-ASM-AND-OBJ: fli.d ft1, 1.280000e+02
+# CHECK-ASM-AND-OBJ: fli.d ft1, 128.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1d,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 1.280000e+02
-# CHECK-ASM-AND-OBJ: fli.d ft1, 2.560000e+02
+# CHECK-ASM-AND-OBJ: fli.d ft1, 256.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1d,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 2.560000e+02
-# CHECK-ASM-AND-OBJ: fli.d ft1, 3.276800e+04
+# CHECK-ASM-AND-OBJ: fli.d ft1, 32768.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1e,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 3.276800e+04
-# CHECK-ASM-AND-OBJ: fli.d ft1, 6.553600e+04
+# CHECK-ASM-AND-OBJ: fli.d ft1, 65536.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1e,0xf2]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, 6.553600e+04
@@ -336,7 +336,7 @@ fli.d ft1, INF
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.d ft1, nan
-# CHECK-ASM-AND-OBJ: fli.h ft1, -1.000000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, -1.0
# CHECK-ASM: encoding: [0xd3,0x00,0x10,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, -1.000000e+00
@@ -346,142 +346,142 @@ fli.h ft1, -1.000000e+00
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, min
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.525879e-05
+# CHECK-ASM-AND-OBJ: fli.h ft1, 1.52587890625e-05
# CHECK-ASM: encoding: [0xd3,0x00,0x11,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.52587890625e-05
-# CHECK-ASM-AND-OBJ: fli.h ft1, 3.051758e-05
+# CHECK-ASM-AND-OBJ: fli.h ft1, 3.0517578125e-05
# CHECK-ASM: encoding: [0xd3,0x80,0x11,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 3.0517578125e-05
-# CHECK-ASM-AND-OBJ: fli.h ft1, 3.906250e-03
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.00390625
# CHECK-ASM: encoding: [0xd3,0x00,0x12,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 3.906250e-03
-# CHECK-ASM-AND-OBJ: fli.h ft1, 7.812500e-03
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.0078125
# CHECK-ASM: encoding: [0xd3,0x80,0x12,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 7.812500e-03
-# CHECK-ASM-AND-OBJ: fli.h ft1, 6.250000e-02
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.0625
# CHECK-ASM: encoding: [0xd3,0x00,0x13,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 6.250000e-02
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.250000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.125
# CHECK-ASM: encoding: [0xd3,0x80,0x13,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.250000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 2.500000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.25
# CHECK-ASM: encoding: [0xd3,0x00,0x14,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 2.500000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 3.125000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.3125
# CHECK-ASM: encoding: [0xd3,0x80,0x14,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 3.125000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 3.750000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.375
# CHECK-ASM: encoding: [0xd3,0x00,0x15,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 3.750000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 4.375000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.4375
# CHECK-ASM: encoding: [0xd3,0x80,0x15,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 4.375000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 5.000000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.5
# CHECK-ASM: encoding: [0xd3,0x00,0x16,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 5.000000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 6.250000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.625
# CHECK-ASM: encoding: [0xd3,0x80,0x16,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 6.250000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 7.500000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.75
# CHECK-ASM: encoding: [0xd3,0x00,0x17,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 7.500000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 8.750000e-01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 0.875
# CHECK-ASM: encoding: [0xd3,0x80,0x17,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 8.750000e-01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.000000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 1.0
# CHECK-ASM: encoding: [0xd3,0x00,0x18,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.000000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.250000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 1.25
# CHECK-ASM: encoding: [0xd3,0x80,0x18,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.250000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.500000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 1.5
# CHECK-ASM: encoding: [0xd3,0x00,0x19,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.500000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.750000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 1.75
# CHECK-ASM: encoding: [0xd3,0x80,0x19,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.750000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 2.000000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 2.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1a,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 2.000000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 2.500000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 2.5
# CHECK-ASM: encoding: [0xd3,0x80,0x1a,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 2.500000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 3.000000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 3.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1b,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 3.000000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 4.000000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 4.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1b,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 4.000000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 8.000000e+00
+# CHECK-ASM-AND-OBJ: fli.h ft1, 8.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1c,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 8.000000e+00
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.600000e+01
+# CHECK-ASM-AND-OBJ: fli.h ft1, 16.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1c,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.600000e+01
-# CHECK-ASM-AND-OBJ: fli.h ft1, 1.280000e+02
+# CHECK-ASM-AND-OBJ: fli.h ft1, 128.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1d,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 1.280000e+02
-# CHECK-ASM-AND-OBJ: fli.h ft1, 2.560000e+02
+# CHECK-ASM-AND-OBJ: fli.h ft1, 256.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1d,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 2.560000e+02
-# CHECK-ASM-AND-OBJ: fli.h ft1, 3.276800e+04
+# CHECK-ASM-AND-OBJ: fli.h ft1, 32768.0
# CHECK-ASM: encoding: [0xd3,0x00,0x1e,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 3.276800e+04
-# CHECK-ASM-AND-OBJ: fli.h ft1, 6.553600e+04
+# CHECK-ASM-AND-OBJ: fli.h ft1, 65536.0
# CHECK-ASM: encoding: [0xd3,0x80,0x1e,0xf4]
# CHECK-NO-EXT: error: instruction requires the following: 'Zfa' (Additional Floating-Point){{$}}
fli.h ft1, 6.553600e+04
More information about the llvm-commits
mailing list