[llvm-bugs] [Bug 49124] New: error: conflicting types for '_m_prefetchw'

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Feb 10 04:22:06 PST 2021


            Bug ID: 49124
           Summary: error: conflicting types for '_m_prefetchw'
           Product: clang
           Version: 11.0
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: C
          Assignee: unassignedclangbugs at nondot.org
          Reporter: vturbanov at gmail.com
                CC: blitzrakete at gmail.com, dgregor at apple.com,
                    erik.pilkington at gmail.com, llvm-bugs at lists.llvm.org,
                    richard-llvm at metafoo.co.uk

There is a declaration collision, when trying to compile with Clang under
_m_prefetchw is declared in prfchwintrin.h as:
> static __inline__ void __attribute__((__always_inline__, __nodebug__))
_m_prefetchw(void *__P)

While there is a colliding declaration in Windows SDK's header winnt.h:
>_m_prefetchw (
>    _In_ volatile CONST VOID *Source
>    );

As an example, because of this collision the SDL library is failing to compile
with Clang on Windows 10. I'm currently developing some hacking method to
overcome this, but I a solution from Clang itself could actually be more
appropriate and stable.

You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210210/71284c02/attachment.html>

More information about the llvm-bugs mailing list