This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/66875] entire for loop got eliminated at cddce2 tree-opt stage


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66875

--- Comment #3 from Patrick S. <patricksung at gmail dot com> ---
argh...

my mistake to not check the termination condition is actually matching the size
of the prot_short_str[] array.  fixing that by properly calculating the array
size would fix the compilation now. Thanks!

But one more thing. Since the compiler can see the static size of the array,
wouldn't it be possible to have a warning for possible access of array size out
of bound?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]