On 01/12/2018 01:58 PM, li...@coryfields.com wrote: > From: Cory Fields <cory-nosp...@coryfields.com> > > 2018-01-12 Cory Fields <cory-nosp...@coryfields.com> > * tree-ira.c (allocno_hard_regs_compare): stabilize sort > --- > gcc/ChangeLog | 3 +++ > gcc/ira-color.c | 3 +-- > 2 files changed, 4 insertions(+), 2 deletions(-) > > diff --git a/gcc/ChangeLog b/gcc/ChangeLog > index ab96bd6..546e84c 100644 > --- a/gcc/ChangeLog > +++ b/gcc/ChangeLog > @@ -1,4 +1,7 @@ > 2018-01-12 Cory Fields <cory-nosp...@coryfields.com> > + * tree-ira.c (allocno_hard_regs_compare): stabilize sort Note I'm not sure this is sufficient to stabilize the sort. Given two allocnos with the same cost and the same potential hard reg set ought to hash to the same value.
Similarly if two sets with the same cost had a hash collision. But it's still more stable than doing nothing. jeff