linuxKludges.C File Reference

#include "common/h/headers.h"
#include "common/h/parseauxv.h"
#include "common/h/linuxKludges.h"
#include "common/h/Types.h"
#include <elf.h>
#include <vector>
#include <sys/types.h>
#include <unistd.h>
#include <dirent.h>
#include <string.h>

Go to the source code of this file.

Defines

#define AT_SYSINFO_EHDR   33
#define READ_BLOCK_SIZE   (1024 * 5)
#define LINE_LEN   1024

Typedefs

typedef int(* intKludge )()

Functions

int P_getopt (int argc, char *argv[], const char *optstring)
int P_copy (const char *from, const char *to)
unsigned long long PDYN_div1000 (unsigned long long in)
unsigned long long PDYN_divMillion (unsigned long long in)
unsigned long long PDYN_mulMillion (unsigned long long in)
char * P_cplus_demangle (const char *symbol, bool nativeCompiler, bool includeTypes)
bool PtraceBulkRead (Address inTraced, unsigned size, const void *inSelf, int pid)
bool PtraceBulkWrite (Dyninst::Address inTraced, unsigned nbytes, const void *inSelf, int pid)
static bool couldBeVsyscallPage (map_entries *entry, bool strict, Address)
map_entriesgetVMMaps (int pid, unsigned &maps_size)
bool findProcLWPs (pid_t pid, std::vector< pid_t > &lwps)

Define Documentation

#define AT_SYSINFO_EHDR   33

Definition at line 382 of file linuxKludges.C.

#define LINE_LEN   1024

Definition at line 923 of file linuxKludges.C.

#define READ_BLOCK_SIZE   (1024 * 5)

Definition at line 861 of file linuxKludges.C.

Referenced by AuxvParser::readAuxvFromProc().


Typedef Documentation

typedef int(* intKludge)()

Definition at line 44 of file linuxKludges.C.


Function Documentation

static bool couldBeVsyscallPage ( map_entries entry,
bool  strict,
Address   
) [static]
bool findProcLWPs ( pid_t  pid,
std::vector< pid_t > &  lwps 
)

Linux 2.6:

Linux 2.4:

PIDs that are created by pthreads have a '.' prepending their name in /proc. We'll check all of those for the ones that have this lwp as a parent pid.

Definition at line 1031 of file linuxKludges.C.

References P_fopen().

map_entries* getVMMaps ( int  pid,
unsigned &  maps_size 
)
int P_copy ( const char *  from,
const char *  to 
)

Definition at line 55 of file linuxKludges.C.

References P_open().

char* P_cplus_demangle ( const char *  symbol,
bool  nativeCompiler,
bool  includeTypes 
) [inline]

Definition at line 182 of file linuxKludges.C.

References cplus_demangle(), dedemangle(), DMGL_ANSI, DMGL_ARM, and DMGL_PARAMS.

int P_getopt ( int  argc,
char *  argv[],
const char *  optstring 
) [inline]

Definition at line 46 of file linuxKludges.C.

unsigned long long PDYN_div1000 ( unsigned long long  in  ) 

Definition at line 84 of file linuxKludges.C.

unsigned long long PDYN_divMillion ( unsigned long long  in  ) 

Definition at line 118 of file linuxKludges.C.

unsigned long long PDYN_mulMillion ( unsigned long long  in  ) 

Definition at line 150 of file linuxKludges.C.

bool PtraceBulkRead ( Address  inTraced,
unsigned  size,
const void *  inSelf,
int  pid 
)

Definition at line 224 of file linuxKludges.C.

References P_ptrace().

bool PtraceBulkWrite ( Dyninst::Address  inTraced,
unsigned  nbytes,
const void *  inSelf,
int  pid 
)

Definition at line 290 of file linuxKludges.C.

References P_ptrace().

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 12 Jul 2013 for SymtabAPI by  doxygen 1.6.1