diff options
Diffstat (limited to 'thumb2compact.s')
-rw-r--r-- | thumb2compact.s | 55 |
1 files changed, 55 insertions, 0 deletions
diff --git a/thumb2compact.s b/thumb2compact.s index ac79a79..cb79d52 100644 --- a/thumb2compact.s +++ b/thumb2compact.s @@ -30,6 +30,7 @@ NO_BIT_INSTRUCTIONS = 1 cmp r4,#0
beq end_mark_cafs
+ .thumb_func
mark_cafs_lp:
ldr r12,[r4,#-4]
str r12,[sp,#-4]!
@@ -57,6 +58,7 @@ mark_cafs_lp: tst r4,r4
bne mark_cafs_lp
+ .thumb_func
end_mark_cafs:
.if COMPACT_MARK_WITH_STACK
lao r12,stack_p,6
@@ -110,6 +112,7 @@ end_mark_cafs: @ compact the heap
+ .thumb_func
compact_heap:
.ifdef FINALIZERS
@@ -142,10 +145,12 @@ determine_free_finalizers_after_compact1: mov r9,r8
b finalizer_find_descriptor
+ .thumb_func
finalizer_find_descriptor_lp:
and r4,r4,#-4
mov r9,r4
ldr r4,[r4]
+ .thumb_func
finalizer_find_descriptor:
tst r4,#1
bne finalizer_find_descriptor_lp
@@ -161,6 +166,7 @@ finalizer_find_descriptor: str r9,[r8]
str r4,[r6]
+ .thumb_func
finalizer_no_reverse:
add r6,r8,#4
ldr r8,[r8,#4]
@@ -195,7 +201,9 @@ end_finalizers_after_compact1: str r12,[r6]
lao r12,finalizer_list,5
sto r4,r12,finalizer_list,5
+ .thumb_func
finalizer_list_already_reversed:
+ .thumb_func
finalizer_list_empty:
.if COMPACT_MARK_WITH_STACK
@@ -224,6 +232,7 @@ finalizer_list_empty: str r12,[sp,#-4]!
bl mark_stack_nodes
.endif
+ .thumb_func
free_finalizer_list_empty:
.endif
@@ -264,7 +273,9 @@ free_finalizer_list_empty: b skip_zeros
@ d0,a0,a2: free
+ .thumb_func
find_non_zero_long:
+ .thumb_func
skip_zeros:
subs r2,r2,#1
bcc end_copy
@@ -272,6 +283,7 @@ skip_zeros: cmp r9,#0
beq skip_zeros
@ a2: free
+ .thumb_func
end_skip_zeros:
lao r12,neg_heap_vector_plus_4,1
ldo r8,r12,neg_heap_vector_plus_4,1
@@ -279,12 +291,14 @@ end_skip_zeros: add r8,r11,r8,lsl #5
+ .thumb_func
bsf_and_copy_nodes:
neg r12,r9
and r12,r12,r9
clz r3,r12
rsb r3,r3,#31
+ .thumb_func
copy_nodes:
ldr r4,[r8,r3,lsl #2]
@@ -321,6 +335,7 @@ end_list_2: sub r3,r3,#256
sub r3,r3,#3
+ .thumb_func
copy_record_arguments_all_b:
str r3,[sp,#-4]!
lao r12,heap_vector,10
@@ -371,6 +386,7 @@ copy_argument_part_1r: add r8,r8,r1
add r8,r11,r8,lsl #5
+ .thumb_func
bit_in_this_word:
mov r12,#1
lsl r12,r12,r3
@@ -378,6 +394,7 @@ bit_in_this_word: ldr r3,[sp],#4
+ .thumb_func
copy_b_record_argument_part_arguments:
ldr r4,[r6],#4
str r4,[r10],#4
@@ -388,6 +405,7 @@ copy_b_record_argument_part_arguments: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
copy_record_arguments_aa:
mov r12,#(256+2)/2
sub r3,r3,r7
@@ -426,6 +444,7 @@ copy_record_argument_2: subs r3,r3,#1
bcc no_pointers_in_record
+ .thumb_func
copy_record_pointers:
ldr r7,[r6],#4
cmp r7,r6
@@ -444,23 +463,27 @@ copy_record_pointers_2: subs r3,r3,#1
bcs copy_record_pointers
+ .thumb_func
no_pointers_in_record:
ldr r3,[sp],#4
subs r3,r3,#1
bcc no_non_pointers_in_record
+ .thumb_func
copy_non_pointers_in_record:
ldr r4,[r6],#4
str r4,[r10],#4
subs r3,r3,#1
bcs copy_non_pointers_in_record
+ .thumb_func
no_non_pointers_in_record:
cmp r9,#0
bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
no_record_arguments:
subs r3,r3,#3
update_up_list_2:
@@ -490,6 +513,7 @@ copy_argument_part_2: copy_arguments_1:
str r4,[r10],#4
+ .thumb_func
copy_argument_part_arguments:
ldr r7,[r6],#4
cmp r7,r6
@@ -634,6 +658,7 @@ move_hnf_1_: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
move_record:
mov r12,#258/2
subs r3,r3,r12,lsl #1
@@ -741,6 +766,7 @@ move_record_3_2: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
bit_in_next_word:
sub r2,r2,#1
ldr r9,[r1],#4
@@ -787,9 +813,11 @@ move_record_1: bne move_hnf_1
b move_int_bool_or_char
+ .thumb_func
move_real_or_file:
ldr r4,[r6],#4
str r4,[r10],#4
+ .thumb_func
move_int_bool_or_char:
ldr r4,[r6],#4
str r4,[r10],#4
@@ -815,6 +843,7 @@ move_normal_hnf_0: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
move_real_file_string_or_array:
laol r12,__STRING__+2,__STRING___o_2,10
otoa r12,__STRING___o_2,10
@@ -836,6 +865,7 @@ cp_s_arg_lp3: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
move_array:
.ifdef DLL
laol r12,__ARRAY__+2,__ARRAY___o_2,2
@@ -846,6 +876,7 @@ move_array: cmp r9,#0
bne bsf_and_end_array_bit
+ .thumb_func
skip_zeros_a:
ldr r9,[r1],#4
sub r2,r2,#1
@@ -858,12 +889,14 @@ skip_zeros_a: add r8,r11,r8,lsl #5
+ .thumb_func
bsf_and_end_array_bit:
neg r12,r9
and r12,r12,r9
clz r3,r12
rsb r3,r3,#31
+ .thumb_func
end_array_bit:
bic r9,r9,r12
@@ -872,6 +905,7 @@ end_array_bit: cmp r6,r3
bne move_a_array
+ .thumb_func
move_b_array:
ldr r7,[r6]
str r7,[r10]
@@ -886,6 +920,7 @@ move_b_array: mov r4,r7
b cp_s_arg_lp3
+ .thumb_func
move_strict_basic_array:
mov r4,r7
laol r12,INT+2,INT_o_2,14
@@ -901,11 +936,13 @@ move_strict_basic_array: add r4,r4,r4
b cp_s_arg_lp3
+ .thumb_func
move_bool_array:
add r4,r4,#3
lsr r4,r4,#2
b cp_s_arg_lp3
+ .thumb_func
move_a_array:
mov r7,r3
subs r3,r3,r6
@@ -935,6 +972,7 @@ move_a_array: cmp r4,r9
beq st_move_array_lp
+ .thumb_func
move_array_ab:
str r6,[sp,#-4]!
@@ -961,6 +999,7 @@ move_array_ab: move_array_ab_lp1:
ldr r4,[sp,#8]
+ .thumb_func
move_array_ab_a_elements:
ldr r3,[r6],#4
cmp r3,r6
@@ -974,18 +1013,21 @@ move_array_ab_a_elements: add r10,r10,#1
str r10,[r7]
subs r10,r10,#1
+ .thumb_func
move_array_element_ab:
str r3,[r10],#4
subs r4,r4,#1
bcs move_array_ab_a_elements
ldr r4,[sp,#4]
+ .thumb_func
move_array_ab_b_elements:
ldr r3,[r6],#4
str r3,[r10],#4
subs r4,r4,#1
bcs move_array_ab_b_elements
+ .thumb_func
st_move_array_lp_ab:
ldr r12,[sp]
subs r12,r12,#1
@@ -1015,12 +1057,15 @@ move_array_lp1: b end_array
+ .thumb_func
move_array_element:
str r4,[r10,#-4]
+ .thumb_func
st_move_array_lp:
subs r3,r3,#1
bcs move_array_lp1
+ .thumb_func
end_array:
ldr r9,[sp],#4
@@ -1028,6 +1073,7 @@ end_array: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
move_lazy_node:
mov r7,r4
ldr r3,[r7,#-4]
@@ -1040,6 +1086,7 @@ move_lazy_node: cmp r3,#256
bge move_closure_with_unboxed_arguments
+ .thumb_func
move_lazy_node_arguments:
ldr r7,[r6],#4
cmp r7,r6
@@ -1060,6 +1107,7 @@ move_lazy_node_arguments: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
move_lazy_node_arguments_:
str r7,[r10],#4
subs r3,r3,#1
@@ -1096,6 +1144,7 @@ move_lazy_node_0: bne bsf_and_copy_nodes
b find_non_zero_long
+ .thumb_func
move_closure_with_unboxed_arguments:
beq move_closure_with_unboxed_arguments_1
add r3,r3,#1
@@ -1107,6 +1156,7 @@ move_closure_with_unboxed_arguments: str r4,[sp,#-4]!
+ .thumb_func
move_closure_with_unboxed_arguments_lp:
ldr r7,[r6],#4
cmp r7,r6
@@ -1126,6 +1176,7 @@ move_closure_with_unboxed_arguments_lp: ldr r4,[sp],#4
b move_non_pointers_of_closure
+ .thumb_func
move_closure_with_unboxed_arguments_:
str r7,[r10],#4
subs r3,r3,#1
@@ -1133,6 +1184,7 @@ move_closure_with_unboxed_arguments_: ldr r4,[sp],#4
+ .thumb_func
move_non_pointers_of_closure:
ldr r3,[r6],#4
str r3,[r10],#4
@@ -1197,12 +1249,14 @@ move_closure_with_unboxed_arguments_1: .endif
.endif
+ .thumb_func
end_copy:
.ifdef FINALIZERS
lao r12,finalizer_list,6
ldo r6,r12,finalizer_list,6
+ .thumb_func
restore_finalizer_descriptors:
laol r12,__Nil-4,__Nil_o_m4,8
otoa r12,__Nil_o_m4,8
@@ -1215,5 +1269,6 @@ restore_finalizer_descriptors: ldr r6,[r6,#4]
b restore_finalizer_descriptors
+ .thumb_func
end_restore_finalizer_descriptors:
.endif
|