Turn off "disable free" mode when preprocessing imported module files in

-frewrite-imports mode.

This could end up accumulating a very large amount of intermediate state. Clear
it out after each module file is processed.

llvm-svn: 305764
This commit is contained in:
Richard Smith 2017-06-20 01:31:53 +00:00
parent 4a99e37edc
commit 4f05b36285
1 changed files with 1 additions and 0 deletions

View File

@ -243,6 +243,7 @@ public:
Instance.createDiagnostics(
new ForwardingDiagnosticConsumer(CI.getDiagnosticClient()),
/*ShouldOwnClient=*/true);
Instance.getFrontendOpts().DisableFree = false;
Instance.getFrontendOpts().Inputs.clear();
Instance.getFrontendOpts().Inputs.emplace_back(
Filename, InputKind(InputKind::Unknown, InputKind::Precompiled));