Skip to content

Commit 165246a

Browse files
committed
Simplify .s files very much
1 parent 607b92a commit 165246a

File tree

3 files changed

+26
-338
lines changed

3 files changed

+26
-338
lines changed
Lines changed: 9 additions & 115 deletions
Original file line numberDiff line numberDiff line change
@@ -1,128 +1,22 @@
1-
.globaltype __stack_pointer, i32
21
.functype foo (i32) -> ()
32
.functype test0 () -> ()
3+
44
.section .text.foo,"",@
5-
.weak foo # -- Begin function foo
5+
.weak foo
66
.type foo,@function
7-
foo: # @foo
8-
.Lfunc_begin0:
7+
foo:
98
.functype foo (i32) -> ()
10-
# %bb.0:
11-
# fallthrough-return
129
end_function
13-
.Lfunc_end0:
14-
# -- End function
10+
1511
.section .text.test0,"",@
16-
.globl test0 # -- Begin function test0
12+
.globl test0
1713
.type test0,@function
18-
test0: # @test0
19-
.Lfunc_begin1:
14+
test0:
2015
.functype test0 () -> ()
21-
# %bb.0:
2216
i32.const 3
2317
call foo
24-
# fallthrough-return
2518
end_function
26-
.Lfunc_end1:
27-
# -- End function
28-
.file 1 "a.c"
29-
.section .debug_abbrev,"",@
30-
.int8 1 # Abbreviation Code
31-
.int8 17 # DW_TAG_compile_unit
32-
.int8 1 # DW_CHILDREN_yes
33-
.int8 37 # DW_AT_producer
34-
.int8 14 # DW_FORM_strp
35-
.int8 19 # DW_AT_language
36-
.int8 5 # DW_FORM_data2
37-
.int8 3 # DW_AT_name
38-
.int8 14 # DW_FORM_strp
39-
.int8 16 # DW_AT_stmt_list
40-
.int8 23 # DW_FORM_sec_offset
41-
.int8 17 # DW_AT_low_pc
42-
.int8 1 # DW_FORM_addr
43-
.int8 85 # DW_AT_ranges
44-
.int8 23 # DW_FORM_sec_offset
45-
.int8 0 # EOM(1)
46-
.int8 0 # EOM(2)
47-
.int8 2 # Abbreviation Code
48-
.int8 46 # DW_TAG_subprogram
49-
.int8 0 # DW_CHILDREN_no
50-
.int8 17 # DW_AT_low_pc
51-
.int8 1 # DW_FORM_addr
52-
.int8 18 # DW_AT_high_pc
53-
.int8 6 # DW_FORM_data4
54-
.int8 64 # DW_AT_frame_base
55-
.int8 24 # DW_FORM_exprloc
56-
.int8 3 # DW_AT_name
57-
.int8 14 # DW_FORM_strp
58-
.int8 58 # DW_AT_decl_file
59-
.int8 11 # DW_FORM_data1
60-
.int8 59 # DW_AT_decl_line
61-
.int8 11 # DW_FORM_data1
62-
.int8 39 # DW_AT_prototyped
63-
.int8 25 # DW_FORM_flag_present
64-
.int8 63 # DW_AT_external
65-
.int8 25 # DW_FORM_flag_present
66-
.int8 0 # EOM(1)
67-
.int8 0 # EOM(2)
68-
.int8 3 # Abbreviation Code
69-
.int8 46 # DW_TAG_subprogram
70-
.int8 0 # DW_CHILDREN_no
71-
.int8 17 # DW_AT_low_pc
72-
.int8 1 # DW_FORM_addr
73-
.int8 18 # DW_AT_high_pc
74-
.int8 6 # DW_FORM_data4
75-
.int8 64 # DW_AT_frame_base
76-
.int8 24 # DW_FORM_exprloc
77-
.int8 3 # DW_AT_name
78-
.int8 14 # DW_FORM_strp
79-
.int8 58 # DW_AT_decl_file
80-
.int8 11 # DW_FORM_data1
81-
.int8 59 # DW_AT_decl_line
82-
.int8 11 # DW_FORM_data1
83-
.int8 63 # DW_AT_external
84-
.int8 25 # DW_FORM_flag_present
85-
.int8 0 # EOM(1)
86-
.int8 0 # EOM(2)
87-
.int8 0 # EOM(3)
19+
8820
.section .debug_info,"",@
89-
.Lcu_begin0:
90-
.int32 .Ldebug_info_end0-.Ldebug_info_start0 # Length of Unit
91-
.Ldebug_info_start0:
92-
.int16 4 # DWARF version number
93-
.int32 .debug_abbrev0 # Offset Into Abbrev. Section
94-
.int8 4 # Address Size (in bytes)
95-
.int8 1 # Abbrev [1] 0xb:0x46 DW_TAG_compile_unit
96-
.int32 .Linfo_string0 # DW_AT_producer
97-
.int16 29 # DW_AT_language
98-
.int32 .Linfo_string1 # DW_AT_name
99-
.int32 .Lline_table_start0 # DW_AT_stmt_list
100-
.int32 0 # DW_AT_low_pc
101-
.int32 .Ldebug_ranges0 # DW_AT_ranges
102-
.int8 2 # Abbrev [2] 0x22:0x17 DW_TAG_subprogram
103-
.int32 .Lfunc_begin0 # DW_AT_low_pc
104-
.int32 .Lfunc_end0-.Lfunc_begin0 # DW_AT_high_pc
105-
.int8 7 # DW_AT_frame_base
106-
.int8 237
107-
.int8 3
108-
.int32 __stack_pointer
109-
.int8 159
110-
.int32 .Linfo_string2 # DW_AT_name
111-
.int8 1 # DW_AT_decl_file
112-
.int8 3 # DW_AT_decl_line
113-
# DW_AT_prototyped
114-
# DW_AT_external
115-
.int8 3 # Abbrev [3] 0x39:0x17 DW_TAG_subprogram
116-
.int32 .Lfunc_begin1 # DW_AT_low_pc
117-
.int32 .Lfunc_end1-.Lfunc_begin1 # DW_AT_high_pc
118-
.int8 7 # DW_AT_frame_base
119-
.int8 237
120-
.int8 3
121-
.int32 __stack_pointer
122-
.int8 159
123-
.int32 .Linfo_string3 # DW_AT_name
124-
.int8 1 # DW_AT_decl_file
125-
.int8 7 # DW_AT_decl_line
126-
# DW_AT_external
127-
.int8 0 # End Of Children Mark
128-
.Ldebug_info_end0:
21+
.int32 foo
22+
.int32 test0
Lines changed: 8 additions & 115 deletions
Original file line numberDiff line numberDiff line change
@@ -1,129 +1,22 @@
1-
.globaltype __stack_pointer, i32
21
.functype foo (i32, i32) -> ()
32
.functype test1 () -> ()
43
.section .text.foo,"",@
5-
.weak foo # -- Begin function foo
4+
.weak foo
65
.type foo,@function
7-
foo: # @foo
8-
.Lfunc_begin0:
6+
foo:
97
.functype foo (i32, i32) -> ()
10-
# %bb.0:
11-
# fallthrough-return
128
end_function
13-
.Lfunc_end0:
14-
# -- End function
9+
1510
.section .text.test1,"",@
16-
.globl test1 # -- Begin function test1
11+
.globl test1
1712
.type test1,@function
18-
test1: # @test1
19-
.Lfunc_begin1:
13+
test1:
2014
.functype test1 () -> ()
21-
# %bb.0:
2215
i32.const 4
2316
i32.const 5
2417
call foo
25-
# fallthrough-return
2618
end_function
27-
.Lfunc_end1:
28-
# -- End function
29-
.file 1 "b.c"
30-
.section .debug_abbrev,"",@
31-
.int8 1 # Abbreviation Code
32-
.int8 17 # DW_TAG_compile_unit
33-
.int8 1 # DW_CHILDREN_yes
34-
.int8 37 # DW_AT_producer
35-
.int8 14 # DW_FORM_strp
36-
.int8 19 # DW_AT_language
37-
.int8 5 # DW_FORM_data2
38-
.int8 3 # DW_AT_name
39-
.int8 14 # DW_FORM_strp
40-
.int8 16 # DW_AT_stmt_list
41-
.int8 23 # DW_FORM_sec_offset
42-
.int8 17 # DW_AT_low_pc
43-
.int8 1 # DW_FORM_addr
44-
.int8 85 # DW_AT_ranges
45-
.int8 23 # DW_FORM_sec_offset
46-
.int8 0 # EOM(1)
47-
.int8 0 # EOM(2)
48-
.int8 2 # Abbreviation Code
49-
.int8 46 # DW_TAG_subprogram
50-
.int8 0 # DW_CHILDREN_no
51-
.int8 17 # DW_AT_low_pc
52-
.int8 1 # DW_FORM_addr
53-
.int8 18 # DW_AT_high_pc
54-
.int8 6 # DW_FORM_data4
55-
.int8 64 # DW_AT_frame_base
56-
.int8 24 # DW_FORM_exprloc
57-
.int8 3 # DW_AT_name
58-
.int8 14 # DW_FORM_strp
59-
.int8 58 # DW_AT_decl_file
60-
.int8 11 # DW_FORM_data1
61-
.int8 59 # DW_AT_decl_line
62-
.int8 11 # DW_FORM_data1
63-
.int8 39 # DW_AT_prototyped
64-
.int8 25 # DW_FORM_flag_present
65-
.int8 63 # DW_AT_external
66-
.int8 25 # DW_FORM_flag_present
67-
.int8 0 # EOM(1)
68-
.int8 0 # EOM(2)
69-
.int8 3 # Abbreviation Code
70-
.int8 46 # DW_TAG_subprogram
71-
.int8 0 # DW_CHILDREN_no
72-
.int8 17 # DW_AT_low_pc
73-
.int8 1 # DW_FORM_addr
74-
.int8 18 # DW_AT_high_pc
75-
.int8 6 # DW_FORM_data4
76-
.int8 64 # DW_AT_frame_base
77-
.int8 24 # DW_FORM_exprloc
78-
.int8 3 # DW_AT_name
79-
.int8 14 # DW_FORM_strp
80-
.int8 58 # DW_AT_decl_file
81-
.int8 11 # DW_FORM_data1
82-
.int8 59 # DW_AT_decl_line
83-
.int8 11 # DW_FORM_data1
84-
.int8 63 # DW_AT_external
85-
.int8 25 # DW_FORM_flag_present
86-
.int8 0 # EOM(1)
87-
.int8 0 # EOM(2)
88-
.int8 0 # EOM(3)
19+
8920
.section .debug_info,"",@
90-
.Lcu_begin0:
91-
.int32 .Ldebug_info_end0-.Ldebug_info_start0 # Length of Unit
92-
.Ldebug_info_start0:
93-
.int16 4 # DWARF version number
94-
.int32 .debug_abbrev0 # Offset Into Abbrev. Section
95-
.int8 4 # Address Size (in bytes)
96-
.int8 1 # Abbrev [1] 0xb:0x46 DW_TAG_compile_unit
97-
.int32 .Linfo_string0 # DW_AT_producer
98-
.int16 29 # DW_AT_language
99-
.int32 .Linfo_string1 # DW_AT_name
100-
.int32 .Lline_table_start0 # DW_AT_stmt_list
101-
.int32 0 # DW_AT_low_pc
102-
.int32 .Ldebug_ranges0 # DW_AT_ranges
103-
.int8 2 # Abbrev [2] 0x22:0x17 DW_TAG_subprogram
104-
.int32 .Lfunc_begin0 # DW_AT_low_pc
105-
.int32 .Lfunc_end0-.Lfunc_begin0 # DW_AT_high_pc
106-
.int8 7 # DW_AT_frame_base
107-
.int8 237
108-
.int8 3
109-
.int32 __stack_pointer
110-
.int8 159
111-
.int32 .Linfo_string2 # DW_AT_name
112-
.int8 1 # DW_AT_decl_file
113-
.int8 3 # DW_AT_decl_line
114-
# DW_AT_prototyped
115-
# DW_AT_external
116-
.int8 3 # Abbrev [3] 0x39:0x17 DW_TAG_subprogram
117-
.int32 .Lfunc_begin1 # DW_AT_low_pc
118-
.int32 .Lfunc_end1-.Lfunc_begin1 # DW_AT_high_pc
119-
.int8 7 # DW_AT_frame_base
120-
.int8 237
121-
.int8 3
122-
.int32 __stack_pointer
123-
.int8 159
124-
.int32 .Linfo_string3 # DW_AT_name
125-
.int8 1 # DW_AT_decl_file
126-
.int8 7 # DW_AT_decl_line
127-
# DW_AT_external
128-
.int8 0 # End Of Children Mark
129-
.Ldebug_info_end0:
21+
.int32 foo
22+
.int32 test1

0 commit comments

Comments
 (0)