gcc param min-pagesize

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello

I saw this part of the manual documents "min-pagesize" added by Martin Liska.

https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#Optimize-Options

"min-pagesize
Minimum page size for warning purposes."

Could anyone give more explanation of it's purpose please? It sounds very useful.

I was expecting the value to be a pagesize, with zero disabling it. However, trying it out it seems it sets the lowest accessible address, is that the case? If so I can make a patch to clarify that in the manual.

I did a test where I set it to 257 with a struct at 0x100 and that does give the array-bounds warning still, so maybe it's actually just the minimum address.

https://godbolt.org/z/ohhv5eMvK

I had read on this ticket about setting --param=min-pagesize=0 to allow access to the first 0x1000 address range (for embedded) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106699#c1

Thanks
Jonny



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux