Thanks for notifying me that, I just reverted that first and will
investigate next week :)

On Sat, Dec 7, 2024 at 3:30 AM Mark Wielaard <m...@klomp.org> wrote:
>
> Hi Kito,
>
> On Thu, Dec 05, 2024 at 03:12:03PM +0800, Kito Cheng wrote:
> > function_shape::get_name is the funciton for building intrinsic function 
> > name,
> > the result should not be changed by others once it built.
> >
> > So add const to the return type to make sure no one change that by
> > accident.
>
> This seems to have broken bootstrap on risc-v:
> https://builder.sourceware.org/buildbot/#/builders/310/builds/681
>
> In file included from ../../gcc/gcc/../libcpp/include/symtab.h:21,
>                  from ../../gcc/gcc/tree-core.h:23,
>                  from ../../gcc/gcc/tree.h:23,
>                  from ../../gcc/gcc/config/riscv/riscv-vector-builtins.cc:27:
> ../../gcc/gcc/config/riscv/riscv-vector-builtins.cc: In member function ‘void 
> riscv_vector::function_builder::add_unique_function(const 
> riscv_vector::function_instance&, const riscv_vector::function_shape*, tree, 
> vec<tree_node*>&, riscv_vector::required_ext)’:
> ../../gcc/gcc/../include/obstack.h:421:22: error: cast from type ‘const 
> char*’ to type ‘void*’ casts away qualifiers [-Werror=cast-qual]
>   421 |        void *__obj = (void *) (OBJ);                                  
>         \
>       |                      ^~~~~~~~~~~~~~
> ../../gcc/gcc/config/riscv/riscv-vector-builtins.cc:4011:3: note: in 
> expansion of macro ‘obstack_free’
>  4011 |   obstack_free (&m_string_obstack, name);
>       |   ^~~~~~~~~~~~
> ../../gcc/gcc/config/riscv/riscv-vector-builtins.cc: In member function ‘void 
> riscv_vector::function_builder::add_overloaded_function(const 
> riscv_vector::function_instance&, const riscv_vector::function_shape*, 
> riscv_vector::required_ext)’:
> ../../gcc/gcc/../include/obstack.h:421:22: error: cast from type ‘const 
> char*’ to type ‘void*’ casts away qualifiers [-Werror=cast-qual]
>   421 |        void *__obj = (void *) (OBJ);                                  
>         \
>       |                      ^~~~~~~~~~~~~~
> ../../gcc/gcc/config/riscv/riscv-vector-builtins.cc:4032:7: note: in 
> expansion of macro ‘obstack_free’
>  4032 |       obstack_free (&m_string_obstack, name);
>       |       ^~~~~~~~~~~~
> cc1plus: all warnings being treated as errors
> make[3]: *** [../../gcc/gcc/config/riscv/t-riscv:32: riscv-vector-builtins.o] 
> Error 1

Reply via email to