aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-11-14 08:08:46 +0000
committerChris Lattner <sabre@nondot.org>2006-11-14 08:08:46 +0000
commit20ddd4a7ae3798fa65a2bc6e7258e3d4500ecbe9 (patch)
tree47bf433fed04f80f75648e4cb26cf068e90849b2
parente511b74f4aa0b74a0d1923beb8b95b966eed2050 (diff)
it would be nice of ctlz were lowered to bsf etc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31730 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Target/X86/README.txt9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/Target/X86/README.txt b/lib/Target/X86/README.txt
index 834a47c51b..629d30336b 100644
--- a/lib/Target/X86/README.txt
+++ b/lib/Target/X86/README.txt
@@ -114,6 +114,15 @@ ctz:
however, check that these are defined for 0 and 32. Our intrinsics are, GCC's
aren't.
+Another example (use predsimplify to eliminate a select):
+
+int foo (unsigned long j) {
+ if (j)
+ return __builtin_ffs (j) - 1;
+ else
+ return 0;
+}
+
//===---------------------------------------------------------------------===//
Use push/pop instructions in prolog/epilog sequences instead of stores off