CACAO
Data Structures | Macros | Typedefs | Functions | Variables
show.cpp File Reference

Go to the source code of this file.

Data Structures

struct  show_filter
 

Macros

#define SHOW_TARGET(target)
 
#define SHOW_INT_CONST(val)
 
#define SHOW_LNG_CONST(val)
 
#define SHOW_ADR_CONST(val)
 
#define SHOW_FLT_CONST(val)
 
#define SHOW_DBL_CONST(val)
 
#define SHOW_INDEX(index)
 
#define SHOW_STRING(val)
 
#define SHOW_CLASSREF_OR_CLASSINFO(c)
 
#define SHOW_FIELD(fmiref)
 
#define SHOW_VARIABLE(v)   show_variable(jd, (v), stage)
 
#define SHOW_S1(iptr)
 
#define SHOW_S2(iptr)
 
#define SHOW_S3(iptr)
 
#define SHOW_DST(iptr)
 
#define SHOW_S1_LOCAL(iptr)
 
#define SHOW_DST_LOCAL(iptr)
 
#define SHOW_FILTERS_SIZE   3
 
#define STATE_IS_INITIAL()   ((FILTERVERBOSECALLCTR[0] == 0) && (FILTERVERBOSECALLCTR[1] == 0))
 
#define STATE_IS_INCLUDE()   ((FILTERVERBOSECALLCTR[0] > 0) && (FILTERVERBOSECALLCTR[1] == 0))
 
#define STATE_IS_EXCLUDE()   (FILTERVERBOSECALLCTR[1] > 0)
 
#define EVENT_INCLUDE()   (m->filtermatches & SHOW_FILTER_FLAG_VERBOSECALL_INCLUDE)
 
#define EVENT_EXCLUDE()   (m->filtermatches & SHOW_FILTER_FLAG_VERBOSECALL_EXCLUDE)
 
#define TRANSITION_NEXT_INCLUDE()   ++FILTERVERBOSECALLCTR[0]
 
#define TRANSITION_PREV_INCLUDE()   --FILTERVERBOSECALLCTR[0]
 
#define TRANSITION_NEXT_EXCLUDE()   ++FILTERVERBOSECALLCTR[1]
 
#define TRANSITION_PREV_EXCLUDE()   --FILTERVERBOSECALLCTR[1]
 

Typedefs

typedef struct show_filter show_filter_t
 

Functions

static void show_variable_intern (jitdata *jd, s4 index, int stage)
 
bool show_init (void)
 
void show_method (jitdata *jd, int stage)
 
void show_basicblock (jitdata *jd, basicblock *bptr, int stage)
 
void show_allocation (s4 type, s4 flags, s4 regoff)
 
void show_variable (jitdata *jd, s4 index, int stage)
 
static void show_variable_array_intern (jitdata *jd, s4 *vars, int n, int stage, bool javalocals)
 
void show_variable_array (jitdata *jd, s4 *vars, int n, int stage)
 
void show_javalocals_array (jitdata *jd, s4 *vars, int n, int stage)
 
void show_icmd (jitdata *jd, instruction *iptr, bool deadcode, int stage)
 
static void show_filter_init (show_filter_t *cf, const char *str, u1 flag, u1 default_flag, const char *description)
 
void show_filters_init (void)
 
void show_filters_apply (methodinfo *m)
 
int show_filters_test_verbosecall_enter (methodinfo *m)
 
int show_filters_test_verbosecall_exit (methodinfo *m)
 

Variables

static Mutex mutex
 
const char * show_jit_type_names []
 
const char show_jit_type_letters []
 
static struct show_filter show_filters [SHOW_FILTERS_SIZE]
 

Macro Definition Documentation

#define EVENT_EXCLUDE ( )    (m->filtermatches & SHOW_FILTER_FLAG_VERBOSECALL_EXCLUDE)

Definition at line 1558 of file show.cpp.

#define EVENT_INCLUDE ( )    (m->filtermatches & SHOW_FILTER_FLAG_VERBOSECALL_INCLUDE)

Definition at line 1557 of file show.cpp.

#define SHOW_ADR_CONST (   val)
Value:
if (stage >= SHOW_PARSE) \
printf("0x%" PRINTF_INTPTR_NUM_HEXDIGITS PRIxPTR " ", (ptrint) (val)); \
printf("aconst ");
#define SHOW_PARSE
Definition: show.hpp:40
uintptr_t ptrint
Definition: types.hpp:54
#define PRINTF_INTPTR_NUM_HEXDIGITS
Definition: global.hpp:80
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 655 of file show.cpp.

#define SHOW_CLASSREF_OR_CLASSINFO (   c)
Value:
if (stage >= SHOW_PARSE) { \
if (c.is_classref()) \
class_print(c.cls); \
putchar(' '); \
} \
else { \
printf("class "); \
}
void class_print(classinfo *c)
Definition: class.cpp:2231
#define SHOW_PARSE
Definition: show.hpp:40
void class_classref_print(constant_classref *cr)
Definition: class.cpp:2251
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 699 of file show.cpp.

#define SHOW_DBL_CONST (   val)
Value:
if (stage >= SHOW_PARSE) { \
imm_union v; \
v.d = (val); \
printf("%g (0x%016" PRIx64 ") ", (val), v.l); \
} \
printf("dconst ");
#define SHOW_PARSE
Definition: show.hpp:40
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 671 of file show.cpp.

#define SHOW_DST (   iptr)
Value:
if (stage >= SHOW_STACK) { \
printf("=> "); \
SHOW_VARIABLE(iptr->dst.varindex); \
}
#define SHOW_STACK
Definition: show.hpp:41
#define SHOW_VARIABLE(v)
Definition: show.cpp:720
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 738 of file show.cpp.

#define SHOW_DST_LOCAL (   iptr)
Value:
if (stage >= SHOW_STACK) { \
printf("=> L%d ", iptr->dst.varindex); \
} \
else { \
printf("=> JavaL%d ", iptr->dst.varindex); \
}
#define SHOW_STACK
Definition: show.hpp:41
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 752 of file show.cpp.

#define SHOW_FIELD (   fmiref)
Value:
if (stage >= SHOW_PARSE) { \
putchar(' '); \
} \
else { \
printf("field "); \
}
#define SHOW_PARSE
Definition: show.hpp:40
void field_fieldref_print(constant_FMIref *fr)
Definition: field.cpp:522
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 711 of file show.cpp.

#define SHOW_FILTERS_SIZE   3

Definition at line 1443 of file show.cpp.

#define SHOW_FLT_CONST (   val)
Value:
if (stage >= SHOW_PARSE) { \
imm_union v; \
v.f = (val); \
printf("%g (0x%08x) ", (val), v.i); \
} \
else { \
printf("fconst "); \
}
#define SHOW_PARSE
Definition: show.hpp:40
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 661 of file show.cpp.

#define SHOW_INDEX (   index)
Value:
if (stage >= SHOW_PARSE) { \
printf("%d ", index); \
} \
else { \
printf("index"); \
}
std::size_t index
#define SHOW_PARSE
Definition: show.hpp:40
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 680 of file show.cpp.

#define SHOW_INT_CONST (   val)
Value:
if (stage >= SHOW_PARSE) { \
printf("%d (0x%08x) ", (int32_t) (val), (int32_t) (val)); \
} \
else { \
printf("iconst "); \
}
#define SHOW_PARSE
Definition: show.hpp:40
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 641 of file show.cpp.

#define SHOW_LNG_CONST (   val)
Value:
if (stage >= SHOW_PARSE) \
printf("%" PRId64 " (0x%016" PRIx64 ") ", (val), (val)); \
printf("lconst ");
#define SHOW_PARSE
Definition: show.hpp:40
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 649 of file show.cpp.

#define SHOW_S1 (   iptr)
Value:
if (stage >= SHOW_STACK) { \
SHOW_VARIABLE(iptr->s1.varindex); \
}
#define SHOW_STACK
Definition: show.hpp:41
#define SHOW_VARIABLE(v)
Definition: show.cpp:720

Definition at line 723 of file show.cpp.

#define SHOW_S1_LOCAL (   iptr)
Value:
if (stage >= SHOW_STACK) { \
printf("L%d ", iptr->s1.varindex); \
} \
else { \
printf("JavaL%d ", iptr->s1.varindex); \
}
#define SHOW_STACK
Definition: show.hpp:41
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 744 of file show.cpp.

#define SHOW_S2 (   iptr)
Value:
if (stage >= SHOW_STACK) { \
SHOW_VARIABLE(iptr->sx.s23.s2.varindex); \
}
#define SHOW_STACK
Definition: show.hpp:41
#define SHOW_VARIABLE(v)
Definition: show.cpp:720

Definition at line 728 of file show.cpp.

#define SHOW_S3 (   iptr)
Value:
if (stage >= SHOW_STACK) { \
SHOW_VARIABLE(iptr->sx.s23.s3.varindex); \
}
#define SHOW_STACK
Definition: show.hpp:41
#define SHOW_VARIABLE(v)
Definition: show.cpp:720

Definition at line 733 of file show.cpp.

#define SHOW_STRING (   val)
Value:
if (stage >= SHOW_PARSE) { \
putchar('"'); \
JavaString((java_handle_t*) (val)).to_utf8()); \
printf("\" "); \
} \
else { \
printf("string "); \
}
#define SHOW_PARSE
Definition: show.hpp:40
void utf_display_printable_ascii(Utf8String u)
Definition: utf8.cpp:532
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 688 of file show.cpp.

#define SHOW_TARGET (   target)
Value:
if (stage >= SHOW_PARSE) { \
printf("--> L%03d ", (target).block->nr); \
} \
else { \
printf("--> insindex %d ", (target).insindex); \
}
#define SHOW_PARSE
Definition: show.hpp:40
BeginInst *& block
BeginInst * target
#define printf(...)
Definition: ssa2.cpp:40

Definition at line 633 of file show.cpp.

#define SHOW_VARIABLE (   v)    show_variable(jd, (v), stage)

Definition at line 720 of file show.cpp.

#define STATE_IS_EXCLUDE ( )    (FILTERVERBOSECALLCTR[1] > 0)

Definition at line 1556 of file show.cpp.

#define STATE_IS_INCLUDE ( )    ((FILTERVERBOSECALLCTR[0] > 0) && (FILTERVERBOSECALLCTR[1] == 0))

Definition at line 1555 of file show.cpp.

#define STATE_IS_INITIAL ( )    ((FILTERVERBOSECALLCTR[0] == 0) && (FILTERVERBOSECALLCTR[1] == 0))

Definition at line 1554 of file show.cpp.

#define TRANSITION_NEXT_EXCLUDE ( )    ++FILTERVERBOSECALLCTR[1]

Definition at line 1561 of file show.cpp.

#define TRANSITION_NEXT_INCLUDE ( )    ++FILTERVERBOSECALLCTR[0]

Definition at line 1559 of file show.cpp.

#define TRANSITION_PREV_EXCLUDE ( )    --FILTERVERBOSECALLCTR[1]

Definition at line 1562 of file show.cpp.

#define TRANSITION_PREV_INCLUDE ( )    --FILTERVERBOSECALLCTR[0]

Definition at line 1560 of file show.cpp.

Typedef Documentation

typedef struct show_filter show_filter_t

Definition at line 1441 of file show.cpp.

Function Documentation

void show_allocation ( s4  type,
s4  flags,
s4  regoff 
)

Definition at line 760 of file show.cpp.

void show_basicblock ( jitdata jd,
basicblock bptr,
int  stage 
)

Definition at line 449 of file show.cpp.

static void show_filter_init ( show_filter_t cf,
const char *  str,
u1  flag,
u1  default_flag,
const char *  description 
)
static

Definition at line 1448 of file show.cpp.

void show_filters_apply ( methodinfo m)

Definition at line 1525 of file show.cpp.

void show_filters_init ( void  )

Definition at line 1469 of file show.cpp.

int show_filters_test_verbosecall_enter ( methodinfo m)

Definition at line 1572 of file show.cpp.

int show_filters_test_verbosecall_exit ( methodinfo m)

Definition at line 1597 of file show.cpp.

void show_icmd ( jitdata jd,
instruction iptr,
bool  deadcode,
int  stage 
)

Definition at line 917 of file show.cpp.

bool show_init ( void  )

Definition at line 91 of file show.cpp.

void show_javalocals_array ( jitdata jd,
s4 vars,
int  n,
int  stage 
)

Definition at line 912 of file show.cpp.

void show_method ( jitdata jd,
int  stage 
)

Definition at line 140 of file show.cpp.

void show_variable ( jitdata jd,
s4  index,
int  stage 
)

Definition at line 808 of file show.cpp.

void show_variable_array ( jitdata jd,
s4 vars,
int  n,
int  stage 
)

Definition at line 907 of file show.cpp.

static void show_variable_array_intern ( jitdata jd,
s4 vars,
int  n,
int  stage,
bool  javalocals 
)
static

Definition at line 875 of file show.cpp.

static void show_variable_intern ( jitdata jd,
s4  index,
int  stage 
)
static

Definition at line 814 of file show.cpp.

Variable Documentation

Mutex mutex
static

Definition at line 73 of file show.cpp.

struct show_filter show_filters[SHOW_FILTERS_SIZE]
static

Definition at line 1446 of file show.cpp.

const char show_jit_type_letters[]
Initial value:
= {
'I',
'L',
'F',
'D',
'A',
'5',
'6',
'7',
'R'
}

Definition at line 117 of file show.cpp.

const char* show_jit_type_names[]
Initial value:
= {
"INT",
"LNG",
"FLT",
"DBL",
"ADR",
"??5",
"??6",
"??7",
"RET"
}

Definition at line 105 of file show.cpp.