brintos

brintos / llvm-project-archived public Read only

0
0
Text · 13.5 KiB · f85b8a7 Raw
290 lines · plain
1/* Original C (for context):2* __attribute__((noinline))3* int main(int argc, char **argv) {4*   int i = argc;                 // i in a reg (DW_OP_regN)5*   asm volatile("" :: "r"(i));   // keep i live here6*   i = 0;                        // i becomes const 0 (DW_OP_constu 0, stack_value)7*   asm volatile("" :: "r"(i));   // keep the const range materialized8*   return 0;                     // i ends -> <undef> after its range9* }10*/11 12	.file	"seed_reg_const_undef.c"13	.text14	.globl	main                            # -- Begin function main15	.p2align	416	.type	main,@function17main:                                   # @main18.Lfunc_begin0:19	.file	0 "." "seed_reg_const_undef.c" md5 0x5e8dbf089d1bd72d395da802210b313820	.loc	0 3 0                           # seed_reg_const_undef.c:3:021	.cfi_startproc22# %bb.0:                                # %entry23	#DEBUG_VALUE: main:argc <- $edi24	#DEBUG_VALUE: main:argv <- $rsi25	pushq	%rbp26	.cfi_def_cfa_offset 1627	.cfi_offset %rbp, -1628	movq	%rsp, %rbp29	.cfi_def_cfa_register %rbp30.Ltmp0:31	#DEBUG_VALUE: main:i <- $edi32	.loc	0 5 3 prologue_end              # seed_reg_const_undef.c:5:333	#APP34	#NO_APP35.Ltmp1:36	#DEBUG_VALUE: main:i <- 037	.loc	0 7 3                           # seed_reg_const_undef.c:7:338	xorl	%eax, %eax39	#APP40	#NO_APP41	.loc	0 8 3                           # seed_reg_const_undef.c:8:342	xorl	%eax, %eax43	.loc	0 8 3 epilogue_begin is_stmt 0  # seed_reg_const_undef.c:8:344	popq	%rbp45	.cfi_def_cfa %rsp, 846	retq47.Ltmp2:48.Lfunc_end0:49	.size	main, .Lfunc_end0-main50	.cfi_endproc51                                        # -- End function52	.section	.debug_loclists,"",@progbits53	.long	.Ldebug_list_header_end0-.Ldebug_list_header_start0 # Length54.Ldebug_list_header_start0:55	.short	5                               # Version56	.byte	8                               # Address size57	.byte	0                               # Segment selector size58	.long	1                               # Offset entry count59.Lloclists_table_base0:60	.long	.Ldebug_loc0-.Lloclists_table_base061.Ldebug_loc0:62	.byte	4                               # DW_LLE_offset_pair63	.uleb128 .Ltmp0-.Lfunc_begin0           #   starting offset64	.uleb128 .Ltmp1-.Lfunc_begin0           #   ending offset65	.byte	1                               # Loc expr size66	.byte	85                              # super-register DW_OP_reg567	.byte	4                               # DW_LLE_offset_pair68	.uleb128 .Ltmp1-.Lfunc_begin0           #   starting offset69	.uleb128 .Lfunc_end0-.Lfunc_begin0      #   ending offset70	.byte	3                               # Loc expr size71	.byte	17                              # DW_OP_consts72	.byte	0                               # 073	.byte	159                             # DW_OP_stack_value74	.byte	0                               # DW_LLE_end_of_list75.Ldebug_list_header_end0:76	.section	.debug_abbrev,"",@progbits77	.byte	1                               # Abbreviation Code78	.byte	17                              # DW_TAG_compile_unit79	.byte	1                               # DW_CHILDREN_yes80	.byte	37                              # DW_AT_producer81	.byte	37                              # DW_FORM_strx182	.byte	19                              # DW_AT_language83	.byte	5                               # DW_FORM_data284	.byte	3                               # DW_AT_name85	.byte	37                              # DW_FORM_strx186	.byte	114                             # DW_AT_str_offsets_base87	.byte	23                              # DW_FORM_sec_offset88	.byte	16                              # DW_AT_stmt_list89	.byte	23                              # DW_FORM_sec_offset90	.byte	27                              # DW_AT_comp_dir91	.byte	37                              # DW_FORM_strx192	.byte	17                              # DW_AT_low_pc93	.byte	27                              # DW_FORM_addrx94	.byte	18                              # DW_AT_high_pc95	.byte	6                               # DW_FORM_data496	.byte	115                             # DW_AT_addr_base97	.byte	23                              # DW_FORM_sec_offset98	.ascii	"\214\001"                      # DW_AT_loclists_base99	.byte	23                              # DW_FORM_sec_offset100	.byte	0                               # EOM(1)101	.byte	0                               # EOM(2)102	.byte	2                               # Abbreviation Code103	.byte	46                              # DW_TAG_subprogram104	.byte	1                               # DW_CHILDREN_yes105	.byte	17                              # DW_AT_low_pc106	.byte	27                              # DW_FORM_addrx107	.byte	18                              # DW_AT_high_pc108	.byte	6                               # DW_FORM_data4109	.byte	64                              # DW_AT_frame_base110	.byte	24                              # DW_FORM_exprloc111	.byte	122                             # DW_AT_call_all_calls112	.byte	25                              # DW_FORM_flag_present113	.byte	3                               # DW_AT_name114	.byte	37                              # DW_FORM_strx1115	.byte	58                              # DW_AT_decl_file116	.byte	11                              # DW_FORM_data1117	.byte	59                              # DW_AT_decl_line118	.byte	11                              # DW_FORM_data1119	.byte	39                              # DW_AT_prototyped120	.byte	25                              # DW_FORM_flag_present121	.byte	73                              # DW_AT_type122	.byte	19                              # DW_FORM_ref4123	.byte	63                              # DW_AT_external124	.byte	25                              # DW_FORM_flag_present125	.byte	0                               # EOM(1)126	.byte	0                               # EOM(2)127	.byte	3                               # Abbreviation Code128	.byte	5                               # DW_TAG_formal_parameter129	.byte	0                               # DW_CHILDREN_no130	.byte	2                               # DW_AT_location131	.byte	24                              # DW_FORM_exprloc132	.byte	3                               # DW_AT_name133	.byte	37                              # DW_FORM_strx1134	.byte	58                              # DW_AT_decl_file135	.byte	11                              # DW_FORM_data1136	.byte	59                              # DW_AT_decl_line137	.byte	11                              # DW_FORM_data1138	.byte	73                              # DW_AT_type139	.byte	19                              # DW_FORM_ref4140	.byte	0                               # EOM(1)141	.byte	0                               # EOM(2)142	.byte	4                               # Abbreviation Code143	.byte	52                              # DW_TAG_variable144	.byte	0                               # DW_CHILDREN_no145	.byte	2                               # DW_AT_location146	.byte	34                              # DW_FORM_loclistx147	.byte	3                               # DW_AT_name148	.byte	37                              # DW_FORM_strx1149	.byte	58                              # DW_AT_decl_file150	.byte	11                              # DW_FORM_data1151	.byte	59                              # DW_AT_decl_line152	.byte	11                              # DW_FORM_data1153	.byte	73                              # DW_AT_type154	.byte	19                              # DW_FORM_ref4155	.byte	0                               # EOM(1)156	.byte	0                               # EOM(2)157	.byte	5                               # Abbreviation Code158	.byte	36                              # DW_TAG_base_type159	.byte	0                               # DW_CHILDREN_no160	.byte	3                               # DW_AT_name161	.byte	37                              # DW_FORM_strx1162	.byte	62                              # DW_AT_encoding163	.byte	11                              # DW_FORM_data1164	.byte	11                              # DW_AT_byte_size165	.byte	11                              # DW_FORM_data1166	.byte	0                               # EOM(1)167	.byte	0                               # EOM(2)168	.byte	6                               # Abbreviation Code169	.byte	15                              # DW_TAG_pointer_type170	.byte	0                               # DW_CHILDREN_no171	.byte	73                              # DW_AT_type172	.byte	19                              # DW_FORM_ref4173	.byte	0                               # EOM(1)174	.byte	0                               # EOM(2)175	.byte	0                               # EOM(3)176	.section	.debug_info,"",@progbits177.Lcu_begin0:178	.long	.Ldebug_info_end0-.Ldebug_info_start0 # Length of Unit179.Ldebug_info_start0:180	.short	5                               # DWARF version number181	.byte	1                               # DWARF Unit Type182	.byte	8                               # Address Size (in bytes)183	.long	.debug_abbrev                   # Offset Into Abbrev. Section184	.byte	1                               # Abbrev [1] 0xc:0x5b DW_TAG_compile_unit185	.byte	0                               # DW_AT_producer186	.short	29                              # DW_AT_language187	.byte	1                               # DW_AT_name188	.long	.Lstr_offsets_base0             # DW_AT_str_offsets_base189	.long	.Lline_table_start0             # DW_AT_stmt_list190	.byte	2                               # DW_AT_comp_dir191	.byte	0                               # DW_AT_low_pc192	.long	.Lfunc_end0-.Lfunc_begin0       # DW_AT_high_pc193	.long	.Laddr_table_base0              # DW_AT_addr_base194	.long	.Lloclists_table_base0          # DW_AT_loclists_base195	.byte	2                               # Abbrev [2] 0x27:0x2d DW_TAG_subprogram196	.byte	0                               # DW_AT_low_pc197	.long	.Lfunc_end0-.Lfunc_begin0       # DW_AT_high_pc198	.byte	1                               # DW_AT_frame_base199	.byte	86200                                        # DW_AT_call_all_calls201	.byte	3                               # DW_AT_name202	.byte	0                               # DW_AT_decl_file203	.byte	3                               # DW_AT_decl_line204                                        # DW_AT_prototyped205	.long	84                              # DW_AT_type206                                        # DW_AT_external207	.byte	3                               # Abbrev [3] 0x36:0xa DW_TAG_formal_parameter208	.byte	1                               # DW_AT_location209	.byte	85210	.byte	5                               # DW_AT_name211	.byte	0                               # DW_AT_decl_file212	.byte	3                               # DW_AT_decl_line213	.long	84                              # DW_AT_type214	.byte	3                               # Abbrev [3] 0x40:0xa DW_TAG_formal_parameter215	.byte	1                               # DW_AT_location216	.byte	84217	.byte	6                               # DW_AT_name218	.byte	0                               # DW_AT_decl_file219	.byte	3                               # DW_AT_decl_line220	.long	88                              # DW_AT_type221	.byte	4                               # Abbrev [4] 0x4a:0x9 DW_TAG_variable222	.byte	0                               # DW_AT_location223	.byte	8                               # DW_AT_name224	.byte	0                               # DW_AT_decl_file225	.byte	4                               # DW_AT_decl_line226	.long	84                              # DW_AT_type227	.byte	0                               # End Of Children Mark228	.byte	5                               # Abbrev [5] 0x54:0x4 DW_TAG_base_type229	.byte	4                               # DW_AT_name230	.byte	5                               # DW_AT_encoding231	.byte	4                               # DW_AT_byte_size232	.byte	6                               # Abbrev [6] 0x58:0x5 DW_TAG_pointer_type233	.long	93                              # DW_AT_type234	.byte	6                               # Abbrev [6] 0x5d:0x5 DW_TAG_pointer_type235	.long	98                              # DW_AT_type236	.byte	5                               # Abbrev [5] 0x62:0x4 DW_TAG_base_type237	.byte	7                               # DW_AT_name238	.byte	6                               # DW_AT_encoding239	.byte	1                               # DW_AT_byte_size240	.byte	0                               # End Of Children Mark241.Ldebug_info_end0:242	.section	.debug_str_offsets,"",@progbits243	.long	40                              # Length of String Offsets Set244	.short	5245	.short	0246.Lstr_offsets_base0:247	.section	.debug_str,"MS",@progbits,1248.Linfo_string0:249	.asciz	"clang version 22.0.0git (https://github.com/UltimateForce21/llvm-project.git 79c0a9e1e7da0f727c41d27c9c6ff8a28bb7d06f)" # string offset=0250.Linfo_string1:251	.asciz	"seed_reg_const_undef.c"        # string offset=119252.Linfo_string2:253	.asciz	"."                             # string offset=142254.Linfo_string3:255	.asciz	"main"                          # string offset=144256.Linfo_string4:257	.asciz	"int"                           # string offset=149258.Linfo_string5:259	.asciz	"argc"                          # string offset=153260.Linfo_string6:261	.asciz	"argv"                          # string offset=158262.Linfo_string7:263	.asciz	"char"                          # string offset=163264.Linfo_string8:265	.asciz	"i"                             # string offset=168266	.section	.debug_str_offsets,"",@progbits267	.long	.Linfo_string0268	.long	.Linfo_string1269	.long	.Linfo_string2270	.long	.Linfo_string3271	.long	.Linfo_string4272	.long	.Linfo_string5273	.long	.Linfo_string6274	.long	.Linfo_string7275	.long	.Linfo_string8276	.section	.debug_addr,"",@progbits277	.long	.Ldebug_addr_end0-.Ldebug_addr_start0 # Length of contribution278.Ldebug_addr_start0:279	.short	5                               # DWARF version number280	.byte	8                               # Address size281	.byte	0                               # Segment selector size282.Laddr_table_base0:283	.quad	.Lfunc_begin0284.Ldebug_addr_end0:285	.ident	"clang version 22.0.0git (https://github.com/UltimateForce21/llvm-project.git 79c0a9e1e7da0f727c41d27c9c6ff8a28bb7d06f)"286	.section	".note.GNU-stack","",@progbits287	.addrsig288	.section	.debug_line,"",@progbits289.Lline_table_start0:290