HPCToolkit
rtmap.c File Reference
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <limits.h>
#include <libgen.h>
#include <sys/types.h>
#include "rtmap.h"
Include dependency graph for rtmap.c:

Go to the source code of this file.

Macros

#define TESTING   0
 
#define bhl   ((int)(sizeof(long)*2+2))
 
#define MAXLINELEN   (PATH_MAX + 80)
 

Functions

static void finalizelines (void)
 
static int iscodeline (char *line)
 
static char * get_line_slot (void)
 
static char * get_name (char *line)
 
static char * get_beg_addr (char *line)
 
static char * get_end_addr (char *line)
 
static unsigned long hex2ul (char *s)
 
static uint64_t hex2u64 (char *s)
 
static void dumprtloadmap (void)
 
static void dumplines (void)
 
static void reset_slots ()
 
rtloadmap_thpcrun_get_rtloadmap (int dbglvl)
 
const char * hpcrun_get_cmd (int dbglvl)
 

Variables

static rtloadmap_t rtloadmap
 
static char ** mappings = 0
 
static int slots_avail = 0
 
static int slots_in_use = 0
 

Macro Definition Documentation

◆ bhl

#define bhl   ((int)(sizeof(long)*2+2))

Definition at line 102 of file rtmap.c.

◆ MAXLINELEN

#define MAXLINELEN   (PATH_MAX + 80)

Definition at line 104 of file rtmap.c.

◆ TESTING

#define TESTING   0

Definition at line 79 of file rtmap.c.

Function Documentation

◆ dumplines()

static void dumplines ( void  )
static

Definition at line 332 of file rtmap.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ dumprtloadmap()

static void dumprtloadmap ( void  )
static

Definition at line 316 of file rtmap.c.

Here is the caller graph for this function:

◆ finalizelines()

static void finalizelines ( void  )
static

Definition at line 244 of file rtmap.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_beg_addr()

static char * get_beg_addr ( char *  line)
static

Definition at line 284 of file rtmap.c.

Here is the caller graph for this function:

◆ get_end_addr()

static char * get_end_addr ( char *  line)
static

Definition at line 290 of file rtmap.c.

Here is the caller graph for this function:

◆ get_line_slot()

static char * get_line_slot ( void  )
static

Definition at line 210 of file rtmap.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_name()

static char * get_name ( char *  line)
static

Definition at line 275 of file rtmap.c.

Here is the caller graph for this function:

◆ hex2u64()

static uint64_t hex2u64 ( char *  s)
static

Definition at line 305 of file rtmap.c.

Here is the caller graph for this function:

◆ hex2ul()

static unsigned long hex2ul ( char *  s)
static

Definition at line 297 of file rtmap.c.

Here is the caller graph for this function:

◆ hpcrun_get_cmd()

const char* hpcrun_get_cmd ( int  dbglvl)

Definition at line 160 of file rtmap.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hpcrun_get_rtloadmap()

rtloadmap_t* hpcrun_get_rtloadmap ( int  dbglvl)

Definition at line 118 of file rtmap.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iscodeline()

static int iscodeline ( char *  line)
static

Definition at line 232 of file rtmap.c.

Here is the caller graph for this function:

◆ reset_slots()

static void reset_slots ( )
static

Definition at line 198 of file rtmap.c.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ mappings

char** mappings = 0
static

Definition at line 194 of file rtmap.c.

◆ rtloadmap

rtloadmap_t rtloadmap
static

Definition at line 81 of file rtmap.c.

◆ slots_avail

int slots_avail = 0
static

Definition at line 195 of file rtmap.c.

◆ slots_in_use

int slots_in_use = 0
static

Definition at line 196 of file rtmap.c.