1 2 3# TEST-OPTIONS: unwind_test_main.c unwind_test_x86.s -arch i386 -fexceptions 4# TEST-OPTIONS: unwind_test_main.c unwind_test_x86.s -arch i386 -fexceptions -Wl,-no_compact_unwind 5 6 .data 7.globl _unwind_tester_list 8_unwind_tester_list: 9 .long _test_no_reg 10 .long _test_ebx 11 .long _test_esi 12 .long _test_edi 13 .long _test_ebx_esi 14 .long _test_esi_edi 15 .long _test_esi_edi_ebp 16 .long _test_ebx_esi_edi 17 .long _test_ebx_esi_edi_ebp 18 .long _test_esi_ebp_ebx_edi 19 .long 0 20 21 22 .text 23 24.globl _test_ebx 25_test_ebx: 26LFB13: 27 pushl %ebx 28LCFI0: 29 subl $24, %esp 30LCFI1: 31 movl $0, %ebx 32 call _uwind_to_main 33 addl $24, %esp 34 popl %ebx 35 ret 36LFE13: 37 38 39.globl _test_no_reg 40_test_no_reg: 41LFB12: 42 subl $28, %esp 43LCFI2: 44 call _uwind_to_main 45 addl $28, %esp 46 ret 47LFE12: 48 49 50.globl _test_esi 51_test_esi: 52LFB10: 53 pushl %esi 54LCFI5: 55 subl $24, %esp 56LCFI6: 57 movl $0, %esi 58 call _uwind_to_main 59 addl $24, %esp 60 popl %esi 61 ret 62LFE10: 63 64 65.globl _test_edi 66_test_edi: 67LFB11: 68 pushl %edi 69LCFI3: 70 subl $24, %esp 71LCFI4: 72 movl $0, %edi 73 call _uwind_to_main 74 addl $24, %esp 75 popl %edi 76 ret 77LFE11: 78 79 80.globl _test_ebx_esi 81_test_ebx_esi: 82LFB9: 83 subl $28, %esp 84LCFI7: 85 movl %ebx, 20(%esp) 86LCFI8: 87 movl %esi, 24(%esp) 88LCFI9: 89 movl $0, %ebx 90 movl $0, %esi 91 call _uwind_to_main 92 movl 20(%esp), %ebx 93 movl 24(%esp), %esi 94 addl $28, %esp 95 ret 96LFE9: 97 98 99.globl _test_esi_edi 100_test_esi_edi: 101LFB8: 102 subl $28, %esp 103LCFI10: 104 movl %esi, 20(%esp) 105LCFI11: 106 movl %edi, 24(%esp) 107LCFI12: 108 movl $0, %esi 109 movl $0, %edi 110 call _uwind_to_main 111 movl 20(%esp), %esi 112 movl 24(%esp), %edi 113 addl $28, %esp 114 ret 115LFE8: 116 117 118 119.globl _test_ebx_esi_edi 120_test_ebx_esi_edi: 121LFB7: 122 subl $28, %esp 123LCFI13: 124 movl %ebx, 16(%esp) 125LCFI14: 126 movl %esi, 20(%esp) 127LCFI15: 128 movl %edi, 24(%esp) 129LCFI16: 130 movl $0, %ebx 131 movl $0, %esi 132 movl $0, %edi 133 call _uwind_to_main 134 movl 16(%esp), %ebx 135 movl 20(%esp), %esi 136 movl 24(%esp), %edi 137 addl $28, %esp 138 ret 139LFE7: 140 141 142.globl _test_esi_edi_ebp 143_test_esi_edi_ebp: 144LFB6: 145 subl $28, %esp 146LCFI17: 147 movl %esi, 16(%esp) 148LCFI18: 149 movl %edi, 20(%esp) 150LCFI19: 151 movl %ebp, 24(%esp) 152LCFI20: 153 movl $0, %esi 154 movl $0, %edi 155 movl $0, %ebp 156 call _uwind_to_main 157 movl 16(%esp), %esi 158 movl 20(%esp), %edi 159 movl 24(%esp), %ebp 160 addl $28, %esp 161 ret 162LFE6: 163 164 165.globl _test_ebx_esi_edi_ebp 166_test_ebx_esi_edi_ebp: 167LFB5: 168 subl $60, %esp 169LCFI21: 170 movl %ebx, 44(%esp) 171LCFI22: 172 movl %esi, 48(%esp) 173LCFI23: 174 movl %edi, 52(%esp) 175LCFI24: 176 movl %ebp, 56(%esp) 177LCFI25: 178 movl $0, %ebx 179 movl $0, %esi 180 movl $0, %edi 181 movl $0, %ebp 182 call _uwind_to_main 183 movl 44(%esp), %ebx 184 movl 48(%esp), %esi 185 movl 52(%esp), %edi 186 movl 56(%esp), %ebp 187 addl $60, %esp 188 ret 189LFE5: 190 191.globl _test_esi_ebp_ebx_edi 192_test_esi_ebp_ebx_edi: 193LFB5a: 194 subl $60, %esp 195LCFI21a: 196 movl %esi, 44(%esp) 197LCFI22a: 198 movl %ebp, 48(%esp) 199LCFI23a: 200 movl %ebx, 52(%esp) 201LCFI24a: 202 movl %edi, 56(%esp) 203LCFI25a: 204 movl $0, %esi 205 movl $0, %ebp 206 movl $0, %ebx 207 movl $0, %edi 208 call _uwind_to_main 209 movl 44(%esp), %esi 210 movl 48(%esp), %ebp 211 movl 52(%esp), %ebx 212 movl 56(%esp), %edi 213 addl $60, %esp 214 ret 215LFE5a: 216 217 218 .section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support 219EH_frame1: 220 .set L$set$0,LECIE1-LSCIE1 221 .long L$set$0 # Length of Common Information Entry 222LSCIE1: 223 .long 0x0 # CIE Identifier Tag 224 .byte 0x1 # CIE Version 225 .ascii "zR\0" # CIE Augmentation 226 .byte 0x1 # uleb128 0x1; CIE Code Alignment Factor 227 .byte 0x7c # sleb128 -4; CIE Data Alignment Factor 228 .byte 0x8 # CIE RA Column 229 .byte 0x1 # uleb128 0x1; Augmentation size 230 .byte 0x10 # FDE Encoding (pcrel) 231 .byte 0xc # DW_CFA_def_cfa 232 .byte 0x5 # uleb128 0x5 233 .byte 0x4 # uleb128 0x4 234 .byte 0x88 # DW_CFA_offset, column 0x8 235 .byte 0x1 # uleb128 0x1 236 .align 2 237LECIE1: 238 239 240.globl _test_ebx.eh 241_test_ebx.eh: 242LSFDE3: 243 .set L$set$1,LEFDE3-LASFDE3 244 .long L$set$1 # FDE Length 245LASFDE3: 246 .long LASFDE3-EH_frame1 # FDE CIE offset 247 .long LFB13-. # FDE initial location 248 .set L$set$2,LFE13-LFB13 249 .long L$set$2 # FDE address range 250 .byte 0x0 # uleb128 0x0; Augmentation size 251 .byte 0x4 # DW_CFA_advance_loc4 252 .set L$set$3,LCFI0-LFB13 253 .long L$set$3 254 .byte 0xe # DW_CFA_def_cfa_offset 255 .byte 0x8 # uleb128 0x8 256 .byte 0x4 # DW_CFA_advance_loc4 257 .set L$set$4,LCFI1-LCFI0 258 .long L$set$4 259 .byte 0xe # DW_CFA_def_cfa_offset 260 .byte 0x20 # uleb128 0x20 261 .byte 0x83 # DW_CFA_offset, column 0x3 262 .byte 0x2 # uleb128 0x2 263 .align 2 264LEFDE3: 265 266 267.globl _test_no_reg.eh 268_test_no_reg.eh: 269LSFDE5: 270 .set L$set$5,LEFDE5-LASFDE5 271 .long L$set$5 # FDE Length 272LASFDE5: 273 .long LASFDE5-EH_frame1 # FDE CIE offset 274 .long LFB12-. # FDE initial location 275 .set L$set$6,LFE12-LFB12 276 .long L$set$6 # FDE address range 277 .byte 0x0 # uleb128 0x0; Augmentation size 278 .byte 0x4 # DW_CFA_advance_loc4 279 .set L$set$7,LCFI2-LFB12 280 .long L$set$7 281 .byte 0xe # DW_CFA_def_cfa_offset 282 .byte 0x20 # uleb128 0x20 283 .align 2 284LEFDE5: 285 286 287.globl _test_esi.eh 288_test_esi.eh: 289LSFDE9: 290 .set L$set$12,LEFDE9-LASFDE9 291 .long L$set$12 # FDE Length 292LASFDE9: 293 .long LASFDE9-EH_frame1 # FDE CIE offset 294 .long LFB10-. # FDE initial location 295 .set L$set$13,LFE10-LFB10 296 .long L$set$13 # FDE address range 297 .byte 0x0 # uleb128 0x0; Augmentation size 298 .byte 0x4 # DW_CFA_advance_loc4 299 .set L$set$14,LCFI5-LFB10 300 .long L$set$14 301 .byte 0xe # DW_CFA_def_cfa_offset 302 .byte 0x8 # uleb128 0x8 303 .byte 0x4 # DW_CFA_advance_loc4 304 .set L$set$15,LCFI6-LCFI5 305 .long L$set$15 306 .byte 0xe # DW_CFA_def_cfa_offset 307 .byte 0x20 # uleb128 0x20 308 .byte 0x86 # DW_CFA_offset, column 0x6 309 .byte 0x2 # uleb128 0x2 310 .align 2 311LEFDE9: 312 313 314.globl _test_edi.eh 315_test_edi.eh: 316LSFDE10: 317 .set L$set$12a,LEFDE10-LASFDE10 318 .long L$set$12a # FDE Length 319LASFDE10: 320 .long LASFDE10-EH_frame1 # FDE CIE offset 321 .long LFB11-. # FDE initial location 322 .set L$set$13a,LFE11-LFB11 323 .long L$set$13a # FDE address range 324 .byte 0x0 # uleb128 0x0; Augmentation size 325 .byte 0x4 # DW_CFA_advance_loc4 326 .set L$set$14a,LCFI3-LFB11 327 .long L$set$14a 328 .byte 0xe # DW_CFA_def_cfa_offset 329 .byte 0x8 # uleb128 0x8 330 .byte 0x4 # DW_CFA_advance_loc4 331 .set L$set$15a,LCFI4-LCFI3 332 .long L$set$15a 333 .byte 0xe # DW_CFA_def_cfa_offset 334 .byte 0x20 # uleb128 0x20 335 .byte 0x87 # DW_CFA_offset, column 0x7 336 .byte 0x2 # uleb128 0x2 337 .align 2 338LEFDE10: 339 340 341 342.globl _test_ebx_esi.eh 343_test_ebx_esi.eh: 344LSFDE11: 345 .set L$set$16,LEFDE11-LASFDE11 346 .long L$set$16 # FDE Length 347LASFDE11: 348 .long LASFDE11-EH_frame1 # FDE CIE offset 349 .long LFB9-. # FDE initial location 350 .set L$set$17,LFE9-LFB9 351 .long L$set$17 # FDE address range 352 .byte 0x0 # uleb128 0x0; Augmentation size 353 .byte 0x4 # DW_CFA_advance_loc4 354 .set L$set$18,LCFI7-LFB9 355 .long L$set$18 356 .byte 0xe # DW_CFA_def_cfa_offset 357 .byte 0x20 # uleb128 0x20 358 .byte 0x4 # DW_CFA_advance_loc4 359 .set L$set$19,LCFI9-LCFI7 360 .long L$set$19 361 .byte 0x86 # DW_CFA_offset, column 0x6 362 .byte 0x2 # uleb128 0x2 363 .byte 0x83 # DW_CFA_offset, column 0x3 364 .byte 0x3 # uleb128 0x3 365 .align 2 366LEFDE11: 367 368 369.globl _test_esi_edi.eh 370_test_esi_edi.eh: 371LSFDE13: 372 .set L$set$20,LEFDE13-LASFDE13 373 .long L$set$20 # FDE Length 374LASFDE13: 375 .long LASFDE13-EH_frame1 # FDE CIE offset 376 .long LFB8-. # FDE initial location 377 .set L$set$21,LFE8-LFB8 378 .long L$set$21 # FDE address range 379 .byte 0x0 # uleb128 0x0; Augmentation size 380 .byte 0x4 # DW_CFA_advance_loc4 381 .set L$set$22,LCFI10-LFB8 382 .long L$set$22 383 .byte 0xe # DW_CFA_def_cfa_offset 384 .byte 0x20 # uleb128 0x20 385 .byte 0x4 # DW_CFA_advance_loc4 386 .set L$set$23,LCFI12-LCFI10 387 .long L$set$23 388 .byte 0x87 # DW_CFA_offset, column 0x7 389 .byte 0x2 # uleb128 0x2 390 .byte 0x86 # DW_CFA_offset, column 0x6 391 .byte 0x3 # uleb128 0x3 392 .align 2 393LEFDE13: 394 395 396.globl _test_ebx_esi_edi.eh 397_test_ebx_esi_edi.eh: 398LSFDE15: 399 .set L$set$24,LEFDE15-LASFDE15 400 .long L$set$24 # FDE Length 401LASFDE15: 402 .long LASFDE15-EH_frame1 # FDE CIE offset 403 .long LFB7-. # FDE initial location 404 .set L$set$25,LFE7-LFB7 405 .long L$set$25 # FDE address range 406 .byte 0x0 # uleb128 0x0; Augmentation size 407 .byte 0x4 # DW_CFA_advance_loc4 408 .set L$set$26,LCFI13-LFB7 409 .long L$set$26 410 .byte 0xe # DW_CFA_def_cfa_offset 411 .byte 0x20 # uleb128 0x20 412 .byte 0x4 # DW_CFA_advance_loc4 413 .set L$set$27,LCFI16-LCFI13 414 .long L$set$27 415 .byte 0x87 # DW_CFA_offset, column 0x7 416 .byte 0x2 # uleb128 0x2 417 .byte 0x86 # DW_CFA_offset, column 0x6 418 .byte 0x3 # uleb128 0x3 419 .byte 0x83 # DW_CFA_offset, column 0x3 420 .byte 0x4 # uleb128 0x4 421 .align 2 422LEFDE15: 423 424 425.globl _test_esi_edi_ebp.eh 426_test_esi_edi_ebp.eh: 427LSFDE17: 428 .set L$set$28,LEFDE17-LASFDE17 429 .long L$set$28 # FDE Length 430LASFDE17: 431 .long LASFDE17-EH_frame1 # FDE CIE offset 432 .long LFB6-. # FDE initial location 433 .set L$set$29,LFE6-LFB6 434 .long L$set$29 # FDE address range 435 .byte 0x0 # uleb128 0x0; Augmentation size 436 .byte 0x4 # DW_CFA_advance_loc4 437 .set L$set$30,LCFI17-LFB6 438 .long L$set$30 439 .byte 0xe # DW_CFA_def_cfa_offset 440 .byte 0x20 # uleb128 0x20 441 .byte 0x4 # DW_CFA_advance_loc4 442 .set L$set$31,LCFI20-LCFI17 443 .long L$set$31 444 .byte 0x84 # DW_CFA_offset, column 0x4 445 .byte 0x2 # uleb128 0x2 446 .byte 0x87 # DW_CFA_offset, column 0x7 447 .byte 0x3 # uleb128 0x3 448 .byte 0x86 # DW_CFA_offset, column 0x6 449 .byte 0x4 # uleb128 0x4 450 .align 2 451LEFDE17: 452 453 454.globl _test_ebx_esi_edi_ebp.eh 455_test_ebx_esi_edi_ebp.eh: 456LSFDE19: 457 .set L$set$32,LEFDE19-LASFDE19 458 .long L$set$32 # FDE Length 459LASFDE19: 460 .long LASFDE19-EH_frame1 # FDE CIE offset 461 .long LFB5-. # FDE initial location 462 .set L$set$33,LFE5-LFB5 463 .long L$set$33 # FDE address range 464 .byte 0x0 # uleb128 0x0; Augmentation size 465 .byte 0x4 # DW_CFA_advance_loc4 466 .set L$set$34,LCFI21-LFB5 467 .long L$set$34 468 .byte 0xe # DW_CFA_def_cfa_offset 469 .byte 0x40 # uleb128 0x40 470 .byte 0x4 # DW_CFA_advance_loc4 471 .set L$set$35,LCFI25-LCFI21 472 .long L$set$35 473 .byte 0x84 # DW_CFA_offset, column 0x4 474 .byte 0x2 # uleb128 0x2 475 .byte 0x87 # DW_CFA_offset, column 0x7 476 .byte 0x3 # uleb128 0x3 477 .byte 0x86 # DW_CFA_offset, column 0x6 478 .byte 0x4 # uleb128 0x4 479 .byte 0x83 # DW_CFA_offset, column 0x3 480 .byte 0x5 # uleb128 0x5 481 .align 2 482LEFDE19: 483 484.globl _test_esi_ebp_ebx_edi.eh 485_test_esi_ebp_ebx_edi.eh: 486LSFDE19a: 487 .set L$set$32a,LEFDE19a-LASFDE19a 488 .long L$set$32a # FDE Length 489LASFDE19a: 490 .long LASFDE19a-EH_frame1 # FDE CIE offset 491 .long LFB5a-. # FDE initial location 492 .set L$set$33a,LFE5a-LFB5a 493 .long L$set$33a # FDE address range 494 .byte 0x0 # uleb128 0x0; Augmentation size 495 .byte 0x4 # DW_CFA_advance_loc4 496 .set L$set$34a,LCFI21a-LFB5a 497 .long L$set$34a 498 .byte 0xe # DW_CFA_def_cfa_offset 499 .byte 0x40 # uleb128 0x40 500 .byte 0x4 # DW_CFA_advance_loc4 501 .set L$set$35a,LCFI25a-LCFI21a 502 .long L$set$35a 503 .byte 0x87 # DW_CFA_offset, column 0x7 504 .byte 0x2 # uleb128 0x2 505 .byte 0x83 # DW_CFA_offset, column 0x3 506 .byte 0x3 # uleb128 0x3 507 .byte 0x84 # DW_CFA_offset, column 0x4 508 .byte 0x4 # uleb128 0x4 509 .byte 0x86 # DW_CFA_offset, column 0x6 510 .byte 0x5 # uleb128 0x5 511 .align 2 512LEFDE19a: 513 514 515 516 .subsections_via_symbols 517