コード例 #1
0
void
__deregister_frame (void *begin)
{
  /* If .eh_frame is empty, we haven't registered.  */
  if (*(uword *) begin != 0)
    free (__deregister_frame_info (begin));
}
コード例 #2
0
ファイル: crtstuff.c プロジェクト: qiyao/xcc
static void
__do_global_dtors_aux (void)
{
  static func_ptr *p = __DTOR_LIST__ + 1;
  static int completed = 0;

  if (completed)
    return;

#ifdef CRTSTUFFS_O
  if (__cxa_finalize)
    __cxa_finalize (__dso_handle);
#endif

  while (*p)
    {
      p++;
      (*(p-1)) ();
    }

#ifdef EH_FRAME_SECTION_ASM_OP
  if (__deregister_frame_info)
    __deregister_frame_info (__EH_FRAME_BEGIN__);
#endif
  completed = 1;
}
コード例 #3
0
ファイル: crtstuff.c プロジェクト: Akheon23/nvopencc
__do_global_dtors_aux (void)
{
  static func_ptr *p = __DTOR_LIST__ + 1;
  static _Bool completed;
  func_ptr f;

  if (__builtin_expect (completed, 0))
    return;

#ifdef CRTSTUFFS_O
  if (__cxa_finalize)
    __cxa_finalize (__dso_handle);
#endif

  while ((f = *p))
    {
      p++;
      f ();
    }

#ifdef USE_EH_FRAME_REGISTRY
#if defined(CRT_GET_RFIB_TEXT) || defined(CRT_GET_RFIB_DATA)
  /* If we used the new __register_frame_info_bases interface,
     make sure that we deregister from the same place.  */
  if (__deregister_frame_info_bases)
    __deregister_frame_info_bases (__EH_FRAME_BEGIN__);
#else
  if (__deregister_frame_info)
    __deregister_frame_info (__EH_FRAME_BEGIN__);
#endif
#endif

  completed = 1;
}
コード例 #4
0
ファイル: frvbegin.c プロジェクト: 0day-ci/gcc
/* Unregister the exception handling table as a deconstructor.  */
void
__frv_deregister_eh (void)
{
  static int completed = 0;

  if (completed)
    return;

  if (__deregister_frame_info)
    __deregister_frame_info (__EH_FRAME_BEGIN__);

  completed = 1;
}
コード例 #5
0
ファイル: soinit.c プロジェクト: mbref/glibc-236-microblaze
void
__libc_fini (void)
#endif
{
  /* Call destructor functions.  */
  run_hooks (__DTOR_LIST__);
#ifdef HAVE_DWARF2_UNWIND_INFO
# ifdef HAVE_DWARF2_UNWIND_INFO_STATIC
#  if defined CRT_GET_RFIB_TEXT || defined CRT_GET_RFIB_DATA
  __deregister_frame_info_bases (__EH_FRAME_BEGIN__);
#  else
  __deregister_frame_info (__EH_FRAME_BEGIN__);
#  endif
# else
  __deregister_frame (__EH_FRAME_BEGIN__);
# endif
#endif
}
コード例 #6
0
ファイル: crtstuff.c プロジェクト: bkeepers/cheribsd
__do_global_dtors_aux (void)
{
#ifndef FINI_ARRAY_SECTION_ASM_OP
  static func_ptr *p = __DTOR_LIST__ + 1;
  func_ptr f;
#endif /* !defined(FINI_ARRAY_SECTION_ASM_OP)  */
  static _Bool completed;

  if (__builtin_expect (completed, 0))
    return;

#ifdef CRTSTUFFS_O
  if (__cxa_finalize)
    __cxa_finalize (__dso_handle);
#endif

#ifdef FINI_ARRAY_SECTION_ASM_OP
  /* If we are using .fini_array then destructors will be run via that
     mechanism.  */
#else /* !defined (FINI_ARRAY_SECTION_ASM_OP) */
  while ((f = *p))
    {
      p++;
      f ();
    }
#endif /* !defined(FINI_ARRAY_SECTION_ASM_OP) */

#ifdef USE_EH_FRAME_REGISTRY
#ifdef CRT_GET_RFIB_DATA
  /* If we used the new __register_frame_info_bases interface,
     make sure that we deregister from the same place.  */
  if (__deregister_frame_info_bases)
    __deregister_frame_info_bases (__EH_FRAME_BEGIN__);
#else
  if (__deregister_frame_info)
    __deregister_frame_info (__EH_FRAME_BEGIN__);
#endif
#endif

  completed = 1;
}
コード例 #7
0
ファイル: frame.c プロジェクト: qiyao/xcc
void
__deregister_frame (void *begin)
{
  free (__deregister_frame_info (begin));
}
コード例 #8
0
/*
 * __attribute__((destructor)) places a call to the function in the
 * .fini_array section in PNaCl.  The function pointers in .fini_array
 * are then invoked in inverse order (__do_global_dtors_aux is invoked last)
 * at exit.
 */
static void __attribute__((destructor)) __do_eh_dtor(void) {
  __deregister_frame_info (__EH_FRAME_BEGIN__);
}
コード例 #9
0
ファイル: dyn_start.c プロジェクト: RobertGiff/Composite
__attribute__((section(".fini"))) void _fini(void)
{
    __do_global_dtors_aux();
    if (__deregister_frame_info)
        __deregister_frame_info(__EH_FRAME_BEGIN__);
}
コード例 #10
0
static void eh_dtor(void) {
    extern void *__deregister_frame_info (const void *);

    __deregister_frame_info(__EH_FRAME_BEGIN__);
}