ucfunc.cc File Reference

#include "ucdata.h"
#include "ucfunc.h"
#include <set>
#include <strstream>
#include <algorithm>
#include <iomanip>
#include "files/utils.h"
#include "ops.h"

Include dependency graph for ucfunc.cc:

Go to the source code of this file.

Defines

#define DEBUG_READ_PAIR(X, Y)

Functions

string demunge_ocstring (UCFunc &ucf, const FuncMap &funcmap, const string &asmstr, const vector< unsigned int > &params, const map< unsigned int, string > &intrinsics, const UCc &op, bool ucs_output)
ostream & tab_indent (const unsigned int indent, ostream &o)
void gc_gotoset (vector< GotoSet > &gotoset)
int calc16reloffset (const UCc &op, unsigned int param)
int calc32reloffset (const UCc &op, unsigned int param)
void ucc_parse_parambytes (UCc &ucop, const UCOpcodeData &otd)
unsigned int charnum2uint (const char c)
void readbin_U7UCFunc (ifstream &f, UCFunc &ucf, const UCOptions &options)
void readbin_U8UCFunc (ifstream &f, UCFunc &ucf)

Variables

const string VARNAME = "var"
const string VARPREFIX = "var"


Define Documentation

#define DEBUG_READ_PAIR ( X,
 ) 

Definition at line 51 of file ucfunc.cc.

Referenced by readbin_U7UCFunc().


Function Documentation

int calc16reloffset ( const UCc op,
unsigned int  param 
) [inline]

Definition at line 500 of file ucfunc.cc.

References UCc::_offset, and UCc::_params.

Referenced by ucc_parse_parambytes().

int calc32reloffset ( const UCc op,
unsigned int  param 
) [inline]

Definition at line 515 of file ucfunc.cc.

References UCc::_offset, and UCc::_params.

Referenced by ucc_parse_parambytes().

unsigned int charnum2uint ( const char  c  )  [inline]

Definition at line 683 of file ucfunc.cc.

Referenced by demunge_ocstring().

string demunge_ocstring ( UCFunc ucf,
const FuncMap funcmap,
const string &  asmstr,
const vector< unsigned int > &  params,
const map< unsigned int, string > &  intrinsics,
const UCc op,
bool  ucs_output 
)

Definition at line 702 of file ucfunc.cc.

References UCFunc::_data, UCFunc::_externs, UCFunc::_funcid, UCc::_id, UCc::_params_parsed, UCc::_popped, charnum2uint(), UCFunc::funcname, len, opcode_table_data, s, and width.

Here is the call graph for this function:

void gc_gotoset ( vector< GotoSet > &  gotoset  )  [inline]

Definition at line 256 of file ucfunc.cc.

void readbin_U7UCFunc ( ifstream &  f,
UCFunc ucf,
const UCOptions options 
)

Definition at line 917 of file ucfunc.cc.

References UCFunc::_bodyoffset, UCFunc::_codeoffset, UCFunc::_data, UCFunc::_datasize, UCFunc::_externs, UCFunc::_funcid, UCFunc::_funcsize, UCFunc::_num_args, UCFunc::_num_externs, UCFunc::_num_locals, UCFunc::_offset, UCFunc::_opcodes, DEBUG_READ_PAIR, UCFunc::debugging_info, UCFunc::debugging_offset, UCFunc::ext32, UCOpcodeData::flag_return, UCFunc::funcname, UCOptions::game_bg(), UCOptions::game_si(), getline(), UCOpcodeData::num_bytes, UCOpcodeData::opcode, opcode_table_data, Read1(), Read2(), Read4(), UCFunc::return_var, SIZEOF_USHORT, ucc_parse_parambytes(), and UCOptions::very_verbose.

Here is the call graph for this function:

void readbin_U8UCFunc ( ifstream &  f,
UCFunc ucf 
)

Definition at line 1075 of file ucfunc.cc.

ostream& tab_indent ( const unsigned int  indent,
ostream &  o 
) [inline]

Definition at line 79 of file ucfunc.cc.

void ucc_parse_parambytes ( UCc ucop,
const UCOpcodeData otd 
)

Definition at line 529 of file ucfunc.cc.

References UCc::_jump_offsets, UCc::_params, UCc::_params_parsed, calc16reloffset(), calc32reloffset(), UCOpcodeData::param_sizes, and s.

Referenced by readbin_U7UCFunc().

Here is the call graph for this function:


Variable Documentation

const string VARNAME = "var"

Definition at line 71 of file ucfunc.cc.

const string VARPREFIX = "var"

Definition at line 72 of file ucfunc.cc.


Generated on Mon Jul 9 14:46:06 2007 for ExultEngine by  doxygen 1.5.1