From 95af34e33f9918dc8a399f8414ce6a9673bd5ffb Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Wed, 13 Sep 2006 03:54:54 +0000 Subject: [PATCH] new note git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30285 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/X86/README.txt | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/lib/Target/X86/README.txt b/lib/Target/X86/README.txt index 8994569ea9c..5e2ab199ad2 100644 --- a/lib/Target/X86/README.txt +++ b/lib/Target/X86/README.txt @@ -45,6 +45,19 @@ http://gcc.gnu.org/ml/gcc-patches/2004-09/msg01136.html Another useful one would be ~0ULL >> X and ~0ULL << X. +One better solution for 1LL << x is: + xorl %eax, %eax + xorl %edx, %edx + testb $32, %cl + sete %al + setne %dl + sall %cl, %eax + sall %cl, %edx + +But that requires good 8-bit subreg support. + + + //===---------------------------------------------------------------------===// Compile this: -- 2.34.1