Lang Hames 8493467490 [JITLink][AArch64] Ensure that nulls remain null during ptrauth signing.
Signing a null pointer value can, and usually will, result in some high bits
being set, causing null checks to fail. E.g. in

extern void __attribute__((weak_import)) f(void);
void (*p) = &f;

if f is undefined then p should be null (left unsigned).

This patch updates lowerPointer64AuthEdgesToSigningFunction to check for
Pointer64Authenticated edges to null targets. Where found, these edges are
turned into plain Pointer64 edges (which we know from context will write a null
value to the fixup location), and signing instructions for these locations are
omitted from the signing function.
2025-02-28 15:19:41 +11:00
..