[llvm-bugs] [Bug 48427] New: [powerpc] -m32 should not define __powerpc64__

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Dec 7 09:59:23 PST 2020


https://bugs.llvm.org/show_bug.cgi?id=48427

            Bug ID: 48427
           Summary: [powerpc] -m32 should not define __powerpc64__
           Product: clang
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Frontend
          Assignee: unassignedclangbugs at nondot.org
          Reporter: ndesaulniers at google.com
                CC: kit.barton at gmail.com, llvm-bugs at lists.llvm.org,
                    neeilans at live.com, richard-llvm at metafoo.co.uk,
                    srhines at google.com
            Blocks: 4068

For building the Linux kernel with Clang, particularly the 32b compat VDSO for
powerpc64, we build one image file using `--target=powerpc64le-linux-gnu -m32`.
 It looks like in this case Clang's preprocessor #defines __powerpc64__.  This
causes compatibility issues for building this code with Clang (as GCC does not
define this for -m32).

See also:
https://lore.kernel.org/linuxppc-dev/87czzlu7n4.fsf@mpe.ellerman.id.au/T/


Referenced Bugs:

https://bugs.llvm.org/show_bug.cgi?id=4068
[Bug 4068] [Meta] Compiling the Linux kernel with clang
-- 
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/20201207/35a4b538/attachment.html>


More information about the llvm-bugs mailing list