New codegen failing test-cases

Edward Z. Yang ezyang at MIT.EDU
Fri Dec 10 16:59:26 CET 2010

Ok, I've got a patch that fixes this segfault.  In the process I looked
at all patches to Cg* modules after Nov 2009 and looked for changes that
weren't applied to the new codegen.  I skipped the LLVM patch, but picked
up the rest of the blackhole changes.  There are, however, two hunks that
I am not 100% sure how to translate.

    hunk ./compiler/codeGen/CgClosure.lhs 477
    -         stmtC (CmmStore (CmmReg nodeReg) bh_info)
    +         stmtsC [
    +              CmmStore (cmmOffsetW (CmmReg nodeReg) fixedHdrSize)
    +                       (CmmReg (CmmGlobal CurrentTSO)),
    +              CmmCall (CmmPrim MO_WriteBarrier) [] [] CmmUnsafe CmmMayReturn,
    +             CmmStore (CmmReg nodeReg) bh_info
    +            ]

(the new code uses emits and a different format)

    hunk ./compiler/codeGen/CgStackery.lhs 20
    -       pushUpdateFrame, emitPushUpdateFrame,
    +       pushUpdateFrame, pushBHUpdateFrame, emitPushUpdateFrame,

A new pushBHUpdateFrame function was added, but I'm not sure how to translate
this because the new codegenerator only reads out the offset from
the FCode monad and there's no label to speak of.


More information about the Glasgow-haskell-users mailing list