Sponsored Content
Full Discussion: MIPS backtrace
Top Forums Programming MIPS backtrace Post 302223120 by shamrock on Friday 8th of August 2008 11:32:08 AM
Old 08-08-2008
What OS are you on?
 

6 More Discussions You Might Find Interesting

1. Programming

BackTrace

i need to know how one can get the backtrace of a program in c++ as you find in gdb or dbx on doing a ctrl c (or any signal to the os) do help (6 Replies)
Discussion started by: wojtyla
6 Replies

2. Programming

printing a stack trace with backtrace

I am trying to print a stack trace programatically using backtrace and backtrace_symbols. The problem is that the stack being printed in a mangled format. Is there a way to get the output in more of a human readable form? I am using Red Hat and the program is written in c++. (2 Replies)
Discussion started by: dmirza
2 Replies

3. Linux

how to backtrace a shared library file (.so)

I have a shared library file (.so) and I need to know some information 1. By which GCC version was this .so built? 2. Was this .so built in 32 bits mode or 64 bits mode Any command / tools to backtrace such kind of information? Thanks in advance! (2 Replies)
Discussion started by: princelinux
2 Replies

4. UNIX for Dummies Questions & Answers

Is there a Cron instal pkg for MIPS-SEL processors?

Does anyone know if there is a pkg for installing cron on a mips processor machine with embedded linux? (0 Replies)
Discussion started by: Trogman
0 Replies

5. UNIX and Linux Applications

Cross Compiling Issue of udev-151 for MIPS Little Endain Architecture

Hi All, I am trying to cross compile udev-151 for MIPS little endian architecture. I am configuring like this: ./configure --prefix=$PWD/sree --host=mips-linux-gnu configure: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then... (3 Replies)
Discussion started by: bsreeram
3 Replies

6. Programming

Gdb backtrace

Hi, all I try to understand the output from gdb Program received signal SIGABRT, Aborted. *** glibc detected *** /home/sys_cbo/dev/zif/bin/Debug/zifd: free(): invalid pointer: 0x00007fffac04d3d0 *** how should i read this? (gdb) backtrace #0 0x0000003015e32925 in raise () from... (1 Reply)
Discussion started by: huvcbo
1 Replies
BACKTRACE(3)						   BSD Library Functions Manual 					      BACKTRACE(3)

NAME
backtrace -- fill in the backtrace of the currently executing thread LIBRARY
library ``libexecinfo'' SYNOPSIS
#include <execinfo.h> size_t backtrace(void **addrlist, size_t len); char ** backtrace_symbols(void * const *addrlist, size_t len); int backtrace_symbols_fd(void * const *addrlist, size_t len, int fd); char ** backtrace_symbols_fmt(void * const *addrlist, size_t len, const char *fmt); int backtrace_symbols_fmt_fd(void * const *addrlist, size_t len, const char *fmt, int fd); DESCRIPTION
The backtrace() function places into the array pointed by addrlist the array of the values of the program counter for each frame called up to len frames. The number of frames found (which can be fewer than len) is returned. The backtrace_symbols_fmt() function takes an array of previously filled addresses from backtrace() in addrlist of len elements, and uses fmt to format them. The formatting characters available are: a The numeric address of each element as would be printed using %p. n The name of the nearest function symbol (smaller than the address element) as determined by dladdr(3) if the symbol was dynamic, or looked up in the executable if static and the /proc filesystem is available to determine the executable path. d The difference of the symbol address and the address element printed using 0x%tx. D The difference of the symbol addresss and the address element printed using +0x%tx if non-zero, or nothing if zero. f The filename of the symbol as determined by dladdr(3). The array of formatted strings is returned as a contiguous memory address which can be freed by a single free(3). The backtrace_symbols() function is equivalent of calling backtrace_symbols_fmt() with a format argument of %a <%n%D> at %f The backtrace_symbols_fd() and backtrace_symbols_fmt_fd() are similar to the non _fd named functions, only instead of returning an array or strings, they print a new-line separated array of strings in fd, and return 0 on success and -1 on failure. RETURN VALUES
The backtrace() function returns the number of elements that were filled in the backtrace. The backtrace_symbols() and backtrace_symbols_fmt() return a string array on success, and NULL on failure, setting errno. Diagnostic output may also be produced by the ELF symbol lookup functions. SEE ALSO
dladdr(3), elf(3) HISTORY
The backtrace() library of functions first appeared in NetBSD 7.0 and FreeBSD 10.0. BUGS
1. Errors should not be printed but communicated to the caller differently. 2. Because these functions use elf(3) this is a separate library instead of being part of libc/libutil so that no library dependencies are introduced. 3. The Linux versions of the functions (there are no _fmt variants) use int instead of size_t arguments. BSD
August 23, 2013 BSD
All times are GMT -4. The time now is 07:46 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy