aboutsummaryrefslogtreecommitdiff
path: root/gcc/var-tracking.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/var-tracking.c')
-rw-r--r--gcc/var-tracking.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/var-tracking.c b/gcc/var-tracking.c
index 9676612..76cd7f8 100644
--- a/gcc/var-tracking.c
+++ b/gcc/var-tracking.c
@@ -3694,6 +3694,11 @@ dataflow_set_equiv_regs (dataflow_set *set)
{
rtx canon[NUM_MACHINE_MODES];
+ /* If the list is empty or one entry, no need to canonicalize
+ anything.  */
+  if (set->regs[i] == NULL || set->regs[i]->next == NULL)
+ continue;
+
memset (canon, 0, sizeof (canon));
for (list = set->regs[i]; list; list = list->next)