begining alpha subtarget support


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23531 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/Alpha/AlphaISelPattern.cpp b/lib/Target/Alpha/AlphaISelPattern.cpp
index c30c459..557da82 100644
--- a/lib/Target/Alpha/AlphaISelPattern.cpp
+++ b/lib/Target/Alpha/AlphaISelPattern.cpp
@@ -13,6 +13,7 @@
 
 #include "Alpha.h"
 #include "AlphaRegisterInfo.h"
+#include "AlphaTargetMachine.h"
 #include "AlphaISelLowering.h"
 #include "llvm/Constants.h"                   // FIXME: REMOVE
 #include "llvm/Function.h"
@@ -38,12 +39,6 @@
   cl::opt<bool> EnableAlphaIDIV("enable-alpha-intfpdiv",
     cl::desc("Use the FP div instruction for integer div when possible"),
                              cl::Hidden);
-  cl::opt<bool> EnableAlphaFTOI("enable-alpha-FTOI",
-    cl::desc("Enable use of ftoi* and itof* instructions (ev6 and higher)"),
-                             cl::Hidden);
-  cl::opt<bool> EnableAlphaCT("enable-alpha-CT",
-    cl::desc("Enable use of the ctpop, ctlz, and cttz instructions"),
-                              cl::Hidden);
   cl::opt<bool> EnableAlphaCount("enable-alpha-count",
     cl::desc("Print estimates on live ins and outs"),
     cl::Hidden);
@@ -428,7 +423,7 @@
 void AlphaISel::MoveFP2Int(unsigned src, unsigned dst, bool isDouble)
 {
   unsigned Opc;
-  if (EnableAlphaFTOI) {
+  if (TLI.getTargetMachine().getSubtarget<AlphaSubtarget>().hasF2I()) {
     Opc = isDouble ? Alpha::FTOIT : Alpha::FTOIS;
     BuildMI(BB, Opc, 1, dst).addReg(src).addReg(Alpha::F31);
   } else {
@@ -455,7 +450,7 @@
 void AlphaISel::MoveInt2FP(unsigned src, unsigned dst, bool isDouble)
 {
   unsigned Opc;
-  if (EnableAlphaFTOI) {
+  if (TLI.getTargetMachine().getSubtarget<AlphaSubtarget>().hasF2I()) {
     Opc = isDouble?Alpha::ITOFT:Alpha::ITOFS;
     BuildMI(BB, Opc, 1, dst).addReg(src).addReg(Alpha::R31);
   } else {