[Mono-bugs] [Bug 505375] JIT does not optimize do-while loop correctly

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed May 20 14:41:42 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=505375

User rkumpera at novell.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=505375#c2





--- Comment #2 from Rodrigo Kumpera <rkumpera at novell.com>  2009-05-20 12:41:38 MDT ---
The bug is pretty simple. The cprop pass is posed with the following IR:

int_add_imm R12 <- R12 [1] clobbers: 1
int_sub_imm R42 <- R12 [1] clobbers: 1

It will wrongly const propagate the add into the sub generating the following:

int_add_imm R12 <- R12 [1] clobbers: 1
int_sub_imm R42 <- R12 [0] clobbers: 1

This optimization is incorrect because add changes the value of R12 so the
result is not equivalent.

The fix is done, just waiting regression tests to finish.

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list