Am Di., 23. Juni 2026 um 10:53 Uhr schrieb Uros Bizjak <[email protected]>:
>
> On Sun, Jun 21, 2026 at 2:38 PM Oleg Tolmatcev <[email protected]> 
> wrote:
> >
> > Match Clang's declaration of _m_prefetchw to avoid requiring
> > const_cast<void *> at call sites.
> >
> > gcc
> >         * config/i386/prfchwintrin.h (_m_prefetchw): Take
> >         volatile const void * instead of void *.
>
> This now matches Clang and the real Windows header rather than just
> MSVC's docs, but introduces a new warning with -Wcast-qual. Please
> wrap the builtin in
>
> #pragma GCC diagnostic push
> #pragma GCC diagnostic ignored "-Wcast-qual"
>   __builtin_prefetch (...)
> #pragma GCC diagnostic pop
>
> and add a testcase that checks that warning is not emitted with -Wcast-qual.

I will do that, but why is that necessary? It's a system header and by
default GCC
does not produce warnings for system headers even if you compile with
-Wcast-qual.

> Also, do you have commit rights to the source repository?

I don't.

Oleg

Reply via email to