pushed :)

On Wed, May 14, 2025 at 9:18 PM Christoph Müllner <
christoph.muell...@vrull.eu> wrote:

> On Tue, May 13, 2025 at 4:34 AM Kito Cheng <kito.ch...@sifive.com> wrote:
> >
> > We forgot to initialize m_allow_adding_dup in the constructor of
> > riscv_subset_list, then that will be a random value...that will lead
> > to a random behavior of the -march may accpet duplicate extension.
> >
> > gcc/ChangeLog:
> >
> >         * common/config/riscv/riscv-common.cc
> >         (riscv_subset_list::riscv_subset_list): Init m_allow_adding_dup.
>
> Reviewed-by: Christoph Müllner <christoph.muell...@vrull.eu>
>
> Thanks!
>
> > ---
> >  gcc/common/config/riscv/riscv-common.cc | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/gcc/common/config/riscv/riscv-common.cc
> b/gcc/common/config/riscv/riscv-common.cc
> > index d3240f79240..2834697a857 100644
> > --- a/gcc/common/config/riscv/riscv-common.cc
> > +++ b/gcc/common/config/riscv/riscv-common.cc
> > @@ -620,7 +620,7 @@ riscv_subset_t::riscv_subset_t ()
> >
> >  riscv_subset_list::riscv_subset_list (const char *arch, location_t loc)
> >    : m_arch (arch), m_loc (loc), m_head (NULL), m_tail (NULL), m_xlen
> (0),
> > -    m_subset_num (0)
> > +    m_subset_num (0), m_allow_adding_dup (false)
> >  {
> >  }
> >
> > --
> > 2.34.1
> >
>

Reply via email to