r302940 - Remove ignore-empty-index-file option

Teresa Johnson via cfe-commits cfe-commits at lists.llvm.org
Fri May 12 12:32:17 PDT 2017


Author: tejohnson
Date: Fri May 12 14:32:17 2017
New Revision: 302940

URL: http://llvm.org/viewvc/llvm-project?rev=302940&view=rev
Log:
Remove ignore-empty-index-file option

Summary:
Clang changes to remove this option and replace with a parameter
always set in the context of a ThinLTO distributed backend.

Depends on D33133.

Reviewers: pcc

Subscribers: mehdi_amini, eraman, cfe-commits

Differential Revision: https://reviews.llvm.org/D33134

Modified:
    cfe/trunk/lib/CodeGen/BackendUtil.cpp
    cfe/trunk/test/CodeGen/thinlto_backend.ll

Modified: cfe/trunk/lib/CodeGen/BackendUtil.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/BackendUtil.cpp?rev=302940&r1=302939&r2=302940&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/BackendUtil.cpp (original)
+++ cfe/trunk/lib/CodeGen/BackendUtil.cpp Fri May 12 14:32:17 2017
@@ -1073,7 +1073,8 @@ void clang::EmitBackendOutput(Diagnostic
     // into memory and pass it into runThinLTOBackend, which will run the
     // function importer and invoke LTO passes.
     Expected<std::unique_ptr<ModuleSummaryIndex>> IndexOrErr =
-        llvm::getModuleSummaryIndexForFile(CGOpts.ThinLTOIndexFile);
+        llvm::getModuleSummaryIndexForFile(CGOpts.ThinLTOIndexFile,
+                                           /*IgnoreEmptyThinLTOIndexFile*/true);
     if (!IndexOrErr) {
       logAllUnhandledErrors(IndexOrErr.takeError(), errs(),
                             "Error loading index file '" +

Modified: cfe/trunk/test/CodeGen/thinlto_backend.ll
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGen/thinlto_backend.ll?rev=302940&r1=302939&r2=302940&view=diff
==============================================================================
--- cfe/trunk/test/CodeGen/thinlto_backend.ll (original)
+++ cfe/trunk/test/CodeGen/thinlto_backend.ll Fri May 12 14:32:17 2017
@@ -12,10 +12,10 @@
 ; RUN: %clang -O2 -o %t4.o -x ir %t1.o -c -fthinlto-index=bad.thinlto.bc 2>&1 | FileCheck %s -check-prefix=CHECK-ERROR1
 ; CHECK-ERROR1: Error loading index file 'bad.thinlto.bc'
 
-; Ensure we ignore empty index file under -ignore-empty-index-file, and run
-; non-ThinLTO compilation which would not import f2
+; Ensure we ignore empty index file, and run non-ThinLTO compilation which
+; would not import f2
 ; RUN: touch %t4.thinlto.bc
-; RUN: %clang -target x86_64-unknown-linux-gnu -O2 -o %t4.o -x ir %t1.o -c -fthinlto-index=%t4.thinlto.bc -mllvm -ignore-empty-index-file
+; RUN: %clang -target x86_64-unknown-linux-gnu -O2 -o %t4.o -x ir %t1.o -c -fthinlto-index=%t4.thinlto.bc
 ; RUN: llvm-nm %t4.o | FileCheck --check-prefix=CHECK-OBJ-IGNORE-EMPTY %s
 ; CHECK-OBJ-IGNORE-EMPTY: T f1
 ; CHECK-OBJ-IGNORE-EMPTY: U f2




More information about the cfe-commits mailing list