summaryrefslogtreecommitdiff
path: root/ext/systemc/src/sysc/qt/md/vax_b.s
blob: 2db2d4fec40c47bd4f24d3363de702e43c19a48c (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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
/*
 * QuickThreads -- Threads-building toolkit.
 * Copyright (c) 1993 by David Keppel
 *
 * Permission to use, copy, modify and distribute this software and
 * its documentation for any purpose and without fee is hereby
 * granted, provided that the above copyright notice and this notice
 * appear in all copies.  This software is provided as a
 * proof-of-concept and for demonstration purposes; there is no
 * representation about the suitability of this software for any
 * purpose.
 */

	.text
	.globl _b_call_reg
	.globl _b_call_imm
	.globl _b_add
	.globl _b_load

_b_null:
	.word 0x0
	ret

_b_call_reg:
	.word 0x0
	movl 4(ap),r0
	moval _b_null,r1
L0:
	calls $0,(r1)
	calls $0,(r1)
	calls $0,(r1)
	calls $0,(r1)
	calls $0,(r1)

	subl2 $5,r0
	bgtr L0
	ret


_b_call_imm:
	.word 0x0
	movl 4(ap),r0
L1:
	calls $0,_b_null
	calls $0,_b_null
	calls $0,_b_null
	calls $0,_b_null
	calls $0,_b_null

	subl2 $5,r0
	bgtr L1
	ret


_b_add:
	.word 0x0
	movl 4(ap),r0
L2:
	subl2 $1,r0
	subl2 $1,r0
	subl2 $1,r0
	subl2 $1,r0
	subl2 $1,r0

	subl2 $1,r0
	subl2 $1,r0
	subl2 $1,r0
	subl2 $1,r0
	subl2 $1,r0

	bgtr L2
	ret


_b_load:
	.word 0x0
	movl 4(ap),r0
L3:
	movl 0(sp),r1
	movl 4(sp),r1
	movl 8(sp),r1
	movl 12(sp),r1
	movl 16(sp),r1
	movl 20(sp),r1
	movl 24(sp),r1
	movl 28(sp),r1
	movl 32(sp),r1
	movl 36(sp),r1

	subl2 $1,r0
	bgtr L3
	ret