Closed Quuxplusone closed 14 years ago
Attached bugpoint.test.ll
(24770 bytes, text/plain): LLVM assembly code that is miscompiled.
Attached bugpoint.safe.ll
(463480 bytes, text/plain): LLVM Assembly compiled correctly
cool, I'll take a look. Thanks John!
-Chris
The program requires the following input on stdin:
solve rows 8 cols 8 V
Be sure to include a carriage return at the end of the line.
I still can't run it:
$ echo "solve rows 8 cols 8 V" | ./t
This causes the program to print out a bunch of stuff, but the program doesn't exit.
-Chris
I found and downloaded the program for myself, and it looks like there are
memory issues in the program:
==6953== Conditional jump or move depends on uninitialised value(s)
==6953== at 0x804FEC5: hashlookup (hash.c:103)
==6953== by 0x804C333: negamax (negamax.c:379)
==6953== by 0x804B148: search_for_move (negamax.c:201)
==6953== by 0x8048CA3: main (obsequi.c:102)
==6953== by 0x4026A54C: __libc_start_main (in /lib/libc-2.3.2.so)
==6953== by 0x8048B70: (within
/home/vadve/lattner/tmp/PR338/o/bullock.obsequi/obsequi/Obsequi)
I'll dig into it to see if I can fix this.
-Chris
Obsequi is works a bit better if you change the malloc in "initialize_solver" to
a calloc call. I'm still verifying that this fixes it entirely though.
When I run the native version of the program, it'll stop for about 7-10 seconds
and then finish execution. You might want to wait a bit and see if it finishes.
Yup, changing the malloc to a calloc magically fixes it, with the native
compiler, with LLVM, and with Valgrind.
Could you add this program into the test suite John? It looks like it should be
easy to do and could be an interesting one for the memory work I'm doing. :)
Thanks!
-Chris
bugpoint.test.ll
(24770 bytes, text/plain)bugpoint.safe.ll
(463480 bytes, text/plain)