[PATCH] Make it possible for ints/floats to return different values from getBooleanContents()

hfinkel at anl.gov hfinkel at anl.gov
Tue Jul 8 10:02:29 PDT 2014


================
Comment at: include/llvm/Target/TargetLowering.h:285
@@ -283,1 +284,3 @@
+  /// vectors instead of the way they treat scalars.
+  BooleanContent getBooleanContentsOLD(bool isVec) const {
     return isVec ? BooleanVectorContents : BooleanContents;
----------------
Please remove this (we don't need the OLD version any more).

================
Comment at: lib/CodeGen/SelectionDAG/DAGCombiner.cpp:4524
@@ -4523,1 +4523,3 @@
+  // We can't do this reliably if integer based booleans have different contents
+  // to floating point based booleans.
   if (VT.isInteger() &&
----------------
I'm missing something here... why not?

================
Comment at: lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp:265
@@ +264,3 @@
+  // If integer and float booleans have different contents then we can't
+  // reliably optimize in all cases.
+  if (TLI.getBooleanContents(false, false) !=
----------------
Again, please explain.

http://reviews.llvm.org/D4389






More information about the llvm-commits mailing list