about summary refs log tree commit homepage
path: root/t
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2021-10-04 06:10:21 +0000
committerEric Wong <e@80x24.org>2021-10-04 09:42:15 +0000
commit6248a7ab1046d0ccdc0b244099fb241fd52d653e (patch)
treefb076f47e378fc75ff212d01d40ca20264e2411a /t
parentb28e74c9dc0acad164187f6f584f815df1bc6ec7 (diff)
downloadpublic-inbox-6248a7ab1046d0ccdc0b244099fb241fd52d653e.tar.gz
Making them immortal doesn't seem worth it, since doing immortal
allocations after process startup leads to fragmentation.  While
the allocations made by highlight are small, those small
allocations can break up contiguous regions and prevent
consolidation by the malloc implementation.

Since instantiating code generators doesn't seem too expensive,
just use and delete them ASAP.
Diffstat (limited to 't')
-rw-r--r--t/hl_mod.t3
1 files changed, 1 insertions, 2 deletions
diff --git a/t/hl_mod.t b/t/hl_mod.t
index 96878d51..a88f6c03 100644
--- a/t/hl_mod.t
+++ b/t/hl_mod.t
@@ -3,8 +3,7 @@
 # License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
 use strict; use v5.10.1; use PublicInbox::TestCommon; use IO::Handle; # ->autoflush
 use Fcntl qw(:seek);
-eval { require highlight } or
-        plan skip_all => "failed to load highlight.pm for $0";
+require_mods 'highlight';
 use_ok 'PublicInbox::HlMod';
 my $hls = PublicInbox::HlMod->new;
 ok($hls, 'initialized OK');