Skip to content

Commit 9db72e5

Browse files
[clang][cmake] Fix support for dynamic libraries in CLANG_BOLT
Patch typo introduced in #127020
1 parent 8d1e260 commit 9db72e5

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

clang/utils/perf-training/perf-helper.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -560,12 +560,12 @@ def genOrderFile(args):
560560
return 0
561561

562562

563-
def filter_bolt_optimized(inputs, instrumented_outputs):
563+
def filter_bolt_optimized(inputs, instrumented_outputs, readelf):
564564
new_inputs = []
565565
new_instrumented_ouputs = []
566566
for input, instrumented_output in zip(inputs, instrumented_outputs):
567567
output = subprocess.check_output(
568-
[opts.readelf, "-WS", input], universal_newlines=True
568+
[readelf, "-WS", input], universal_newlines=True
569569
)
570570

571571
# This binary has already been bolt-optimized, so skip further processing.
@@ -597,7 +597,9 @@ def bolt_optimize(args):
597597
instrumented_outputs
598598
), "inconsistent --input / --instrumented-output arguments"
599599

600-
inputs, instrumented_outputs = filter_bolt_optimized(inputs, instrumented_outputs)
600+
inputs, instrumented_outputs = filter_bolt_optimized(inputs,
601+
instrumented_outputs,
602+
opts.readelf)
601603
if not inputs:
602604
return 0
603605

0 commit comments

Comments
 (0)