mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 04:30:23 +00:00
Move assertion with TargetPassConfig's Initialized flag.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159569 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
3fb99a7368
commit
6b2bb15bf7
@ -273,14 +273,14 @@ AnalysisID TargetPassConfig::getPassSubstitution(AnalysisID ID) const {
|
||||
|
||||
/// Add a pass to the PassManager.
|
||||
void TargetPassConfig::addPass(Pass *P) {
|
||||
assert(!Initialized && "PassConfig is immutable");
|
||||
|
||||
PM->add(P);
|
||||
}
|
||||
|
||||
/// Add a CodeGen pass at this point in the pipeline after checking for target
|
||||
/// and command line overrides.
|
||||
AnalysisID TargetPassConfig::addPass(AnalysisID PassID) {
|
||||
assert(!Initialized && "PassConfig is immutable");
|
||||
|
||||
AnalysisID TargetID = getPassSubstitution(PassID);
|
||||
AnalysisID FinalID = overridePass(PassID, TargetID);
|
||||
if (FinalID == 0)
|
||||
|
Loading…
Reference in New Issue
Block a user