osprey/ipa/cord/ipa_cord.cxx File Reference

#include <elf.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/mman.h>
#include <fcntl.h>
#include <stdio.h>
#include <string.h>
#include <vector>
#include <algorithm>
#include <stack>
#include <map>
#include <tree.h>
#include "obj_info.h"
#include "lib_phase_dir.h"

Include dependency graph for ipa_cord.cxx:

Go to the source code of this file.

Data Types

type  ltstr
type  PROC
type  less< PROC >
type  less_src_order< PROC >
type  CALL
type  less< CALL >
type  compress_path

Defines

#define PAGESIZE   65536

Typedefs

typedef pair< PROC *, PROC * > map_key
typedef map< map_key, int > CG
typedef map< const char
*, PROC *, ltstr
PROCTAB

Functions/Subroutines

bool file_exists (const char *path)
void read_call_graph (const char *cgraph, PROCTAB &procedures, CG &cg)
template<class Shdr>
void process_object_file (File_Info &fi, Shdr *tag, PROCTAB &procedures)
void read_obj_list (const char *objlist, PROCTAB &procedures)
bool layout (PROC *p1, PROC *p2, int freq, int retry_count)
void emit_lkcord (const char *outfile, vector< PROC * > &proc_layout, vector< PROC * > &src_order_layout)
 main (int argc, char *argv[])

Variables

int debug = 0
const int LEN = 1000
const int MIN_FREQ = 15
int src_order = 0


Define Documentation

#define PAGESIZE   65536

Definition at line 60 of file ipa_cord.cxx.

Referenced by layout().


Typedef Documentation

typedef map< map_key, int> CG

Definition at line 135 of file ipa_cord.cxx.

typedef pair<PROC *, PROC *> map_key

Definition at line 134 of file ipa_cord.cxx.

typedef map<const char *, PROC *, ltstr> PROCTAB

Definition at line 136 of file ipa_cord.cxx.


Function Documentation

void emit_lkcord ( const char *  outfile,
vector< PROC * > &  proc_layout,
vector< PROC * > &  src_order_layout 
)

bool file_exists ( const char *  path  ) 

Definition at line 139 of file ipa_cord.cxx.

bool layout ( PROC p1,
PROC p2,
int  freq,
int  retry_count 
)

main ( int argc  ,
char *  argv[] 
)

template<class Shdr>
void process_object_file ( File_Info fi,
Shdr *  tag,
PROCTAB procedures 
) [inline]

Definition at line 210 of file ipa_cord.cxx.

References File_Info::begin(), debug, File_Info::end(), p, printf(), size, src_order, strcmp(), and strncmp().

Referenced by read_obj_list().

void read_call_graph ( const char *  cgraph,
PROCTAB procedures,
CG cg 
)

Definition at line 168 of file ipa_cord.cxx.

References atoi(), callee, caller, debug, exit(), fclose(), fgets(), fopen, in1, LEN, PROC::name, NULL, p1, p2, perror(), printf(), strdup, and strtok().

Referenced by main().

void read_obj_list ( const char *  objlist,
PROCTAB procedures 
)


Variable Documentation

int debug = 0

Definition at line 61 of file ipa_cord.cxx.

const int LEN = 1000

Definition at line 62 of file ipa_cord.cxx.

const int MIN_FREQ = 15

Definition at line 63 of file ipa_cord.cxx.

Referenced by main().

int src_order = 0

Definition at line 205 of file ipa_cord.cxx.

Referenced by process_object_file().


Generated on Wed Apr 8 15:09:41 2009 for Open64 by  doxygen 1.5.6