Changes in libcfa/src/exception.c [e8261bb:8f910430]
- File:
-
- 1 edited
-
libcfa/src/exception.c (modified) (8 diffs)
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/exception.c
re8261bb r8f910430 27 27 #include "stdhdr/assert.h" 28 28 #include "virtual.h" 29 30 #if defined( __ARM_ARCH ) 31 #warning FIX ME: temporary hack to keep ARM build working 32 #ifndef _URC_FATAL_PHASE1_ERROR 33 #define _URC_FATAL_PHASE1_ERROR 3 34 #endif // ! _URC_FATAL_PHASE1_ERROR 35 #ifndef _URC_FATAL_PHASE2_ERROR 36 #define _URC_FATAL_PHASE2_ERROR 2 37 #endif // ! _URC_FATAL_PHASE2_ERROR 38 #endif // __ARM_ARCH 39 29 40 #include "lsda.h" 30 41 … … 290 301 } 291 302 292 #if defined( __x86_64 ) || defined( __i386 ) || defined( __ARM_ARCH )303 #if defined( __x86_64 ) || defined( __i386 ) 293 304 // This is our personality routine. For every stack frame annotated with 294 305 // ".cfi_personality 0x3,__gcfa_personality_v0" this function will be called twice when unwinding. … … 408 419 _Unwind_GetCFA(unwind_context) + 24; 409 420 # elif defined( __ARM_ARCH ) 410 _Unwind_GetCFA(unwind_context) + 40; 421 # warning FIX ME: check if anything needed for ARM 422 42; 411 423 # endif 412 424 int (*matcher)(exception_t *) = *(int(**)(exception_t *))match_pos; … … 525 537 // HEADER 526 538 ".LFECFA1:\n" 527 #if defined( __x86_64 ) || defined( __i386 )528 539 " .globl __gcfa_personality_v0\n" 529 #else // defined( __ARM_ARCH )530 " .global __gcfa_personality_v0\n"531 #endif532 540 " .section .gcc_except_table,\"a\",@progbits\n" 533 541 // TABLE HEADER (important field is the BODY length at the end) … … 561 569 // No clue what this does specifically 562 570 " .section .data.rel.local.CFA.ref.__gcfa_personality_v0,\"awG\",@progbits,CFA.ref.__gcfa_personality_v0,comdat\n" 563 #if defined( __x86_64 ) || defined( __i386 )564 571 " .align 8\n" 565 #else // defined( __ARM_ARCH )566 " .align 3\n"567 #endif568 572 " .type CFA.ref.__gcfa_personality_v0, @object\n" 569 573 " .size CFA.ref.__gcfa_personality_v0, 8\n" … … 571 575 #if defined( __x86_64 ) 572 576 " .quad __gcfa_personality_v0\n" 573 #el if defined( __i386 )577 #else // then __i386 574 578 " .long __gcfa_personality_v0\n" 575 #else // defined( __ARM_ARCH )576 " .xword __gcfa_personality_v0\n"577 579 #endif 578 580 ); … … 581 583 // HEADER 582 584 ".LFECFA1:\n" 583 #if defined( __x86_64 ) || defined( __i386 )584 585 " .globl __gcfa_personality_v0\n" 585 #else // defined( __ARM_ARCH )586 " .global __gcfa_personality_v0\n"587 #endif588 586 " .section .gcc_except_table,\"a\",@progbits\n" 589 587 // TABLE HEADER (important field is the BODY length at the end) … … 614 612 #pragma GCC pop_options 615 613 614 #elif defined( __ARM_ARCH ) 615 _Unwind_Reason_Code __gcfa_personality_v0( 616 int version, 617 _Unwind_Action actions, 618 unsigned long long exception_class, 619 struct _Unwind_Exception * unwind_exception, 620 struct _Unwind_Context * unwind_context) { 621 return _URC_CONTINUE_UNWIND; 622 } 623 624 __attribute__((noinline)) 625 void __cfaehm_try_terminate(void (*try_block)(), 626 void (*catch_block)(int index, exception_t * except), 627 __attribute__((unused)) int (*match_block)(exception_t * except)) { 628 } 616 629 #else 617 630 #error unsupported hardware architecture 618 #endif // __x86_64 || __i386 || __ARM_ARCH631 #endif // __x86_64 || __i386
Note:
See TracChangeset
for help on using the changeset viewer.