From 7ff5b8a65aa77946d439deff59ca532eab96f7ee Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Wed, 28 Dec 2022 12:16:22 +0000 Subject: rproxy: disable MWRAP+LD_PRELOAD for addr2line GNU addr2line seems impossibly slow with MWRAP=bt:10 on FreeBSD. In any case, it's impossible for a single-process rproxy to inspect it's own addr2line processes; so just disable it. --- lib/Devel/Mwrap/Rproxy.pm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/Devel/Mwrap/Rproxy.pm b/lib/Devel/Mwrap/Rproxy.pm index c831a36..e2b7097 100644 --- a/lib/Devel/Mwrap/Rproxy.pm +++ b/lib/Devel/Mwrap/Rproxy.pm @@ -139,6 +139,13 @@ sub call { # PSGI entry point undef %cache; $cache_exp = $now + $cache_time; } + + # GNU addr2line is slow with high bt:, and FreeBSD addr2line + # seems less capable. And we can't see addr2line in this + # anyways since we kill them at the end of this scope. + # So just disable MWRAP, here: + delete local $ENV{MWRAP}; + delete local $ENV{LD_PRELOAD}; eval { local %addr2line; # extract executable|library(address) -- cgit v1.2.3-24-ge0c7