[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Paul D. Smith
Additional Item Attachment, bug #15757 (project make): File name: mvnew.cSize:0 KB New version.c:merge_variable_set_lists() function ___ Re

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Paul D. Smith
Follow-up Comment #19, bug #15757 (project make): OK. Please try replacing version.c:merge_variable_set_lists() with the one I've attached to this bug report. See if that solves your problem. It fixes my test case but the regression tests all still pass. __

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Paul D. Smith
Follow-up Comment #18, bug #15757 (project make): Hi. I can now reproduce this problem, even on Linux, using the following setup: mkdir t1 t2 touch t1/rules.mk cd t2 cat > Makefile ___ M

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Paul D. Smith
Follow-up Comment #17, bug #15757 (project make): Oh yeah... using the info you gave and just walking through the logic of merge_variable_set_lists(), you can easily see where the problem happens: global_setlist->next pointer is getting set to point into the "to" setlist. Ouch. The logic in thi

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Paul D. Smith
Update of bug #15757 (project make): Severity: 3 - Normal => 5 - Blocker Assigned to:None => psmith ___ Reply to this item at:

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Paul D. Smith
Follow-up Comment #16, bug #15757 (project make): FYI, the rehash_file() is normally called when a target is found via VPATH. If the target is found via VPATH, _and_ it is not going to be recreated, then the target name is changed to be the VPATH pathname and the file is re-hashed. When that ha

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Paul D. Smith
Follow-up Comment #15, bug #15757 (project make): Good stuff. Having both of those lists eventually point to global_setlist is, I'm pretty sure, quite correct... all local setlists should eventually point to the global list (this allows global variables to be accessed after all!) I'll have to l

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Ab Wilson
Follow-up Comment #14, bug #15757 (project make): So this is what's goig on: merge_variable_set_lists is being called with two non-disjoint lists with the second list longer than the first. The last part of the function where the tail of list1 is appended to list0 results in a circular list. In

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Ab Wilson
Follow-up Comment #13, bug #15757 (project make): I can confirm that the fix for inode comparisons does not fix this bug. ___ Reply to this item at:

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Ab Wilson
Follow-up Comment #12, bug #15757 (project make): We are getting nearer. The problem is actually occuring in merge_variable_set_list. Here is the stack: (dbx) where [1] merge_variable_set_lists(setlist0 = 0xf1868, setlist1 = 0x715fd8), line 735 in "variable.c" =>[2] rehash_file(from_file = 0xb

[bug #15757] circular variable_set_list causes hang on SunOS

2006-02-16 Thread Ab Wilson
Follow-up Comment #11, bug #15757 (project make): I currently running in dbx with the command: stop cond find_cycle(&global_setlist) using int find_cycle(const struct variable_set_list* list) { if(!list) { return 0; } const struct variable_set_list* one_step = list; const struct