[Mono-bugs] [Bug 60909][Wis] New - [PATCH] Recomputate liveness ranges on second scan

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Tue, 29 Jun 2004 20:17:37 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by bmaurer@users.sf.net.

http://bugzilla.ximian.com/show_bug.cgi?id=60909

--- shadow/60909	2004-06-29 20:17:37.000000000 -0400
+++ shadow/60909.tmp.8051	2004-06-29 20:17:37.000000000 -0400
@@ -0,0 +1,37 @@
+Bug#: 60909
+Product: Mono: Runtime
+Version: unspecified
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Wishlist
+Component: misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: bmaurer@users.sf.net               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: [PATCH] Recomputate liveness ranges on second scan
+
+If liveness is recomputated we need to reset the information
+for each variable. This way, if the liveness range has been narrowed
+by optimizations that happened after the last computation, we can return
+a smaller range.
+
+For example, if you have
+
+{
+	int i = 0;
+	
+	// Tons of code that does not affect i
+	
+	i = foo ();
+	...
+}
+
+i = 0 is dead code and will be removed by SSA. However, when
+linear scan gets to the code, i will still appear to be live
+throughout the entire block. This prevents good register allocation.