ObjFW  Check-in [21244a7e62]

Overview
Comment:Use `bti c` instead of `bti jc`

The `j` isn't necessary, as tail call eliminations can just use x16/x17,
which allow any type.

Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | 1.0
Files: files | file ages | folders
SHA3-256: 21244a7e6291184a1ebc69033682fc99783961ffd8daf9d2179250a750456e3c
User & Date: js on 2024-02-24 22:30:47
Other Links: branch diff | manifest | tags
Context
2024-02-25
21:19
OFLHAArchiveEntry: Create more compatible archives check-in: 431696dee5 user: js tags: 1.0
2024-02-24
22:30
Use `bti c` instead of `bti jc` check-in: 21244a7e62 user: js tags: 1.0
22:30
Use `bti c` instead of `bti jc` check-in: ddb7ebcf5b user: js tags: trunk
21:15
Set version to 1.0.10 check-in: 8f026dba58 user: js tags: 1.0, 1.0.10-release
Changes

Modified configure.ac from [5e8a507046] to [c0c6842cf8].

844
845
846
847
848
849
850
851

852
853
854
855
856
857
858
844
845
846
847
848
849
850

851
852
853
854
855
856
857
858







-
+







		AC_MSG_RESULT(no)
	])
	;;
aarch64* | arm64*)
	AC_MSG_CHECKING(for bti)
	AC_COMPILE_IFELSE([
		AC_LANG_PROGRAM([], [
			__asm__ __volatile__ ("bti jc");
			__asm__ __volatile__ ("bti c");
		])
	], [
		AC_DEFINE(HAVE_BTI, 1, [Whether we have bti])
		AC_MSG_RESULT(yes)
	], [
		AC_MSG_RESULT(no)
	])

Modified src/forwarding/apple-forwarding-arm64.S from [ff5af9e7d0] to [eb3a920f88].

30
31
32
33
34
35
36
37

38
39
40
41
42
43
44
30
31
32
33
34
35
36

37
38
39
40
41
42
43
44







-
+







	.long 0, 0

.section __TEXT, __text, regular, pure_instructions
.align 2
_OFForward:
_OFForward_stret:
#ifdef HAVE_BTI
	bti	jc
	bti	c
#endif

	stp	fp, lr, [sp, #-208]!
	mov	fp, sp
	sub	sp, sp, #208

	/* Save all arguments, x8 and x19 */

Modified src/forwarding/forwarding-arm64-elf.S from [d964627f1b] to [09fe8e02cc].

20
21
22
23
24
25
26
27

28
29
30
31
32
33
34
20
21
22
23
24
25
26

27
28
29
30
31
32
33
34







-
+







.globl OFForward
.globl OFForward_stret

.section .text
OFForward:
OFForward_stret:
#ifdef HAVE_BTI
	bti	jc
	bti	c
#endif

	stp	fp, lr, [sp, #-208]!
	mov	fp, sp
	sub	sp, sp, #208

	/* Save all arguments, x8 and x19 */

Modified src/runtime/lookup-asm/lookup-asm-arm64-elf.S from [bed2f1a908] to [3e4b869d59].

22
23
24
25
26
27
28
29

30
31
32
33
34
35
36
22
23
24
25
26
27
28

29
30
31
32
33
34
35
36







-
+







.globl objc_msg_lookup_super
.globl objc_msg_lookup_super_stret

.section .text
.macro GENERATE_LOOKUP name notFound
\name:
#ifdef HAVE_BTI
	bti	jc
	bti	c
#endif

	cbz	x0, returnNilMethod

	tst	x0, #1
	b.ne	.LtaggedPointer_\name

69
70
71
72
73
74
75
76

77
78
79
80
81
82
83
69
70
71
72
73
74
75

76
77
78
79
80
81
82
83







-
+







.type \name, %function
.size \name, .-\name
.endm

.macro GENERATE_LOOKUP_SUPER name lookup
\name:
#ifdef HAVE_BTI
	bti	jc
	bti	c
#endif

	mov	x2, x0
	ldr	x0, [x0]
	cbz	x0, returnNilMethod

	ldr	x2, [x2, #8]