Skip to content

Commit f360763

Browse files
committed
suppress addr2line errors
1 parent 58788cb commit f360763

File tree

2 files changed

+6
-13
lines changed

2 files changed

+6
-13
lines changed

gprofiler/utils/perf_process.py

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
from psutil import Process
1010

11-
from gprofiler.exceptions import CalledProcessError
1211
from gprofiler.log import get_logger_adapter
1312
from gprofiler.utils import (
1413
reap_process,
@@ -190,17 +189,11 @@ def wait_and_script(self) -> str:
190189
perf_data.unlink()
191190
perf_data = inject_data
192191

193-
try:
194-
perf_script_proc = run_process(
195-
[perf_path(), "script", "-F", "+pid,+symline", "-i", str(perf_data)],
196-
suppress_log=True,
197-
)
198-
return perf_script_proc.stdout.decode("utf8")
199-
except CalledProcessError as e:
200-
# ignore addr2line errors
201-
if isinstance(e.stderr, str) and e.stderr.startswith("addr2line"):
202-
return e.stdout.decode("utf8") if isinstance(e.stdout, bytes) else str(e.stdout)
203-
raise
192+
perf_script_proc = run_process(
193+
[perf_path(), "script", "-F", "+pid,+symline", "--no-addr2line-errors", "-i", str(perf_data)],
194+
suppress_log=True,
195+
)
196+
return perf_script_proc.stdout.decode("utf8")
204197
finally:
205198
perf_data.unlink()
206199
if self._inject_jit:

scripts/perf_build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
set -euo pipefail
1818

1919
# downloading the zip because the git is very large (this is also very large, but still smaller)
20-
curl -SL https://codeload.github.com/Granulate/linux/zip/9909d736d8b8927d79003dfa9732050a08c11221 -o linux.zip
20+
curl -SL https://codeload.github.com/Granulate/linux/zip/9f87645132541bf90b080e51092af50bdf2763f0 -o linux.zip
2121
unzip -qq linux.zip
2222
rm linux.zip
2323
cd linux-*/

0 commit comments

Comments
 (0)