[PATCH] D95822: [FE][AIX] Use i8 as guard variable type in both load and store operation

Hubert Tong via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 1 17:00:25 PST 2021


hubert.reinterpretcast added inline comments.


================
Comment at: clang/test/CodeGenCXX/aix-static-init-temp-spec-and-inline-var.cpp:193
 // CHECK:   %1 = call i32 @atexit(void ()* @__dtor__ZN5test12t1IiEE)
-// CHECK:   store i64 1, i64* @_ZGVN5test12t1IiEE
 // CHECK:   br label %init.end
----------------
Okay, so the store here is wrong, but it's got nothing to do with AIX.

The ABI doc (http://itanium-cxx-abi.github.io/cxx-abi/abi.html#once-ctor) says:
> the first byte (i.e., the byte with lowest address)

So the bug here seems to be that the Itanium ABI implementation in Clang is incorrect for big-endian systems.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D95822/new/

https://reviews.llvm.org/D95822



More information about the cfe-commits mailing list