https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111394
Sayu <aiya64bits at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |UNCONFIRMED Resolution|INVALID |--- --- Comment #3 from Sayu <aiya64bits at gmail dot com> --- (In reply to Andrew Pinski from comment #1) > N could be -1 which then would access out of bounds .. > > I suspect if you add a check for n being negative in memoized_cut_rod the > warning will go away and a security issue is solved too. I see. I didn't realize that negative indexes are allowed in C, I always assumed it was undefined behavior or just invalid. However, what does "*r_30 + _122" mean in the warning?