Re: [RFA] gcc: fix PR rtl-optimization/107482

2022-11-08 Thread Max Filippov via Gcc-patches
On Mon, Nov 7, 2022 at 12:52 PM Vladimir Makarov wrote: > even better patch: > > diff --git a/gcc/ira-color.cc b/gcc/ira-color.cc > index 4a1a325e8e3..ffe73b61c45 100644 > --- a/gcc/ira-color.cc > +++ b/gcc/ira-color.cc > @@ -2209,8 +2209,8 @@ assign_hard_reg (ira_allocno_t a, bool retry_p) >

Re: [RFA] gcc: fix PR rtl-optimization/107482

2022-11-07 Thread Vladimir Makarov via Gcc-patches
On 2022-11-07 04:46, Max Filippov wrote: gcc/ * ira-color.cc (update_costs_from_allocno): Check that allocno is in the consideration_allocno_bitmap before dereferencing ALLOCNO_COLOR_DATA (allocno). --- This fixes the invalid memory access, but I'm not sure if that's suf

[RFA] gcc: fix PR rtl-optimization/107482

2022-11-07 Thread Max Filippov via Gcc-patches
gcc/ * ira-color.cc (update_costs_from_allocno): Check that allocno is in the consideration_allocno_bitmap before dereferencing ALLOCNO_COLOR_DATA (allocno). --- This fixes the invalid memory access, but I'm not sure if that's sufficient and there's no remaining higher level