404

[ Avaa Bypassed ]




Upload:

Command:

botdev@3.144.20.151: ~ $
/* backtrace.h -- Public header file for stack backtrace library.
   Copyright (C) 2012-2017 Free Software Foundation, Inc.
   Written by Ian Lance Taylor, Google.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:

    (1) Redistributions of source code must retain the above copyright
    notice, this list of conditions and the following disclaimer.

    (2) Redistributions in binary form must reproduce the above copyright
    notice, this list of conditions and the following disclaimer in
    the documentation and/or other materials provided with the
    distribution.

    (3) The name of the author may not be used to
    endorse or promote products derived from this software without
    specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.  */

#ifndef BACKTRACE_H
#define BACKTRACE_H

#include <stddef.h>
#include <stdio.h>

/* We want to get a definition for uintptr_t, but we still care about
   systems that don't have <stdint.h>.  */
#if defined(__GLIBC__) && __GLIBC__ >= 2

#include <stdint.h>

#elif defined(HAVE_STDINT_H)

#include <stdint.h>

#else

/* Systems that don't have <stdint.h> must provide gstdint.h, e.g.,
   from GCC_HEADER_STDINT in configure.ac.  */
#include "gstdint.h"

#endif

#ifdef __cplusplus
extern "C" {
#endif

/* The backtrace state.  This struct is intentionally not defined in
   the public interface.  */

struct backtrace_state;

/* The type of the error callback argument to backtrace functions.
   This function, if not NULL, will be called for certain error cases.
   The DATA argument is passed to the function that calls this one.
   The MSG argument is an error message.  The ERRNUM argument, if
   greater than 0, holds an errno value.  The MSG buffer may become
   invalid after this function returns.

   As a special case, the ERRNUM argument will be passed as -1 if no
   debug info can be found for the executable, but the function
   requires debug info (e.g., backtrace_full, backtrace_pcinfo).  The
   MSG in this case will be something along the lines of "no debug
   info".  Similarly, ERRNUM will be passed as -1 if there is no
   symbol table, but the function requires a symbol table (e.g.,
   backtrace_syminfo).  This may be used as a signal that some other
   approach should be tried.  */

typedef void (*backtrace_error_callback) (void *data, const char *msg,
					  int errnum);

/* Create state information for the backtrace routines.  This must be
   called before any of the other routines, and its return value must
   be passed to all of the other routines.  FILENAME is the path name
   of the executable file; if it is NULL the library will try
   system-specific path names.  If not NULL, FILENAME must point to a
   permanent buffer.  If THREADED is non-zero the state may be
   accessed by multiple threads simultaneously, and the library will
   use appropriate atomic operations.  If THREADED is zero the state
   may only be accessed by one thread at a time.  This returns a state
   pointer on success, NULL on error.  If an error occurs, this will
   call the ERROR_CALLBACK routine.  */

extern struct backtrace_state *backtrace_create_state (
    const char *filename, int threaded,
    backtrace_error_callback error_callback, void *data);

/* The type of the callback argument to the backtrace_full function.
   DATA is the argument passed to backtrace_full.  PC is the program
   counter.  FILENAME is the name of the file containing PC, or NULL
   if not available.  LINENO is the line number in FILENAME containing
   PC, or 0 if not available.  FUNCTION is the name of the function
   containing PC, or NULL if not available.  This should return 0 to
   continuing tracing.  The FILENAME and FUNCTION buffers may become
   invalid after this function returns.  */

typedef int (*backtrace_full_callback) (void *data, uintptr_t pc,
					const char *filename, int lineno,
					const char *function);

/* Get a full stack backtrace.  SKIP is the number of frames to skip;
   passing 0 will start the trace with the function calling
   backtrace_full.  DATA is passed to the callback routine.  If any
   call to CALLBACK returns a non-zero value, the stack backtrace
   stops, and backtrace returns that value; this may be used to limit
   the number of stack frames desired.  If all calls to CALLBACK
   return 0, backtrace returns 0.  The backtrace_full function will
   make at least one call to either CALLBACK or ERROR_CALLBACK.  This
   function requires debug info for the executable.  */

extern int backtrace_full (struct backtrace_state *state, int skip,
			   backtrace_full_callback callback,
			   backtrace_error_callback error_callback,
			   void *data);

/* The type of the callback argument to the backtrace_simple function.
   DATA is the argument passed to simple_backtrace.  PC is the program
   counter.  This should return 0 to continue tracing.  */

typedef int (*backtrace_simple_callback) (void *data, uintptr_t pc);

/* Get a simple backtrace.  SKIP is the number of frames to skip, as
   in backtrace.  DATA is passed to the callback routine.  If any call
   to CALLBACK returns a non-zero value, the stack backtrace stops,
   and backtrace_simple returns that value.  Otherwise
   backtrace_simple returns 0.  The backtrace_simple function will
   make at least one call to either CALLBACK or ERROR_CALLBACK.  This
   function does not require any debug info for the executable.  */

extern int backtrace_simple (struct backtrace_state *state, int skip,
			     backtrace_simple_callback callback,
			     backtrace_error_callback error_callback,
			     void *data);

/* Print the current backtrace in a user readable format to a FILE.
   SKIP is the number of frames to skip, as in backtrace_full.  Any
   error messages are printed to stderr.  This function requires debug
   info for the executable.  */

extern void backtrace_print (struct backtrace_state *state, int skip, FILE *);

/* Given PC, a program counter in the current program, call the
   callback function with filename, line number, and function name
   information.  This will normally call the callback function exactly
   once.  However, if the PC happens to describe an inlined call, and
   the debugging information contains the necessary information, then
   this may call the callback function multiple times.  This will make
   at least one call to either CALLBACK or ERROR_CALLBACK.  This
   returns the first non-zero value returned by CALLBACK, or 0.  */

extern int backtrace_pcinfo (struct backtrace_state *state, uintptr_t pc,
			     backtrace_full_callback callback,
			     backtrace_error_callback error_callback,
			     void *data);

/* The type of the callback argument to backtrace_syminfo.  DATA and
   PC are the arguments passed to backtrace_syminfo.  SYMNAME is the
   name of the symbol for the corresponding code.  SYMVAL is the
   value and SYMSIZE is the size of the symbol.  SYMNAME will be NULL
   if no error occurred but the symbol could not be found.  */

typedef void (*backtrace_syminfo_callback) (void *data, uintptr_t pc,
					    const char *symname,
					    uintptr_t symval,
					    uintptr_t symsize);

/* Given ADDR, an address or program counter in the current program,
   call the callback information with the symbol name and value
   describing the function or variable in which ADDR may be found.
   This will call either CALLBACK or ERROR_CALLBACK exactly once.
   This returns 1 on success, 0 on failure.  This function requires
   the symbol table but does not require the debug info.  Note that if
   the symbol table is present but ADDR could not be found in the
   table, CALLBACK will be called with a NULL SYMNAME argument.
   Returns 1 on success, 0 on error.  */

extern int backtrace_syminfo (struct backtrace_state *state, uintptr_t addr,
			      backtrace_syminfo_callback callback,
			      backtrace_error_callback error_callback,
			      void *data);

#ifdef __cplusplus
} /* End extern "C".  */
#endif

#endif

Filemanager

Name Type Size Permission Actions
cilk Folder 0755
sanitizer Folder 0755
adxintrin.h File 2.8 KB 0644
ammintrin.h File 3.14 KB 0644
avx2intrin.h File 56.67 KB 0644
avx5124fmapsintrin.h File 6.38 KB 0644
avx5124vnniwintrin.h File 4.16 KB 0644
avx512bwintrin.h File 98.41 KB 0644
avx512cdintrin.h File 5.69 KB 0644
avx512dqintrin.h File 76.14 KB 0644
avx512erintrin.h File 12.66 KB 0644
avx512fintrin.h File 428.66 KB 0644
avx512ifmaintrin.h File 3.35 KB 0644
avx512ifmavlintrin.h File 5.26 KB 0644
avx512pfintrin.h File 9.8 KB 0644
avx512vbmiintrin.h File 4.81 KB 0644
avx512vbmivlintrin.h File 8.17 KB 0644
avx512vlbwintrin.h File 138.97 KB 0644
avx512vldqintrin.h File 59.88 KB 0644
avx512vlintrin.h File 413.31 KB 0644
avx512vpopcntdqintrin.h File 3.03 KB 0644
avxintrin.h File 48.29 KB 0644
backtrace-supported.h File 2.91 KB 0644
backtrace.h File 8.55 KB 0644
bmi2intrin.h File 3.31 KB 0644
bmiintrin.h File 5.5 KB 0644
bmmintrin.h File 1.13 KB 0644
clflushoptintrin.h File 1.62 KB 0644
clwbintrin.h File 1.55 KB 0644
clzerointrin.h File 1.46 KB 0644
cpuid.h File 8.3 KB 0644
cross-stdarg.h File 2.5 KB 0644
emmintrin.h File 49.84 KB 0644
f16cintrin.h File 3.33 KB 0644
float.h File 16.52 KB 0644
fma4intrin.h File 8.92 KB 0644
fmaintrin.h File 10.29 KB 0644
fxsrintrin.h File 2.06 KB 0644
gcov.h File 1.36 KB 0644
ia32intrin.h File 7.63 KB 0644
immintrin.h File 4.87 KB 0644
iso646.h File 1.24 KB 0644
lwpintrin.h File 3.32 KB 0644
lzcntintrin.h File 2.34 KB 0644
mm3dnow.h File 6.91 KB 0644
mm_malloc.h File 1.74 KB 0644
mmintrin.h File 30.62 KB 0644
mwaitxintrin.h File 1.71 KB 0644
nmmintrin.h File 1.26 KB 0644
omp.h File 5.95 KB 0644
openacc.h File 4.55 KB 0644
pkuintrin.h File 1.7 KB 0644
pmmintrin.h File 4.27 KB 0644
popcntintrin.h File 1.71 KB 0644
prfchwintrin.h File 1.41 KB 0644
quadmath.h File 8.87 KB 0644
quadmath_weak.h File 3.07 KB 0644
rdseedintrin.h File 1.97 KB 0644
rtmintrin.h File 2.67 KB 0644
sgxintrin.h File 4.42 KB 0644
shaintrin.h File 3.12 KB 0644
smmintrin.h File 27.74 KB 0644
stdalign.h File 1.18 KB 0644
stdarg.h File 3.98 KB 0644
stdatomic.h File 9.1 KB 0644
stdbool.h File 1.49 KB 0644
stddef.h File 13.81 KB 0644
stdfix.h File 5.86 KB 0644
stdint-gcc.h File 9.24 KB 0644
stdint.h File 328 B 0644
stdnoreturn.h File 1.11 KB 0644
tbmintrin.h File 5.12 KB 0644
tmmintrin.h File 8.15 KB 0644
unwind.h File 10.47 KB 0644
varargs.h File 139 B 0644
wmmintrin.h File 4.48 KB 0644
x86intrin.h File 2.01 KB 0644
xmmintrin.h File 41.22 KB 0644
xopintrin.h File 27.9 KB 0644
xsavecintrin.h File 1.78 KB 0644
xsaveintrin.h File 2.14 KB 0644
xsaveoptintrin.h File 1.86 KB 0644
xsavesintrin.h File 2.11 KB 0644
xtestintrin.h File 1.65 KB 0644