summaryrefslogtreecommitdiffstats
path: root/lld/test/ELF/tls-static.s
blob: 61d504b2e85046c80d33ea226d4554edd944b7d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// REQUIRES: x86
// RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t
// RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %S/Inputs/shared.s -o %tso
// RUN: ld.lld -static %t -o %tout
// RUN: ld.lld %t -o %tout
// RUN: ld.lld -shared %tso -o %tshared

.global _start
_start:
  data16
  leaq  foobar@TLSGD(%rip), %rdi
  data16
  data16
  rex64
  callq  __tls_get_addr@PLT


.section        .tdata,"awT",@progbits
.global  foobar
foobar:
  .long   42
OpenPOWER on IntegriCloud