summaryrefslogtreecommitdiff
path: root/lang/kaffe/patches/patch-ag
blob: 4278bed9ecb229f37d8f6443c52c063d63555c24 (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
$NetBSD: patch-ag,v 1.3 2003/09/16 20:15:35 jmmv Exp $

--- config/i386/trampolines.c.orig	2003-08-11 13:01:10.966139000 +0100
+++ config/i386/trampolines.c	2003-08-11 13:13:31.960345000 +0100
@@ -33,10 +33,10 @@
 
 asm(
 	START_ASM_FUNC() C_FUNC_NAME(i386_do_fixup_trampoline) "\n"
-C_FUNC_NAME(i386_do_fixup_trampoline) ":			\n
-	call	" C_FUNC_NAME(soft_fixup_trampoline) "		\n
-	popl	%ecx						\n
-	jmp	*%eax"
+C_FUNC_NAME(i386_do_fixup_trampoline) ":			\n"
+"	call	" C_FUNC_NAME(soft_fixup_trampoline) "		\n"
+"	popl	%ecx						\n"
+"	jmp	*%eax"
 	END_ASM_FUNC()
 );
 
@@ -48,17 +48,16 @@
  */
 asm(
 	START_ASM_FUNC() C_FUNC_NAME(__kaffe_i386_gcj_fixup) "\n"
-C_FUNC_NAME(__kaffe_i386_gcj_fixup) ":
-	mov	(%esp), %eax	# get return address
-	add	-4(%eax), %eax	# add jump relative offset from previous instr.
-				# this points at at jmp *$off(%ebx) instr.
-	mov	2(%eax), %eax	# extract 'off'
-	add	%ebx, %eax	# compute $off(%ebx)
-	pushl	%eax		# pass as first argument
-	call	" C_FUNC_NAME(gcj_fixup_trampoline) " # returns target
-	addl	$4, %esp	# remove argument
-	jmp	*%eax		# jump to target
-"
+C_FUNC_NAME(__kaffe_i386_gcj_fixup) ":"
+"	mov	(%esp), %eax	# get return address\n"
+"	add	-4(%eax), %eax	# add jump relative offset from previous instr.\n"
+"				# this points at at jmp *$off(%ebx) instr.\n"
+"	mov	2(%eax), %eax	# extract 'off'\n"
+"	add	%ebx, %eax	# compute $off(%ebx)\n"
+"	pushl	%eax		# pass as first argument\n"
+"	call	" C_FUNC_NAME(gcj_fixup_trampoline) " # returns target\n"
+"	addl	$4, %esp	# remove argument\n"
+"	jmp	*%eax		# jump to target\n"
 	END_ASM_FUNC()
 );