Hi, if you compile the attached testcase with -O2 -fno-inline -Wall, you get: In function 'process_array3': cc1: warning: 'process_array4' accessing 4 bytes in a region of size 3 [- Wstringop-overflow=] cc1: note: referencing argument 1 of type 'char[4]' t.c:6:6: note: in a call to function 'process_array4' 6 | void process_array4 (char a[4], int n) | ^~~~~~~~~~~~~~ cc1: warning: 'process_array4' accessing 4 bytes in a region of size 3 [- Wstringop-overflow=] cc1: note: referencing argument 1 of type 'char[4]' t.c:6:6: note: in a call to function 'process_array4' That's because the ICF IPA pass has identified the two functions and turned process_array3 into a wrapper of process_array4. This looks sensible to me given that the only difference between them is an "access" attribute on their type describing the access size of the parameter and the "access" attribute does not affect type identity (struct attribute_spec.affects_type_identity). Hence the proposed fix, tested on x86-64/Linux, OK for the mainline? 2022-10-13 Eric Botcazou * gimple-ssa-warn-access.cc (pass_waccess::check_call): Return early for calls made from thunks. 2022-10-13 Eric Botcazou * gcc.dg/Wstringop-overflow-89.c: New test. -- Eric Botcazou