[PATCH] D33133: Remove ignore-empty-index-file option
Teresa Johnson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 12 12:45:30 PDT 2017
This revision was automatically updated to reflect the committed changes.
Closed by commit rL302939: Remove ignore-empty-index-file option (authored by tejohnson).
Changed prior to commit:
https://reviews.llvm.org/D33133?vs=98778&id=98820#toc
Repository:
rL LLVM
https://reviews.llvm.org/D33133
Files:
llvm/trunk/include/llvm/Bitcode/BitcodeReader.h
llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp
Index: llvm/trunk/include/llvm/Bitcode/BitcodeReader.h
===================================================================
--- llvm/trunk/include/llvm/Bitcode/BitcodeReader.h
+++ llvm/trunk/include/llvm/Bitcode/BitcodeReader.h
@@ -152,10 +152,11 @@
/// Parse the module summary index out of an IR file and return the module
/// summary index object if found, or an empty summary if not. If Path refers
- /// to an empty file and the -ignore-empty-index-file cl::opt flag is passed
+ /// to an empty file and IgnoreEmptyThinLTOIndexFile is true, then
/// this function will return nullptr.
Expected<std::unique_ptr<ModuleSummaryIndex>>
- getModuleSummaryIndexForFile(StringRef Path);
+ getModuleSummaryIndexForFile(StringRef Path,
+ bool IgnoreEmptyThinLTOIndexFile = false);
/// isBitcodeWrapper - Return true if the given bytes are the magic bytes
/// for an LLVM IR bitcode wrapper.
Index: llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp
===================================================================
--- llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp
+++ llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp
@@ -93,13 +93,6 @@
cl::desc(
"Print the global id for each value when reading the module summary"));
-// FIXME: This flag should either be removed or moved to clang as a driver flag.
-static llvm::cl::opt<bool> IgnoreEmptyThinLTOIndexFile(
- "ignore-empty-index-file", llvm::cl::ZeroOrMore,
- llvm::cl::desc(
- "Ignore an empty index file and perform non-ThinLTO compilation"),
- llvm::cl::init(false));
-
namespace {
enum {
@@ -5663,7 +5656,8 @@
}
Expected<std::unique_ptr<ModuleSummaryIndex>>
-llvm::getModuleSummaryIndexForFile(StringRef Path) {
+llvm::getModuleSummaryIndexForFile(StringRef Path,
+ bool IgnoreEmptyThinLTOIndexFile) {
ErrorOr<std::unique_ptr<MemoryBuffer>> FileOrErr =
MemoryBuffer::getFileOrSTDIN(Path);
if (!FileOrErr)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D33133.98820.patch
Type: text/x-patch
Size: 1997 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170512/2a2eb611/attachment.bin>
More information about the llvm-commits
mailing list