Myles Watson mylesgw@gmail.com writes:
On Wed, Jun 16, 2010 at 4:34 PM, Myles Watson mylesgw@gmail.com wrote:
On Wed, Jun 16, 2010 at 12:06 PM, Myles Watson mylesgw@gmail.com wrote:
On Wed, Jun 16, 2010 at 12:00 PM, Myles Watson mylesgw@gmail.com wrote:
When compiling asus/p2b (and several others), Rev 5622 succeeds, but 5623 fails.
make: *** [build/mainboard/asus/p2b/romstage.inc] Segmentation fault make: *** Deleting file `build/mainboard/asus/p2b/romstage.inc'
The only difference for these boards is this line in config.h:
#define CONFIG_VENDOR_ECS 0
Removing this line lets 5623 build correctly.
Removing any line from the file that doesn't affect the build works. (CONFIG_VENDOR_*, CONFIG_DEFAULT_CONSOLE_LEVEL_*, etc.)
Program received signal SIGSEGV, Segmentation fault. 0x0000000000423bbe in free_basic_block (state=0x7fff5dbcbb20, block=0x1392ff0) at /home/myles/try/buildrom-devel/work/coreboot/svn/util/romcc/romcc.c:15165 15165 if (child && (child->vertex != -1)) { (gdb) print child $1 = (struct block *) 0x1c95950 (gdb) print child->vertex Cannot access memory at address 0x1c959b8
It looks like Patrick found this before: http://www.coreboot.org/pipermail/coreboot/2009-November/054387.html
If I take out the free it works fine. It seems like there must be a better fix.
Agreed.
I took a look at this a little bit with Stefan and he helped me track where the double free is.
The routine doing the freeing badly needs to be rewritten to use simpler logic as the recursive logic it is using now just doesn't work, and it winds up to be a bit of a crap shoot if your compile gets killed by this or not.
Eric