diff options
author | Michael Zolotukhin <mzolotukhin@apple.com> | 2016-01-14 09:02:45 +0000 |
---|---|---|
committer | Michael Zolotukhin <mzolotukhin@apple.com> | 2016-01-14 09:02:45 +0000 |
commit | af6e8973aa7ac1ae3bdc7ce5a304a78a5cf31dc5 (patch) | |
tree | 760824363f88676287f1261771e1559e506e428f /tools/llvm-extract | |
parent | 741199b1136171aa1116cd55fc5f0a2930060e0d (diff) |
Revert "Assert that we have all use/users in the getters."
This reverts commit fdb838f3f8a8b6896bbbd5285555874eb3b748eb.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@257751 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/llvm-extract')
-rw-r--r-- | tools/llvm-extract/llvm-extract.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/tools/llvm-extract/llvm-extract.cpp b/tools/llvm-extract/llvm-extract.cpp index 1da456d33f5..de4288dd6ad 100644 --- a/tools/llvm-extract/llvm-extract.cpp +++ b/tools/llvm-extract/llvm-extract.cpp @@ -242,22 +242,13 @@ int main(int argc, char **argv) { } } - { - std::vector<GlobalValue *> Gvs(GVs.begin(), GVs.end()); - legacy::PassManager Extract; - Extract.add(createGVExtractionPass(Gvs, DeleteFn)); - Extract.run(*M); - - // Now that we have all the GVs we want, mark the module as fully - // materialized. - // FIXME: should the GVExtractionPass handle this? - M->materializeAll(); - } - // In addition to deleting all other functions, we also want to spiff it // up a little bit. Do this now. legacy::PassManager Passes; + std::vector<GlobalValue*> Gvs(GVs.begin(), GVs.end()); + + Passes.add(createGVExtractionPass(Gvs, DeleteFn)); if (!DeleteFn) Passes.add(createGlobalDCEPass()); // Delete unreachable globals Passes.add(createStripDeadDebugInfoPass()); // Remove dead debug info |