[erlang-questions] Status of HARDDEBUG code (doesn't compile, seems to be outdated)
Winston Smith
smith.winston.101@REDACTED
Thu Apr 5 19:56:07 CEST 2012
The process of attempting to track down the cause of a TYPE ASSERTION
FAILED error stopping Mnesia in R15B* has lead me down the path of
creating a debug build of beam and now on to building a version of
beam with HARDDEBUG defined which should enable a fair bit of internal
sanity checking and debug output.
However, turning on -DHARDDEBUG results in quite a few compile errors,
it's pretty obvious that the HARDDEBUG code is quite out of date. I
have spent some time yesterday fixing these errors (I will submit
patches separately to erlang-patches) but now I find that it's
aborting during startup with:
# ./erts-5.9.1/bin/erl -minimal
size_object: matchstate term not allowedAborted (core dumped)
This is the line in beam/copy.c that it's failing at:
case BIN_MATCHSTATE_SUBTAG:
erl_exit(ERTS_ABORT_EXIT,
"size_object: matchstate term not allowed");
Again, I'm working on a cross compile to the AVR32 platform, so it's a
bit tedious to debug this as I have some issues with gdb not being
able to produce a stack dump, so I have to do it myself. From the
core dump generated by the abort(), I was able to recover the
following stack trace:
0 - ?? (should be erl_exit_vv(), but $pc seems corrupted, could be
an artefact of the SIGABORT)
1 - erl_exit() -- erl_init.c:1627
2 - size_object() -- copy.c:174
3 - process_main() -- beam_emu.c:4109
4 - erl_start() -- erl_init.c:1493
5 - main() -- erl_main.c:30
So onto my question: is HARDDEBUG still supported? Is it
abandonware, or has it just gotten a little out of date?
Am I wasting my time here, or should I dig into it?
Thanks!
W.
More information about the erlang-questions
mailing list