[PATCH] D21949: [SystemZ] Utilize Test Data Class instructions.
Marcin KoĆcielnicki via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 8 08:44:26 PDT 2016
koriakin added inline comments.
================
Comment at: lib/Target/SystemZ/SystemZTDC.cpp:141
@@ +140,3 @@
+ // Likewise for infinities.
+ WhichConst = Const->isNegative() ? 2 : 1;
+ } else if (Const->isExactlyValue(Smallest)) {
----------------
uweigand wrote:
> Do we need to check for impossible comparisons here (like x > inf)?
Not really - at worst we'll get an all-0 or all-1 TDC mask here, so there's no correctness problem. And such comparisons should be removed by earlier optimization passes, so there's no performance problem here either.
================
Comment at: lib/Target/SystemZ/SystemZTDC.cpp:165
@@ +164,3 @@
+ 0, 0xee0, 0x110, 0x00f, // -minnorm
+ };
+ // Construct the mask as a combination of the partial masks.
----------------
uweigand wrote:
> These mask constants are a bit hard to read. It would be nicer to define symbolic constants for the various TDC mask bits ...
OK, will do.
Repository:
rL LLVM
http://reviews.llvm.org/D21949
More information about the llvm-commits
mailing list