about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <mwrap-perl@80x24.org>2022-12-28 12:16:22 +0000
committerEric Wong <mwrap-perl@80x24.org>2022-12-29 21:46:04 +0000
commit7ff5b8a65aa77946d439deff59ca532eab96f7ee (patch)
tree456cbe388c8d5b9f1d2e0cc51365eea906957691
parent3df9312c050249cb5eef2aed8afc3abadbba981d (diff)
downloadmwrap-7ff5b8a65aa77946d439deff59ca532eab96f7ee.tar.gz
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.
-rw-r--r--lib/Devel/Mwrap/Rproxy.pm7
1 files changed, 7 insertions, 0 deletions
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)