> On Jul 10, 2025, at 12:56, Jakub Jelinek <ja...@redhat.com> wrote:
> 
> On Thu, Jul 10, 2025 at 04:03:30PM +0000, Qing Zhao wrote:
>> gcc/c-family/ChangeLog:
>> 
>> * c-ubsan.cc (get_bound_from_access_with_size): Adjust the position
>> of the arguments per the new design.
>> 
>> gcc/c/ChangeLog:
>> 
>> * c-typeck.cc (build_counted_by_ref): Update comments.
>> (build_access_with_size_for_counted_by): Adjust the arguments per
>> the new design.
>> 
>> gcc/ChangeLog:
>> 
>> * internal-fn.cc (expand_DEFERRED_INIT): Update comments.
>> * internal-fn.def (DEFERRED_INIT): Update comments.
>> * tree-object-size.cc (addr_object_size): Update comments.
>> (access_with_size_object_size): Adjust the arguments per the new
>> design.
> 
> Similar comment about ChangeLog entries as on the previous patch.

Sure, will check the changeling and update accordingly. 

> 
> I see only code passing 0 as the third argument (with the right type),
> so don't see why it is documented to be 0/1/2/3.  Or is that something
> done in the patch that got reverted?

ACCESS_MODE is only for a future work to reimplement the attribute
access with the internal function .ACCESS_WITH_SIZE. 

https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-access-function-attribute

For the current “counted_by”, this flag is not used at all.  Therefore only 0 
is passed. 

Hope this is clear. 
> 
> Jakub
> 

Reply via email to