1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 19:42:54 +02:00
llvm-mirror/lib/CodeGen/SelectionDAG
Sanjay Patel 6ce96b0ff0 fix an invisible bug when combining repeated FP divisors
This patch fixes bugs that were exposed by the addition of fast-math-flags in the DAG:
r237046 ( http://reviews.llvm.org/rL237046 ):

1. When replacing a division node, it's not enough to RAUW.
   We should call CombineTo() to delete dead nodes and combine again.
2. Because we are changing the DAG, we can't return an empty SDValue
   after the transform. As the code comments say:

    Visitation implementation - Implement dag node combining for different node types.
    The semantics are as follows: Return Value:
      SDValue.getNode() == 0 - No change was made
      SDValue.getNode() == N - N was replaced, is dead and has been handled.
      otherwise - N should be replaced by the returned Operand.

The new test case shows no difference with or without this patch, but it will crash if
we re-apply r237046 or enable FMF via the current -enable-fmf-dag cl::opt.

Differential Revision: http://reviews.llvm.org/D9893

llvm-svn: 241826
2015-07-09 17:28:37 +00:00
..
CMakeLists.txt
DAGCombiner.cpp fix an invisible bug when combining repeated FP divisors 2015-07-09 17:28:37 +00:00
FastISel.cpp Make getByValTypeAlignment() taking DataLayout as an argument 2015-07-09 02:09:28 +00:00
FunctionLoweringInfo.cpp Redirect DataLayout from TargetMachine to Module in ComputeValueVTs() 2015-07-09 01:57:34 +00:00
InstrEmitter.cpp Redirect DataLayout from TargetMachine to Module in SelectionDAG 2015-07-07 19:07:19 +00:00
InstrEmitter.h [SDAG] Give InstrEmitter hidden visibility 2015-07-01 14:55:10 +00:00
LegalizeDAG.cpp Make TargetLowering::getShiftAmountTy() taking DataLayout as an argument 2015-07-09 02:09:20 +00:00
LegalizeFloatTypes.cpp Make TargetLowering::getShiftAmountTy() taking DataLayout as an argument 2015-07-09 02:09:20 +00:00
LegalizeIntegerTypes.cpp Reapply fixed r241790: Fix shift legalization and lowering for big constants. 2015-07-09 14:58:04 +00:00
LegalizeTypes.cpp Make TargetLowering::getPointerTy() taking DataLayout as an argument 2015-07-09 02:09:04 +00:00
LegalizeTypes.h Reapply fixed r241790: Fix shift legalization and lowering for big constants. 2015-07-09 14:58:04 +00:00
LegalizeTypesGeneric.cpp Make TargetLowering::getPointerTy() taking DataLayout as an argument 2015-07-09 02:09:04 +00:00
LegalizeVectorOps.cpp Make TargetLowering::getShiftAmountTy() taking DataLayout as an argument 2015-07-09 02:09:20 +00:00
LegalizeVectorTypes.cpp Make TargetLowering::getPointerTy() taking DataLayout as an argument 2015-07-09 02:09:04 +00:00
LLVMBuild.txt
Makefile
ResourcePriorityQueue.cpp unique_ptrify ResourcePriorityQueue::ResourceModel 2015-03-03 20:49:08 +00:00
ScheduleDAGFast.cpp Convert a bunch of loops to foreach. NFC. 2015-06-26 19:18:49 +00:00
ScheduleDAGRRList.cpp Convert a bunch of loops to foreach. NFC. 2015-06-26 19:18:49 +00:00
ScheduleDAGSDNodes.cpp Convert a bunch of loops to foreach. NFC. 2015-06-26 19:18:49 +00:00
ScheduleDAGSDNodes.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
ScheduleDAGVLIW.cpp Use 'override/final' instead of 'virtual' for overridden methods 2015-04-11 02:11:45 +00:00
SDNodeDbgValue.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
SelectionDAG.cpp Remove getDataLayout() from TargetLowering 2015-07-09 02:09:52 +00:00
SelectionDAGBuilder.cpp Extended syntax of vector version of getelementptr instruction. 2015-07-09 07:42:48 +00:00
SelectionDAGBuilder.h Redirect DataLayout from TargetMachine to Module in ComputeValueVTs() 2015-07-09 01:57:34 +00:00
SelectionDAGDumper.cpp Rename llvm.frameescape and llvm.framerecover to localescape and localrecover 2015-07-07 22:25:32 +00:00
SelectionDAGISel.cpp Make TargetLowering::getPointerTy() taking DataLayout as an argument 2015-07-09 02:09:04 +00:00
SelectionDAGPrinter.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
StatepointLowering.cpp Redirect DataLayout from TargetMachine to Module in ComputeValueVTs() 2015-07-09 01:57:34 +00:00
StatepointLowering.h [StatepointLowering] Support of the gc.relocates for invoke statepoints. 2015-05-20 11:37:25 +00:00
TargetLowering.cpp Make TargetLowering::getShiftAmountTy() taking DataLayout as an argument 2015-07-09 02:09:20 +00:00
TargetSelectionDAGInfo.cpp Remove getDataLayout() from TargetSelectionDAGInfo (had no users) 2015-07-09 02:10:08 +00:00