From 194eebc9e35c8ef039ae6018ab4de9f4ae7365f6 Mon Sep 17 00:00:00 2001 From: sof Date: Wed, 3 Sep 1997 23:48:25 +0000 Subject: [PATCH] [project @ 1997-09-03 23:48:25 by sof] Fixed ghc-timing regex; allow .foo_o and .bar_a as link files --- ghc/driver/ghc.lprl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ghc/driver/ghc.lprl b/ghc/driver/ghc.lprl index e8c7154..7275466 100644 --- a/ghc/driver/ghc.lprl +++ b/ghc/driver/ghc.lprl @@ -2263,7 +2263,9 @@ sub process_ghc_timings { $GCs = $1 if /^\s*([0-9,]+) garbage collections? performed/; - if ( /^\s*INIT\s+time\s*(\d+\.\d\d)s\s*\(\s*(\d+\.\d\d)s elapsed\)/ ) { + # The presence of -? in the following pattern is only there to + # accommodate 0.29 && <= 2.05 RTS' + if ( /^\s*INIT\s+time\s*(\d+\.\d\d)s\s*\(\s*-?(\d+\.\d\d)s elapsed\)/ ) { $InitTime = $1; $InitElapsed = $2; } elsif ( /^\s*MUT\s+time\s*(\d+\.\d\d)s\s*\(\s*(\d+\.\d\d)s elapsed\)/ ) { $MutTime = $1; $MutElapsed = $2; @@ -2477,7 +2479,7 @@ arg: while($_ = $args[0]) { do { push(@Cmd_opts, $_); push(@Cmd_opts,$args[0]); shift(@args); next arg; }; /^--?./ && do { push(@Cmd_opts, $_); next arg; }; - if (/\.[oa]$/) { + if (/\.([^_]+_)?[oa]$/) { push(@Link_file, $_); } else { push(@Input_file, $_); -- 1.7.10.4