Delete dead code: only functions are materializable.
[oota-llvm.git] / tools / llvm-extract / llvm-extract.cpp
index ca228da74d848914c0fedf9954a98f9e82b8d51c..de4288dd6ad32b3e14340e7c6d12e632e3e79fa2 100644 (file)
@@ -236,10 +236,6 @@ int main(int argc, char **argv) {
   } else {
     // Deleting. Materialize every GV that's *not* in GVs.
     SmallPtrSet<GlobalValue *, 8> GVSet(GVs.begin(), GVs.end());
-    for (auto &G : M->globals()) {
-      if (!GVSet.count(&G))
-        Materialize(G);
-    }
     for (auto &F : *M) {
       if (!GVSet.count(&F))
         Materialize(F);