Fix interpreter with profiling
ClosedPublic

Authored by simonmar on Feb 22 2018, 3:29 AM.

Details

Summary

This was broken by D3746 and/or D3809, but unfortunately we didn't
notice because CI at the time wasn't building the profiling way.

Test Plan
cd testsuite/test/profiling/should_run
make WAY=ghci-ext-prof

Diff Detail

Repository
rGHC Glasgow Haskell Compiler
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
simonmar created this revision.Feb 22 2018, 3:29 AM

Sorry for the breakage! :/

Does running tests with ghci-ext-prof WAY require profiled GHC? (I'm wondering if I could just add it to my usual validate runs)

compiler/ghci/ByteCodeGen.hs
970–980

So IIUC this is the buggy code - we would essentially:

  • add the header size in mkVirtHeapOffsets (even though there is no header!),
  • compensate that by adding wordSize dflags.

Which is broken in profiling because the header size is different?
Is that correct? (I'm just trying to understand this better)

(indeed D3746 seems to have introduced this)

It looks like there is a test that needs to be updated.

Sorry for the breakage! :/

No problem - it's a good reminder that our current CI regime has loopholes

Does running tests with ghci-ext-prof WAY require profiled GHC? (I'm wondering if I could just add it to my usual validate runs)

It requires BUILD_PROF_LIBS = YES, but not a profiled GHC.

compiler/ghci/ByteCodeGen.hs
970–980

That's my understanding, yes.

Sorry for the breakage! :/

Quite alright, I'm just happy it's fixed!

This revision was automatically updated to reflect the committed changes.