Lint performance

Ben Gamari ben at smart-cactus.org
Fri Nov 8 23:26:41 UTC 2024


Simon Peyton Jones <simon.peytonjones at gmail.com> writes:

> Friends
>
> -dcore-lint is switched off in our compile-time tests
> testsuite/tests/perf/compiler
>
> But I'm making some changes whose primary effect will be on Lint.   How can
> I get a before-vs-after analysis of the tess in perf/compiler, with
> -dcore-lint switched on?
>
I'm afraid we don't have a good way of doing that without modifying the
.T file, which explicitly disables linting. The following patch will
drop the appropriate line:

    diff --git a/testsuite/tests/perf/compiler/all.T b/testsuite/tests/perf/compiler/all.T
    index 82390ff27e0..61092d2e1e1 100644
    --- a/testsuite/tests/perf/compiler/all.T
    +++ b/testsuite/tests/perf/compiler/all.T
    @@ -1,7 +1,3 @@
    -# Tests that call 'collect_compiler_stats' are skipped when debugging is on.
    -# See testsuite/driver/testlib.py.
    -setTestOpts(no_lint)
    -
    test('T1969',
          [# expect_broken(12437),
          collect_compiler_residency(20),

With this patch, linting will be enabled for the perf/compiler tests
(since the default testsuite compiler arguments include -dcore-lint; see
Settings.Builders.RunTest.runTestGhcFlags).

Concretely, I would:

 1. run the testsuite as described on [1]
 2. apply the above patch and commit
 3. run the testsuite again as described on [1]
 4. compare the results using the `perf_notes.py` tool as described on [1]

Naturally, I'd be happy to answer any questions that arise.

Cheers,

- Ben


[1] https://gitlab.haskell.org/ghc/ghc/-/wikis/building/running-tests/performance-tests
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 487 bytes
Desc: not available
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20241108/110bb606/attachment.sig>


More information about the ghc-devs mailing list