2009-09-23 Alexandre Oliva <aoliva@redhat.com>
+ PR debug/41353
+ * var-tracking.c (add_with_sets): Sort MO_VAL_LOC last among uses.
+
+2009-09-23 Alexandre Oliva <aoliva@redhat.com>
+
PR debug/41248
* cfgexpand.c (convert_debug_memory_address): New.
(expand_debug_expr): Convert base address and offset to the same
note_uses (&PATTERN (insn), add_uses_1, &cui);
n2 = VTI (bb)->n_mos - 1;
- /* Order the MO_USEs to be before MO_USE_NO_VARs,
- MO_VAL_LOC and MO_VAL_USE. */
+ /* Order the MO_USEs to be before MO_USE_NO_VARs and MO_VAL_USE, and
+ MO_VAL_LOC last. */
while (n1 < n2)
{
while (n1 < n2 && VTI (bb)->mos[n1].type == MO_USE)
}
}
+ n2 = VTI (bb)->n_mos - 1;
+
+ while (n1 < n2)
+ {
+ while (n1 < n2 && VTI (bb)->mos[n1].type != MO_VAL_LOC)
+ n1++;
+ while (n1 < n2 && VTI (bb)->mos[n2].type == MO_VAL_LOC)
+ n2--;
+ if (n1 < n2)
+ {
+ micro_operation sw;
+
+ sw = VTI (bb)->mos[n1];
+ VTI (bb)->mos[n1] = VTI (bb)->mos[n2];
+ VTI (bb)->mos[n2] = sw;
+ }
+ }
+
if (CALL_P (insn))
{
micro_operation *mo = VTI (bb)->mos + VTI (bb)->n_mos++;