llvm-project/llvm/lib
Ulrich Weigand 0d3f782e41 [FPEnv][X86] More strict int <-> FP conversion fixes
Fix several several additional problems with the int <-> FP conversion
logic both in common code and in the X86 target. In particular:

- The STRICT_FP_TO_UINT expansion emits a floating-point compare. This
  compare can raise exceptions and therefore needs to be a strict compare.
  I've made it signaling (even though quiet would also be correct) as
  signaling is the more usual default for an LT. This code exists both
  in common code and in the X86 target.

- The STRICT_UINT_TO_FP expansion algorithm was incorrect for strict mode:
  it emitted two STRICT_SINT_TO_FP nodes and then used a select to choose one
  of the results. This can cause spurious exceptions by the STRICT_SINT_TO_FP
  that ends up not chosen. I've fixed the algorithm to use only a single
  STRICT_SINT_TO_FP instead.

- The !isStrictFPEnabled logic in DoInstructionSelection would sometimes do
  the wrong thing because it calls getOperationAction using the result VT.
  But for some opcodes, incuding [SU]INT_TO_FP, getOperationAction needs to
  be called using the operand VT.

- Remove some (obsolete) code in X86DAGToDAGISel::Select that would mutate
  STRICT_FP_TO_[SU]INT to non-strict versions unnecessarily.

Reviewed by: craig.topper

Differential Revision: https://reviews.llvm.org/D71840
2019-12-23 21:11:45 +01:00
..
Analysis Temporarily revert "Reapply [LVI] Normalize pointer behavior" and "[LVI] Restructure caching" 2019-12-20 10:25:57 -08:00
AsmParser Rename DW_AT_LLVM_isysroot to DW_AT_LLVM_sysroot 2019-12-20 13:11:17 -08:00
BinaryFormat [AIX] Emit TOC entries for ASM printing 2019-11-27 17:20:55 -05:00
Bitcode [LTO] Support for embedding bitcode section during LTO 2019-12-12 12:34:19 -08:00
Bitstream [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
CodeGen [FPEnv][X86] More strict int <-> FP conversion fixes 2019-12-23 21:11:45 +01:00
DebugInfo [WebAssembly] Use TargetIndex operands in DbgValue to track WebAssembly operands locations 2019-12-20 14:39:05 -08:00
Demangle Revert "Add some missing includes to MicrosoftDemangle.cpp (PR44217)" 2019-12-04 11:10:07 -08:00
ExecutionEngine [ORC] De-register eh-frames in the RTDyldObjectLinkingLayer destructor. 2019-12-20 21:10:49 -08:00
Frontend [OpenMP] Introduce the OpenMP-IR-Builder 2019-12-11 14:38:49 -06:00
FuzzMutate [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
Fuzzer
IR Fix case style warnings in DIBuilder. NFC. 2019-12-23 07:27:18 +00:00
IRReader [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
LTO [ThinLTO] Show preserved symbols in DOT files 2019-12-18 18:33:15 +03:00
LineEditor [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
Linker [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
MC [NFC] Style cleanups 2019-12-23 17:02:36 +08:00
MCA [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
Object [WebAssembly] Add new `export_name` clang attribute for controlling wasm export names 2019-12-11 11:54:57 -08:00
ObjectYAML [yaml2obj] - Allow using an arbitrary value for OSABI. 2019-12-23 13:29:52 +03:00
Option [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
Passes [Matrix] Add first set of matrix intrinsics and initial lowering pass. 2019-12-12 15:42:18 +00:00
ProfileData Revert "[Coverage] Revise format to reduce binary size" 2019-12-04 10:35:14 -08:00
Remarks [Remarks] Allow empty temporary remark files 2019-11-22 15:58:12 -08:00
Support Fix LLVM tool --version build mode printing for MSVC 2019-12-23 10:02:01 -08:00
TableGen [TableGen] Add bang-operators !getop and !setop. 2019-12-11 12:05:22 +00:00
Target [FPEnv][X86] More strict int <-> FP conversion fixes 2019-12-23 21:11:45 +01:00
Testing
TextAPI [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
ToolDrivers [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
Transforms [Matrix] Use fmuladd for matrix.multiply if allowed. 2019-12-23 14:49:14 +01:00
WindowsManifest Revert "Temporarily revert "build: avoid hardcoding the libxml2 library name"" 2019-12-03 09:27:14 -08:00
XRay [cmake] Explicitly mark libraries defined in lib/ as "Component Libraries" 2019-11-21 10:48:08 -08:00
CMakeLists.txt [OpenMP][NFCI] Introduce llvm/IR/OpenMPConstants.h 2019-12-10 00:10:09 -06:00
LLVMBuild.txt [OpenMP][NFCI] Introduce llvm/IR/OpenMPConstants.h 2019-12-10 00:10:09 -06:00