This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v2] Implement no_sanitize function attribute


On Wed, May 31, 2017 at 1:51 PM, Jakub Jelinek <jakub@redhat.com> wrote:
> On Wed, May 31, 2017 at 01:46:00PM +0200, Richard Biener wrote:
>> Just wanting to add that "ab-"using options/variables to implement
>> what are really
>> function attributes doesn't look very clean.  Unless the plan is to get rid of
>> function attributes in favor of per-function options.
>
> Function attribute here is one thing (the way user writes it) and that
> combined with the command line options determines the sanitization performed
> (the function attributes only say what sanitization flags should be
> ignored).  The proposed per-function variable is just a cache of this
> information, because parsing function attributes every time is way too
> expensive.

True, but isn't that just an excuse to not improve attribute list
representation?

Ideally we'd have sth like attributes.def and a sorted vector of
integer id, args
pairs.  Using a sorted vector of the existing stuff (compared to the tree list)
might also help.

Yes, we'd get (quite?) a bit less attribute list sharing this way but
we can still
share the actual tree-whatever thing that represents the args.

Richard.

>
>         Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]