On Thu, Sep 14, 2023 at 3:42 PM Qing Zhao via Gcc-patches <gcc-patches@gcc.gnu.org> wrote: > > Hi, > > I have several questions on these options: > > 1.are pointers treated as signed integers in general? (I thought that > pointers are addresses to the memory, should be treated as unsigned integer…) > 2. If Yes, why? > 3. why a separate option for pointesr -fwrapv-pointer in addition to -fwrapv > if they are treated as signed integers?
Pointers are unsigned, they might sign-extend to Pmode though. -fwrapv-pointer is to enable wrapping over zero, we don't have many places using this, ISTR kernel folks requested to disable specific folding - digging in history might reveal the case/PR. Richard. > Thanks for your help. > > Qing >