Skip to content

Commit 2b0c0d3

Browse files
committed
[KernelInfo] Adjust for PR llvm#96691 upstreaming changes
The original version was introduced here in 2476cd3.
1 parent c0a3295 commit 2b0c0d3

File tree

2 files changed

+4
-9
lines changed

2 files changed

+4
-9
lines changed

llvm/lib/LTO/LTOBackend.cpp

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -191,13 +191,8 @@ static void RegisterPassPlugins(ArrayRef<std::string> PassPlugins,
191191
// Load requested pass plugins and let them register pass builder callbacks
192192
for (auto &PluginFN : PassPlugins) {
193193
auto PassPlugin = PassPlugin::Load(PluginFN);
194-
if (!PassPlugin) {
195-
errs() << "Failed to load passes from plugin '" << PluginFN
196-
<< "' (request ignored): " << toString(PassPlugin.takeError())
197-
<< "\n";
198-
continue;
199-
}
200-
194+
if (!PassPlugin)
195+
report_fatal_error(PassPlugin.takeError(), /*gen_crash_diag=*/false);
201196
PassPlugin->registerPassBuilderCallbacks(PB);
202197
}
203198
}

llvm/test/Feature/load_plugin_error.ll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
; REQUIRES: plugins
1+
; REQUIRES: plugins, x86-registered-target
22
; UNSUPPORTED: target={{.*windows.*}}
33

44
; RUN: not opt < %s -load-pass-plugin=%t/nonexistent.so -disable-output 2>&1 | FileCheck %s
55

66
; RUN: opt %s -o %t.o
7-
; RUN: llvm-lto2 run -load-pass-plugin=%t/nonexistent.so %t.o -o %t \
7+
; RUN: not llvm-lto2 run -load-pass-plugin=%t/nonexistent.so %t.o -o %t \
88
; RUN: -r %t.o,test 2>&1 | \
99
; RUN: FileCheck %s
1010

0 commit comments

Comments
 (0)