Aren't there multiple calls to lower_complex_expr? In this case maybe only deleting at the caller is right, but if other uses do not do the delete, and you don't delete in the callee, then you will never delete.
________________________________ From: 朱庆 [mailto:zqing1...@gmail.com] Sent: Wednesday, August 18, 2010 9:23 PM To: open64-devel@lists.sourceforge.net Subject: [Open64-devel] Assertion failure in wn_lower phase Hi, All Can gatekeeper help review this fix? This bug is happens in wn_lower phase, more detailed info please refer to https://bugs.open64.net/show_bug.cgi?id=591. Attached is the patch. The failure is due to one whirl node address attached by two nodes. The main cause is that in wn_lower.cxx:7741:lower_complex_expr(block, WN_kid0(tree), actions, &realexp, &imagexp), WN_kid0(tree) was deleted in the function, , howerver in 7783, the node deleted again , so if there are other new node created between line 7741and 7783, it may reuse the deleted node address, and will be wrongly deleted by line 7783. The fix is modified function lower_complex_expr, delete all "WN_Delete(tree);". 7741 lower_complex_expr(block, WN_kid0(tree), actions, &realexp, &imagexp); 7742 ...... 7762 realexpN = AssignExpr(block, realexp, realTY); 7763 realexp_copy = WN_LdidPreg(realTY, realexpN); 7764 ....... 7783 WN_Delete(WN_kid0(tree)); 7784 WN_kid0(tree) = WN_Ldid(MTYPE_F8, 0, c4temp_st, MTYPE_To_TY(MTYPE_F8)); Best Regards, Zhu Qing ----------------------------------------------------------------------------------- This email message is for the sole use of the intended recipient(s) and may contain confidential information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message. -----------------------------------------------------------------------------------
------------------------------------------------------------------------------ This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev
_______________________________________________ Open64-devel mailing list Open64-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/open64-devel