Skip to content

Commit f0555ce

Browse files
authored
Rollup merge of #89880 - adamgemmell:dev/nc-relocation, r=Amanieu
Use non-checking TLS relocation in aarch64 asm! sym test. The checking variant ensures that the offset required is not larger than 12 bits - hence we wouldn't ever need the upper 12 bits. It's unlikely to ever fail in this small test but this is technically correct. This was noticed incidentally when we found that LLD doesn't support the `tprel_lo12` relocation, even though LLVM can apparently generate it when using `-mtls-size=12`.
2 parents e2c28ad + af5b146 commit f0555ce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/test/ui/asm/aarch64/sym.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ macro_rules! static_tls_addr {
5555
// Add the top 12 bits of the symbol's offset
5656
"add {out}, {out}, :tprel_hi12:{sym}",
5757
// And the bottom 12 bits
58-
"add {out}, {out}, :tprel_lo12:{sym}",
58+
"add {out}, {out}, :tprel_lo12_nc:{sym}",
5959
out = out(reg) result,
6060
sym = sym $s
6161
);

0 commit comments

Comments
 (0)