On Wed, Jan 17, 2024 at 09:04:08AM +0000, Iain Sandoe wrote:
> > On 17 Jan 2024, at 08:55, Iain Sandoe <iains....@gmail.com> wrote:
> > 
> > Tested on x86_64, aarch64 Darwin21 (which default to heap-based trampolines)
> > and on x86_64 Darwin19 and Linux (which default to executable stack
> > trampolines).
> > OK for trunk?
> 
> Hmm.. maybe this is not right and the builtins should still be named 
> __builtin (with
> the fallback function only renamed) or alternatively, add these as libfuncs 
> only?
> 
> > Iain
> > 
> > --- 8< ---
> > 
> > The symbols for the functions supporting heap-based trampolines were
> > exported at an incorrect symbol version, the following patch fixes that.
> > 
> > As requested in the PR, this also renames __builtin_nested_func_ptr* to
> > __gcc_nested_func_ptr*.
> > 
> >     PR libgcc/113402
> > 
> > gcc/ChangeLog:
> > 
> >     * builtins.def
> >     (BUILT_IN_NESTED_PTR_CREATED): Rename __builtin_nested_func_ptr_created
> >     to __gcc_nested_func_ptr_created.
> >     (BUILT_IN_NESTED_PTR_DELETED): Rename __builtin_nested_func_ptr_deleted
> >     to __gcc_nested_func_ptr_deleted.

The normal way would be call the builtins in the compiler
__builtin___gcc_nested_func_ptr_*
and expand them to the __gcc_nested_func_ptr_* calls.
See e.g. __builtin___clear_cache.

        Jakub

Reply via email to