diff options
Diffstat (limited to 'thumb2mark.s')
-rw-r--r-- | thumb2mark.s | 109 |
1 files changed, 109 insertions, 0 deletions
diff --git a/thumb2mark.s b/thumb2mark.s index a4168c8..d1df94d 100644 --- a/thumb2mark.s +++ b/thumb2mark.s @@ -40,6 +40,7 @@ ZERO_ARITY_DESCRIPTOR_OFFSET = -4 tst r4,r4
beq _end_mark_cafs
+ .thumb_func
_mark_cafs_lp:
ldr r3,[r4]
ldr r8,[r4,#-4]
@@ -59,6 +60,7 @@ _mark_cafs_lp: tst r4,r4
bne _mark_cafs_lp
+ .thumb_func
_end_mark_cafs:
lao r12,stack_top,2
ldo r9,r12,stack_top,2
@@ -77,6 +79,7 @@ _end_mark_cafs: cmp r6,#0
beq end_restore_arrays
+ .thumb_func
restore_arrays:
ldr r3,[r6]
laol r12,__ARRAY__+2,__ARRAY___o_2,16
@@ -123,9 +126,11 @@ restore_arrays: .word 1332920885
.word -1108378657
+ .thumb_func
skip_mod_inverse_table:
mul r3,r8,r3
+ .thumb_func
restore_lazy_array:
ldr r10,[r6,#8]
ldr r8,[r6,#4]
@@ -155,6 +160,7 @@ restore_lazy_array: str r12,[sp,#-4]!
bl reorder
+ .thumb_func
no_reorder_array:
mov r6,r9
cmp r6,#0
@@ -174,6 +180,7 @@ restore_array_size_1: tst r6,r6
bne restore_arrays
+ .thumb_func
end_restore_arrays:
.ifdef FINALIZERS
@@ -185,6 +192,7 @@ end_restore_arrays: otoa r7,free_finalizer_list,4
ldr r8,[r6]
+ .thumb_func
determine_free_finalizers_after_mark:
laol r12,__Nil-4,__Nil_o_m4,4
otoa r12,__Nil_o_m4,4
@@ -206,6 +214,7 @@ determine_free_finalizers_after_mark: ldr r8,[r8,#4]
b determine_free_finalizers_after_mark
+ .thumb_func
finalizer_not_used_after_mark:
str r8,[r7]
add r7,r8,#4
@@ -214,6 +223,7 @@ finalizer_not_used_after_mark: str r8,[r6]
b determine_free_finalizers_after_mark
+ .thumb_func
end_finalizers_after_mark:
str r8,[r7]
.endif
@@ -265,6 +275,7 @@ end_finalizers_after_mark: ldo r3,r12,heap_size_33,8
lsl r3,r3,#5
+ .thumb_func
not_largest_heap:
cmp r3,r9
bls no_larger_heap
@@ -275,10 +286,12 @@ not_largest_heap: cmp r3,r9
bls not_larger_then_heap
mov r3,r9
+ .thumb_func
not_larger_then_heap:
lsr r4,r3,#2
lao r12,bit_vector_size,4
sto r4,r12,bit_vector_size,4
+ .thumb_func
no_larger_heap:
.endif
mov r8,r4
@@ -294,6 +307,7 @@ no_larger_heap: mov r12,#0
str r12,[r10,r8,lsl #2]
+ .thumb_func
no_extra_word:
sub r4,r4,r2
lsl r4,r4,#2
@@ -337,6 +351,7 @@ _no_heap_use_message2: mov r6,r10
mov r2,#0
+ .thumb_func
_scan_bits:
ldr r12,[r6]
cmp r3,r12
@@ -349,6 +364,7 @@ _scan_bits: sto r2,r12,n_free_words_after_mark,5
b _end_scan
+ .thumb_func
_zero_bits:
add r7,r6,#4
add r6,r6,#4
@@ -359,6 +375,7 @@ _zero_bits: sto r2,r12,n_free_words_after_mark,6
b _end_bits
+ .thumb_func
_skip_zero_bits_lp:
cmp r4,#0
bne _end_zero_bits
@@ -377,6 +394,7 @@ _skip_zero_bits_lp1: subs r4,r4,r7
b _end_bits2
+ .thumb_func
_end_zero_bits:
sub r4,r6,r7
lsl r4,r4,#3
@@ -387,6 +405,7 @@ _end_zero_bits: blo _scan_bits
@ n_free_words_after_mark updated
+ .thumb_func
_found_free_memory:
lao r12,n_free_words_after_mark,8
sto r2,r12,n_free_words_after_mark,8
@@ -414,6 +433,7 @@ _found_free_memory: ldmia sp!,{r0-r4,pc}
@ n_free_words_after_mark updated
+ .thumb_func
_end_bits:
sub r4,r6,r7
add r4,r4,#4
@@ -428,6 +448,7 @@ _end_bits2: sto r2,r12,n_free_words_after_mark,9
@ n_free_words_after_mark updated
+ .thumb_func
_end_scan:
lao r12,bit_counter,4
sto r8,r12,bit_counter,4
@@ -488,11 +509,13 @@ _end_scan: @ a4: heap_vector
@ d0,d1,a0,a1,a3: free
+ .thumb_func
_mark_stack_nodes:
lao r12,end_vector,2
ldo r12,r12,end_vector,2
cmp r8,r12
beq _end_mark_nodes
+ .thumb_func
_mark_stack_nodes_:
ldr r6,[r8],#4
@@ -516,6 +539,7 @@ _mark_stack_nodes_: mov r9,#1
b __mark_node
+ .thumb_func
__end_mark_using_reversal:
ldr r8,[sp],#4
str r6,[r8,#-4]
@@ -544,9 +568,11 @@ _mark_record_2_c: blo __mark_using_reversal
_mark_node2:
+ .thumb_func
_shared_argument_part:
ldr r6,[r6]
+ .thumb_func
_mark_node:
sub r7,r6,r0
cmp r7,r1
@@ -562,6 +588,7 @@ _mark_node: tst r9,r12
bne _mark_next_node
+ .thumb_func
_mark_arguments:
ldr r4,[r6]
tst r4,#2
@@ -609,6 +636,7 @@ fits_in_word_1: tst r9,r12
bne _shared_argument_part
+ .thumb_func
_no_shared_argument_part:
orr r12,r12,r9
str r12,[r10,r3,lsl #2]
@@ -631,6 +659,7 @@ fits_in_word_2: sub r8,r8,#2
str r3,[sp,#-4]!
+ .thumb_func
_push_hnf_args:
ldr r3,[r7,#-4]!
str r3,[sp,#-4]!
@@ -701,6 +730,7 @@ _mark_selector_node_1: cmp r12,#2
bls _small_tuple_or_record
+ .thumb_func
_large_tuple_or_record:
ldr r8,[r7,#8]
sub r8,r8,r0
@@ -742,6 +772,7 @@ _mark_tuple_selector_node_2: str r6,[r8]
b _mark_node
+ .thumb_func
_small_tuple_or_record:
lao r8,e__system__nind,12
.ifdef PIC
@@ -840,6 +871,7 @@ _mark_strict_record_selector_node_1: tst r8,r12
bne _mark_node3
+ .thumb_func
_select_from_small_record:
.ifdef PIC
ldr r12,[r4,#-8]
@@ -889,11 +921,13 @@ _mark_strict_record_selector_node_5: str r4,[r6]
b _mark_next_node
+ .thumb_func
_mark_indirection_node:
_mark_node3:
mov r6,r7
b _mark_node
+ .thumb_func
_mark_next_node:
ldr r6,[sp],#4
tst r6,r6
@@ -905,9 +939,11 @@ _mark_next_node: cmp r8,r12
bne _mark_stack_nodes_
+ .thumb_func
_end_mark_nodes:
ldr pc,[sp],#4
+ .thumb_func
_mark_lazy_node:
ldr r8,[r4,#-4]
tst r8,r8
@@ -935,6 +971,7 @@ _mark_lazy_node: str r7,[r12,r3,lsl #2]
fits_in_word_7:
sub r8,r8,#3
+ .thumb_func
_push_lazy_args:
ldr r3,[r6,#-4]!
str r3,[sp,#-4]!
@@ -948,6 +985,7 @@ _push_lazy_args: b __mark_using_reversal
+ .thumb_func
_mark_closure_with_unboxed_arguments:
mov r4,r8
and r8,r8,#255
@@ -979,6 +1017,7 @@ fits_in_word_7_: add r6,r12,r8,lsl #2
bne _push_lazy_args
+ .thumb_func
_mark_closure_with_one_boxed_argument:
ldr r6,[r6,#-4]
b _mark_node
@@ -998,6 +1037,7 @@ _mark_hnf_0: cmp r4,r12
bhi _mark_normal_hnf_0
+ .thumb_func
_mark_bool:
add r2,r2,#2
@@ -1014,12 +1054,14 @@ _mark_normal_hnf_0: add r2,r2,#1
b _mark_next_node
+ .thumb_func
_mark_real_file_or_string:
laol r12,__STRING__+2,__STRING___o_2,8
otoa r12,__STRING___o_2,8
cmp r4,r12
bls _mark_string_or_array
+ .thumb_func
_mark_real_or_file:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r9
@@ -1035,6 +1077,7 @@ _mark_real_or_file: str r9,[r12,r3,lsl #2]
b _mark_next_node
+ .thumb_func
_mark_record:
mov r12,#258/2
subs r8,r8,r12,lsl #1
@@ -1084,6 +1127,7 @@ fits_in_word_13: ldr r7,[r12,r4,lsl #2]
orr r7,r7,#1
str r7,[r12,r4,lsl #2]
+ .thumb_func
_push_record_arguments:
ldr r7,[r6,#4]
mov r8,r3
@@ -1138,9 +1182,11 @@ _mark_record_1: b _mark_bool
+ .thumb_func
_mark_string_or_array:
beq _mark_string_
+ .thumb_func
_mark_array:
ldr r8,[r6,#8]
cmp r8,#0
@@ -1162,6 +1208,7 @@ _mark_array: cmp r4,r8
beq _mark_a_record_array
+ .thumb_func
_mark_ab_record_array:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r9
@@ -1186,6 +1233,7 @@ _mark_ab_record_array: cmp r3,r4
bhs _last_ab_array_bits
+ .thumb_func
_mark_ab_array_lp:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
@@ -1194,11 +1242,13 @@ _mark_ab_array_lp: cmp r3,r4
blo _mark_ab_array_lp
+ .thumb_func
_last_ab_array_bits:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
str r12,[r10,r3,lsl #2]
+ .thumb_func
_end_set_ab_array_bits:
ldr r4,[r6,#4]
ldr r7,[r6,#8]
@@ -1216,6 +1266,7 @@ _end_set_ab_array_bits: str r12,[sp,#-4]!
b _mark_ab_array_begin
+ .thumb_func
_mark_ab_array:
ldr r3,[sp,#8]
str r4,[sp,#-4]!
@@ -1232,6 +1283,7 @@ _mark_ab_array: ldr r8,[sp],#4
ldr r4,[sp],#4
add r8,r8,r3
+ .thumb_func
_mark_ab_array_begin:
subs r4,r4,#1
bcs _mark_ab_array
@@ -1242,6 +1294,7 @@ _mark_ab_array_begin: add sp,sp,#12
b _mark_next_node
+ .thumb_func
_mark_a_record_array:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r9
@@ -1268,6 +1321,7 @@ _mark_a_record_array: cmp r3,r4
bhs _last_a_array_bits
+ .thumb_func
_mark_a_array_lp:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
@@ -1276,11 +1330,13 @@ _mark_a_array_lp: cmp r3,r4
blo _mark_a_array_lp
+ .thumb_func
_last_a_array_bits:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
str r12,[r10,r3,lsl #2]
+ .thumb_func
_end_set_a_array_bits:
ldr r4,[sp],#4
add r8,r6,#12
@@ -1302,6 +1358,7 @@ _end_set_a_array_bits: sto r6,r12,end_vector,9
b _mark_next_node
+ .thumb_func
_mark_lazy_array:
cmp sp,r11
blo _mark_array_using_reversal
@@ -1328,6 +1385,7 @@ _mark_lazy_array: cmp r3,r4
bhs _last_lazy_array_bits
+ .thumb_func
_mark_lazy_array_lp:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
@@ -1336,11 +1394,13 @@ _mark_lazy_array_lp: cmp r3,r4
blo _mark_lazy_array_lp
+ .thumb_func
_last_lazy_array_bits:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
str r12,[r10,r3,lsl #2]
+ .thumb_func
_end_set_lazy_array_bits:
ldr r4,[r6,#4]
add r8,r6,#12
@@ -1362,12 +1422,14 @@ _end_set_lazy_array_bits: sto r6,r12,end_vector,12
b _mark_next_node
+ .thumb_func
_mark_array_using_reversal:
mov r12,#0
str r12,[sp,#-4]!
mov r9,#1
b __mark_node
+ .thumb_func
_mark_strict_basic_array:
ldr r4,[r6,#4]
laol r12,INT+2,INT_o_2,8
@@ -1378,16 +1440,20 @@ _mark_strict_basic_array: otoa r12,BOOL_o_2,5
cmp r8,r12
beq _mark_strict_bool_array
+ .thumb_func
_mark_strict_real_array:
add r4,r4,r4
+ .thumb_func
_mark_strict_int_array:
add r4,r4,#3
b _mark_basic_array_
+ .thumb_func
_mark_strict_bool_array:
add r4,r4,#12+3
lsr r4,r4,#2
b _mark_basic_array_
+ .thumb_func
_mark_b_record_array:
ldr r8,[r6,#4]
sub r4,r4,#256
@@ -1395,11 +1461,13 @@ _mark_b_record_array: add r4,r4,#3
b _mark_basic_array_
+ .thumb_func
_mark_string_:
ldr r4,[r6,#4]
add r4,r4,#8+3
lsr r4,r4,#2
+ .thumb_func
_mark_basic_array_:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r9
@@ -1420,6 +1488,7 @@ _mark_basic_array_: cmp r3,r4
bhs _last_string_bits
+ .thumb_func
_mark_string_lp:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
@@ -1428,12 +1497,14 @@ _mark_string_lp: cmp r3,r4
blo _mark_string_lp
+ .thumb_func
_last_string_bits:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
str r12,[r10,r3,lsl #2]
b _mark_next_node
+ .thumb_func
__end_mark_using_reversal:
ldr r7,[sp],#4
tst r7,r7
@@ -1465,12 +1536,14 @@ __end_mark_using_reversal: .endif
.ltorg
+ .thumb_func
__mark_using_reversal:
str r6,[sp,#-4]!
mov r9,#1
ldr r6,[r6]
b __mark_node
+ .thumb_func
__mark_arguments:
ldr r4,[r6]
tst r4,#2
@@ -1520,6 +1593,7 @@ fits__in__word__1: tst r7,r12
bne __shared_argument_part
+ .thumb_func
__no_shared_argument_part:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r7
@@ -1568,6 +1642,7 @@ __mark_hnf_1: ldr r7,[r12,r3,lsl #2]
orr r7,r7,#1
str r7,[r12,r3,lsl #2]
+ .thumb_func
__shared_argument_part:
ldr r8,[r6]
str r9,[r6]
@@ -1675,6 +1750,7 @@ __mark_tuple_selector_node_2: str r6,[r8]
b __mark_node
+ .thumb_func
__small_tuple_or_record:
.ifdef PIC
ldr r12,[r4,#-8]
@@ -1736,6 +1812,7 @@ __mark_record_selector_node_1: tst r8,r12
bne __mark_no_selector_2
+ .thumb_func
__small_record:
.ifdef PIC
ldr r12,[r4,#-8]
@@ -1800,6 +1877,7 @@ __mark_strict_record_selector_node_1: tst r8,r12
bne __mark_no_selector_2
+ .thumb_func
__select_from_small_record:
.ifdef PIC
ldr r4,[r4,#-8]
@@ -1851,6 +1929,7 @@ __mark_strict_record_selector_node_5: str r4,[r6]
b __mark_node
+ .thumb_func
__mark_indirection_node:
ldr r6,[r6]
b __mark_node
@@ -1880,6 +1959,7 @@ __mark_record_2_c: add r9,r6,#4
mov r6,r8
+ .thumb_func
__mark_node:
sub r7,r6,r0
cmp r7,r1
@@ -1895,6 +1975,7 @@ __mark_node: tst r8,r12
beq __mark_arguments
+ .thumb_func
__mark_next_node:
tst r9,#3
bne __mark_parent
@@ -1911,6 +1992,7 @@ __mark_next_node: orr r9,r9,r8
b __mark_node
+ .thumb_func
__mark_parent:
mov r3,r9
bics r9,r9,#3
@@ -1927,6 +2009,7 @@ __mark_parent: mov r9,r8
b __mark_next_node
+ .thumb_func
__argument_part_parent:
and r8,r8,#-4
mov r7,r9
@@ -1937,6 +2020,7 @@ __argument_part_parent: add r9,r8,#2-4
b __mark_node
+ .thumb_func
__mark_lazy_node:
ldr r8,[r4,#-4]
tst r8,r8
@@ -1979,6 +2063,7 @@ __mark_closure_with_unboxed_arguments__2: mov r9,r7
b __mark_node
+ .thumb_func
__mark_closure_with_unboxed_arguments:
mov r4,r8
and r8,r8,#255
@@ -2029,6 +2114,7 @@ __mark_hnf_0: cmp r8,#33
blo ____small_int
+ .thumb_func
__mark_bool_or_small_string:
lsr r7,r7,#2
mov r12,#1
@@ -2045,6 +2131,7 @@ __mark_bool_or_small_string: str r7,[r12,r3,lsl #2]
b __mark_next_node
+ .thumb_func
____small_int:
lao r6,small_integers,2
otoa r6,small_integers,2
@@ -2071,12 +2158,14 @@ __no_char_3: add r6,r4,#ZERO_ARITY_DESCRIPTOR_OFFSET-2
b __mark_next_node
+ .thumb_func
__mark_real_file_or_string:
laol r12,__STRING__+2,__STRING___o_2,9
otoa r12,__STRING___o_2,9
cmp r4,r12
bls __mark_string_or_array
+ .thumb_func
__mark_real_or_file:
lsr r7,r7,#2
mov r12,#1
@@ -2096,6 +2185,7 @@ __mark_real_or_file: str r7,[r12,r3,lsl #2]
b __mark_next_node
+ .thumb_func
__mark__record:
mov r12,#258/2
subs r8,r8,r12,lsl #1
@@ -2183,6 +2273,7 @@ __mark_record_3_aab: mov r6,r8
b __mark_node
+ .thumb_func
__shared_record_argument_part:
ldr r7,[r6,#4]
@@ -2222,9 +2313,11 @@ __mark_record_1: sub r6,r6,#4
b __mark_bool_or_small_string
+ .thumb_func
__mark_string_or_array:
beq __mark_string_
+ .thumb_func
__mark_array:
ldr r8,[r6,#8]
cmp r8,#0
@@ -2242,6 +2335,7 @@ __mark_array: cmp r4,r8
beq __mark_a_record_array
+ .thumb_func
__mark__ab__record__array:
str r7,[sp,#-4]!
str r3,[sp,#-4]!
@@ -2291,16 +2385,19 @@ __mark__ab__record__array: add r7,r6,r4,lsl #2
b __mark_r_array
+ .thumb_func
__mark_a_record_array:
ldr r12,[r6,#4]
mul r4,r12,r4
add r6,r6,#8
b __mark_lr_array
+ .thumb_func
__mark_lazy_array:
ldr r4,[r6,#4]
add r6,r6,#8
+ .thumb_func
__mark_lr_array:
lsr r7,r7,#2
mov r12,#1
@@ -2310,6 +2407,7 @@ __mark_lr_array: str r12,[r10,r3,lsl #2]
add r7,r6,r4,lsl #2
sub r8,r7,r0
+ .thumb_func
__mark_r_array:
lsr r8,r8,#7
@@ -2318,6 +2416,7 @@ __mark_r_array: add r3,r3,#1
+ .thumb_func
__mark_lazy_array_bits:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,#1
@@ -2326,6 +2425,7 @@ __mark_lazy_array_bits: cmp r3,r8
bls __mark_lazy_array_bits
+ .thumb_func
__skip_mark_lazy_array_bits:
add r2,r2,#3
add r2,r2,r4
@@ -2377,6 +2477,7 @@ __mark_array_length_0_1: mov r6,r8
b __mark_node
+ .thumb_func
__mark_b_record_array:
ldr r8,[r6,#4]
sub r4,r4,#256
@@ -2384,6 +2485,7 @@ __mark_b_record_array: add r4,r4,#3
b __mark_basic_array
+ .thumb_func
__mark_strict_basic_array:
ldr r4,[r6,#4]
laol r12,INT+2,INT_o_2,10
@@ -2394,21 +2496,26 @@ __mark_strict_basic_array: otoa r12,BOOL_o_2,6
cmp r8,r12
beq __mark__strict__bool__array
+ .thumb_func
__mark__strict__real__array:
add r4,r4,r4
+ .thumb_func
__mark__strict__int__array:
add r4,r4,#3
b __mark_basic_array
+ .thumb_func
__mark__strict__bool__array:
add r4,r4,#12+3
lsr r4,r4,#2
b __mark_basic_array
+ .thumb_func
__mark_string_:
ldr r4,[r6,#4]
add r4,r4,#8+3
lsr r4,r4,#2
+ .thumb_func
__mark_basic_array:
lsr r7,r7,#2
mov r12,#1
@@ -2433,6 +2540,7 @@ __mark_basic_array: cmp r3,r4
bhs __last__string__bits
+ .thumb_func
__mark_string_lp:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
@@ -2441,6 +2549,7 @@ __mark_string_lp: cmp r3,r4
blo __mark_string_lp
+ .thumb_func
__last__string__bits:
ldr r12,[r10,r3,lsl #2]
orr r12,r12,r8
|