a 21264 fix, and fix the operator precidence on an and -> zap check (should fix hundr...
authorAndrew Lenharth <andrewl@lenharth.org>
Thu, 14 Apr 2005 16:24:00 +0000 (16:24 +0000)
committerAndrew Lenharth <andrewl@lenharth.org>
Thu, 14 Apr 2005 16:24:00 +0000 (16:24 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21302 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/Alpha/AlphaAsmPrinter.cpp
lib/Target/Alpha/AlphaISelPattern.cpp

index 3e7d5e7bbcbf5de2624adde3addaf52736df21a7..3c1b783b916e3b555da601140a6d91b03de95198 100644 (file)
 
 #include "llvm/Support/Mangler.h"
 #include "llvm/ADT/Statistic.h"
+#include "llvm/Support/CommandLine.h"
 
 using namespace llvm;
 
+namespace llvm {
+  extern cl::opt<bool> EnableAlphaFTOI;
+}
+
 namespace {
   Statistic<> EmittedInsts("asm-printer", "Number of machine instrs printed");
 
@@ -229,7 +234,10 @@ void AlphaAsmPrinter::printConstantPool(MachineConstantPool *MCP) {
 bool AlphaAsmPrinter::doInitialization(Module &M)
 {
   AsmPrinter::doInitialization(M);
-  O << "\t.arch ev56\n";
+  if(EnableAlphaFTOI)
+    O << "\t.arch ev6\n";
+  else
+    O << "\t.arch ev56\n";
   return false;
 }
     
index e594c8664afc76b2cae7a8155dcff25b0938598b..18cc35a35691a21c3259fbc5d06bd140db42d93f 100644 (file)
@@ -1695,9 +1695,9 @@ unsigned ISel::SelectExpr(SDOperand N) {
       unsigned int build = 0;
       for(int i = 0; i < 8; ++i)
       {
-        if (k & 0xFF == 0xFF)
+        if ((k & 0x00FF) == 0x00FF)
           build |= 1 << i;
-        else if (k & 0xFF != 0)
+        else if ((k & 0x00FF) != 0)
         { build = 0; break; }
         k >>= 8;
       }