diff options
author | Chris Lattner <sabre@nondot.org> | 2008-07-10 23:37:50 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2008-07-10 23:37:50 +0000 |
commit | 70587ea813986bb0dbef71610091d496e28c22a6 (patch) | |
tree | b899bbfbc87140bb5e85606f82ad34a12cfee5fa /lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | |
parent | 0ebf14c4bb96397b7dd9ba61c38371f868e7b264 (diff) |
make legalize types be a command line option: -enable-legalize-types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53434 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index bc1eda3408..b4b81cd4f1 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -50,7 +50,9 @@ using namespace llvm; static cl::opt<bool> -EnableValueProp("enable-value-prop", cl::Hidden, cl::init(false)); +EnableValueProp("enable-value-prop", cl::Hidden); +static cl::opt<bool> +EnableLegalizeTypes("enable-legalize-types", cl::Hidden); #ifndef NDEBUG @@ -5296,10 +5298,11 @@ void SelectionDAGISel::CodeGenAndEmitDAG(SelectionDAG &DAG) { // Second step, hack on the DAG until it only uses operations and types that // the target supports. -#if 0 // Enable this some day. - DAG.LegalizeTypes(); - // Someday even later, enable a dag combine pass here. -#endif + if (EnableLegalizeTypes) {// Enable this some day. + DAG.LegalizeTypes(); + // TODO: enable a dag combine pass here. + } + if (TimePassesIsEnabled) { NamedRegionTimer T("DAG Legalization"); DAG.Legalize(); |