summaryrefslogtreecommitdiff
path: root/gcc/ira-costs.c
diff options
context:
space:
mode:
authorhp <hp@138bc75d-0d04-0410-961f-82ee72b054a4>2011-06-09 23:38:35 +0000
committerhp <hp@138bc75d-0d04-0410-961f-82ee72b054a4>2011-06-09 23:38:35 +0000
commitfa715e07d02a5de6b678715f9f465c805195a354 (patch)
treef60e8c57aa0950b9f89563791a88772e486bc936 /gcc/ira-costs.c
parent24cedde81874ec48a5940524c6eadeae3207edf2 (diff)
downloadgcc-fa715e07d02a5de6b678715f9f465c805195a354.tar.gz
PR rtl-optimization/49154
* ira-costs.c (setup_regno_cost_classes_by_mode): If there already is a matching slot in the hashtable, assign it to classes_ptr. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@174868 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ira-costs.c')
-rw-r--r--gcc/ira-costs.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/ira-costs.c b/gcc/ira-costs.c
index f517386ceef..a22bb1571cc 100644
--- a/gcc/ira-costs.c
+++ b/gcc/ira-costs.c
@@ -299,6 +299,8 @@ setup_regno_cost_classes_by_mode (int regno, enum machine_mode mode)
classes_ptr = setup_cost_classes (&classes);
*slot = classes_ptr;
}
+ else
+ classes_ptr = *slot;
cost_classes_mode_cache[mode] = (cost_classes_t) *slot;
}
regno_cost_classes[regno] = classes_ptr;