[Bug tree-optimization/122251] New: Missing LIM of aggegrate zeroing
pinskia at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Oct 10 22:13:41 GMT 2025
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122251
Bug ID: 122251
Summary: Missing LIM of aggegrate zeroing
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Keywords: missed-optimization
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: pinskia at gcc dot gnu.org
Target Milestone: ---
```
struct s1
{
int tl[12024];
};
struct s1 a;
void f(int n)
{
for (int i = 0; i < n; i++)
{
a = (struct s1){};
}
}
```
This should just be one memset of a instead of a loop.
More information about the Gcc-bugs
mailing list