summaryrefslogtreecommitdiffstats
path: root/binutils-2.25/ld/testsuite/ld-arm/ifunc-12.s
blob: 388ac34c261d6dfbe8363a93d884295cebece85d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
	.syntax unified
	.arch armv6t2

	.macro	define,name,type
	.type	\name,%gnu_indirect_function
	\type
\name:
	mov	pc,lr
	.size	\name,.-\name
	.endm

	.macro	test_relocs,name
	ldr	r4,1f
	ldr	r4,2f
1:
	.word	\name(GOT)
2:
	.word	\name(GOT_PREL)
	.endm

	.global	f2
	.global	f2t

	.global	f3
	.hidden	f3
	.global	f3t
	.hidden	f3t

	define	f1,.arm
	define	f2,.arm
	define	f3,.arm

	define	f1t,.thumb_func
	define	f2t,.thumb_func
	define	f3t,.thumb_func

	.globl	_start
_start:
	test_relocs foo
	test_relocs f1
	test_relocs f2
	test_relocs f3
	test_relocs f1t
	test_relocs f2t
	test_relocs f3t
	.size	_start,.-_start

	.data
foo:
	.word	0x11223344
	.word	f1
	.word	f2
	.word	f3
	.word	f1t
	.word	f2t
	.word	f3t
	.word	__irel_start
	.word	__irel_end