mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-04-18 03:37:31 +00:00
add a -view-legalize-types-dags option, for viewing the dags going into legalize types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46672 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
4eecdeb3fa
commit
a658baba78
@ -16,9 +16,20 @@
|
||||
#include "LegalizeTypes.h"
|
||||
#include "llvm/Constants.h"
|
||||
#include "llvm/DerivedTypes.h"
|
||||
#include "llvm/Support/CommandLine.h"
|
||||
#include "llvm/Support/MathExtras.h"
|
||||
using namespace llvm;
|
||||
|
||||
#ifndef NDEBUG
|
||||
static cl::opt<bool>
|
||||
ViewLegalizeTypesDAGs("view-legalize-types-dags", cl::Hidden,
|
||||
cl::desc("Pop up a window to show dags before legalize types"));
|
||||
#else
|
||||
static const bool ViewLegalizeTypesDAGs = 0;
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
/// run - This is the main entry point for the type legalizer. This does a
|
||||
/// top-down traversal of the dag, legalizing types as it goes.
|
||||
void DAGTypeLegalizer::run() {
|
||||
@ -438,5 +449,7 @@ void DAGTypeLegalizer::SplitOp(SDOperand Op, SDOperand &Lo, SDOperand &Hi) {
|
||||
/// Note that this is an involved process that may invalidate pointers into
|
||||
/// the graph.
|
||||
void SelectionDAG::LegalizeTypes() {
|
||||
if (ViewLegalizeTypesDAGs) viewGraph();
|
||||
|
||||
DAGTypeLegalizer(*this).run();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user