-Werror=stringop-overflow -O3 returns false-positives on ppc64el
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gcc-12 (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
I have seen various ppc64el-specific build failures in lunar because of use of -Werror + -O3 and -Wstringop-overflow returing false positive results. E.g.:
[...]
mme_context.c: In function ‘mme_context_
mme_context.
1237 | network_
| ~~~~~~~
1238 | c_network_name[i];
| ~~~~~~~~~~~~~~~~~
mme_context.
29 | static mme_context_t self;
| ^~~~
mme_context.
1237 | network_
| ~~~~~~~
1238 | c_network_name[i];
| ~~~~~~~~~~~~~~~~~
mme_context.
29 | static mme_context_t self;
| ^~~~
[...]
https:/
There is no object of size 804192 here and these offsets appear to be fabricated out of whole cloth.
Note that either passing -Wno-error= stringop- overflow, or omitting -O3, is sufficient to work around this failure.