https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109609
--- Comment #17 from Gabriel Burca ---
Speaking of the size parameter, my workaround for the original issue was to
pre-compute the size argument a different way. This however resulted in a
warning that's both right and wrong. Here's the sample c
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109609
--- Comment #7 from Gabriel Burca ---
Here's the code that still fails with -O3 -fno-optimize-sibling-calls:
```
#include
#include
#define N 23
#define MAX_LEN 13
char dst[N + 1];
void stringify(uint64_t id) {
char buf[MAX_LEN];
char *pt
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109609
Bug ID: 109609
Summary: Invalid strncpy/strncat optimization in GCC 12
Product: gcc
Version: 12.2.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: