aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Target/PowerPC/README.txt17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/Target/PowerPC/README.txt b/lib/Target/PowerPC/README.txt
index e5cf75d3be..1b05e7c4f0 100644
--- a/lib/Target/PowerPC/README.txt
+++ b/lib/Target/PowerPC/README.txt
@@ -460,3 +460,20 @@ In particular, the two compares (marked 1) could be shared by reversing one.
This could be done in the dag combiner, by swapping a BR_CC when a SETCC of the
same operands (but backwards) exists. In this case, this wouldn't save us
anything though, because the compares still wouldn't be shared.
+
+===-------------------------------------------------------------------------===
+
+A simple case we generate suboptimal code on:
+
+int test(int X) {
+ return X == 0 ? 32 : 0;
+}
+
+_test:
+ cntlzw r2, r3
+ srwi r2, r2, 5
+ slwi r3, r2, 5
+ blr
+
+The shifts should be one 'andi'.
+