Hi Kevin,

I think this patch will break 32-bit ARM and 64-bit Darwin, both of
which define int64_t to be "long long" for various reasons (32-bit ARM
because "long" is 32-bits, Darwin because Just Because. ;-)).

ItaniumMangle should be fine: that mangling is only used on AArch64
non-Darwin so globally changing it is fine. Targets.cpp looks fine to
me as well.

For SemaChecking.cpp, the getNeonEltType is shared among all
implementations; perhaps give it another bool parameter and rename the
existing one? IsPolyUnsigned & IsInt64Long for example.

NeonEmitter.cpp is a bigger problem, since there doesn't appear to be
an "int64_t" type string available. It seems reasonably easy to add
one (lib/AST/ASTContext.cpp -- DecodeTypeFromStr and a comment in
Builtins.def), but I'm not sure if there's a better solution (we're
running out of letters!)

There are also a couple of bugs on the host side:

-        qmask |= 1ULL << GetNeonEnum(Proto, TypeVec[ti]);
+        qmask |= 1UL << GetNeonEnum(Proto, TypeVec[ti]);

qmask and mask are Clang-internal 64-bit variables. This change will
truncate various lines in arm_neon.inc (#included into
lib/Sema/SemaChecking.cpp) when Clang is built on platforms with a
32-bit long.

The same goes for the change to the "case".

Cheers.

Tim.
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to