CACAO
Macros | Functions
emit-common.hpp File Reference

Go to the source code of this file.

Macros

#define BRANCH_LABEL_1   1
 
#define BRANCH_LABEL_2   2
 
#define BRANCH_LABEL_3   3
 
#define BRANCH_LABEL_4   4
 
#define BRANCH_LABEL_5   5
 
#define BRANCH_LABEL_6   6
 
#define BRANCH_LABEL_7   7
 
#define BRANCH_LABEL_8   8
 
#define BRANCH_LABEL_9   9
 
#define BRANCH_LABEL_10   10
 
#define IS_IMM8(c)   (((s8) (c) >= -128) && ((s8) (c) <= 127))
 
#define IS_IMM32(c)   (((s8) (c) >= (-2147483647-1)) && ((s8) (c) <= 2147483647))
 
#define M_INTMOVE(a, b)   emit_imove(cd, a, b)
 
#define M_LNGMOVE(a, b)   emit_lmove(cd, a, b)
 
#define M_FLTMOVE(a, b)   emit_fmove(cd, a, b)
 
#define M_DBLMOVE(a, b)   emit_dmove(cd, a, b)
 

Functions

s4 emit_load (jitdata *jd, instruction *iptr, varinfo *src, s4 tempreg)
 
s4 emit_load_s1 (jitdata *jd, instruction *iptr, s4 tempreg)
 
s4 emit_load_s2 (jitdata *jd, instruction *iptr, s4 tempreg)
 
s4 emit_load_s3 (jitdata *jd, instruction *iptr, s4 tempreg)
 
void emit_store (jitdata *jd, instruction *iptr, varinfo *dst, s4 d)
 
void emit_store_dst (jitdata *jd, instruction *iptr, s4 d)
 
void emit_copy (jitdata *jd, instruction *iptr)
 
void emit_iconst (codegendata *cd, s4 d, s4 value)
 
void emit_lconst (codegendata *cd, s4 d, s8 value)
 
void emit_bccz (codegendata *cd, basicblock *target, s4 condition, s4 reg, u4 options)
 
void emit_bcc (codegendata *cd, basicblock *target, s4 condition, u4 options)
 
void emit_br (codegendata *cd, basicblock *target)
 
void emit_label_bccz (codegendata *cd, s4 label, s4 condition, s4 reg, u4 options)
 
void emit_label (codegendata *cd, s4 label)
 
void emit_label_bcc (codegendata *cd, s4 label, s4 condition, u4 options)
 
void emit_label_br (codegendata *cd, s4 label)
 
void emit_branch (codegendata *cd, s4 disp, s4 condition, s4 reg, u4 options)
 
void emit_arithmetic_check (codegendata *cd, instruction *iptr, s4 reg)
 
void emit_arrayindexoutofbounds_check (codegendata *cd, instruction *iptr, s4 s1, s4 s2)
 
void emit_arraystore_check (codegendata *cd, instruction *iptr)
 
void emit_classcast_check (codegendata *cd, instruction *iptr, s4 condition, s4 reg, s4 s1)
 
void emit_nullpointer_check (codegendata *cd, instruction *iptr, s4 reg)
 
void emit_exception_check (codegendata *cd, instruction *iptr)
 
void emit_trap_compiler (codegendata *cd)
 
void emit_trap_countdown (codegendata *cd, s4 *counter)
 
uint32_t emit_trap (codegendata *cd)
 
void emit_abstractmethoderror_trap (codegendata *cd)
 
void emit_patcher_traps (jitdata *jd)
 
void emit_recompute_pv (codegendata *cd)
 Emit code to recompute the procedure vector. More...
 
void emit_fastpath_monitor_enter (jitdata *jd, instruction *iptr, int d)
 Generates fast-path code for the below builtin. More...
 
void emit_fastpath_monitor_exit (jitdata *jd, instruction *iptr, int d)
 Generates fast-path code for the below builtin. More...
 
void emit_monitor_enter (jitdata *jd, int32_t syncslot_offset)
 Generates synchronization code to enter a monitor. More...
 
void emit_monitor_exit (jitdata *jd, int32_t syncslot_offset)
 Generates synchronization code to leave a monitor. More...
 
void emit_verbosecall_enter (jitdata *jd)
 Emit profiling code for method frequency counting. More...
 
void emit_verbosecall_exit (jitdata *jd)
 
static void emit_imove (codegendata *cd, int s, int d)
 Generates an integer-move from register s to d. More...
 
static void emit_lmove (codegendata *cd, int s, int d)
 Generates a long-move from register s to d. More...
 
static void emit_fmove (codegendata *cd, int s, int d)
 Generates a float-move from register s to d. More...
 
static void emit_dmove (codegendata *cd, int s, int d)
 Generates an double-move from register s to d. More...
 

Macro Definition Documentation

#define BRANCH_LABEL_1   1

Definition at line 47 of file emit-common.hpp.

#define BRANCH_LABEL_10   10

Definition at line 56 of file emit-common.hpp.

#define BRANCH_LABEL_2   2

Definition at line 48 of file emit-common.hpp.

#define BRANCH_LABEL_3   3

Definition at line 49 of file emit-common.hpp.

#define BRANCH_LABEL_4   4

Definition at line 50 of file emit-common.hpp.

#define BRANCH_LABEL_5   5

Definition at line 51 of file emit-common.hpp.

#define BRANCH_LABEL_6   6

Definition at line 52 of file emit-common.hpp.

#define BRANCH_LABEL_7   7

Definition at line 53 of file emit-common.hpp.

#define BRANCH_LABEL_8   8

Definition at line 54 of file emit-common.hpp.

#define BRANCH_LABEL_9   9

Definition at line 55 of file emit-common.hpp.

#define IS_IMM32 (   c)    (((s8) (c) >= (-2147483647-1)) && ((s8) (c) <= 2147483647))

Definition at line 66 of file emit-common.hpp.

#define IS_IMM8 (   c)    (((s8) (c) >= -128) && ((s8) (c) <= 127))

Definition at line 63 of file emit-common.hpp.

#define M_DBLMOVE (   a,
 
)    emit_dmove(cd, a, b)

Definition at line 301 of file emit-common.hpp.

#define M_FLTMOVE (   a,
 
)    emit_fmove(cd, a, b)

Definition at line 300 of file emit-common.hpp.

#define M_INTMOVE (   a,
 
)    emit_imove(cd, a, b)

Definition at line 298 of file emit-common.hpp.

#define M_LNGMOVE (   a,
 
)    emit_lmove(cd, a, b)

Definition at line 299 of file emit-common.hpp.

Function Documentation

void emit_abstractmethoderror_trap ( codegendata cd)

Definition at line 468 of file emit.cpp.

void emit_arithmetic_check ( codegendata cd,
instruction iptr,
s4  reg 
)

Definition at line 346 of file emit.cpp.

void emit_arrayindexoutofbounds_check ( codegendata cd,
instruction iptr,
s4  s1,
s4  s2 
)

Definition at line 362 of file emit.cpp.

void emit_arraystore_check ( codegendata cd,
instruction iptr 
)

Definition at line 380 of file emit.cpp.

void emit_bcc ( codegendata cd,
basicblock target,
s4  condition,
u4  options 
)

Definition at line 334 of file emit-common.cpp.

void emit_bccz ( codegendata cd,
basicblock target,
s4  condition,
s4  reg,
u4  options 
)

Definition at line 287 of file emit-common.cpp.

void emit_br ( codegendata cd,
basicblock target 
)

Definition at line 346 of file emit-common.cpp.

void emit_branch ( codegendata cd,
s4  disp,
s4  condition,
s4  reg,
u4  options 
)

Definition at line 263 of file emit.cpp.

void emit_classcast_check ( codegendata cd,
instruction iptr,
s4  condition,
s4  reg,
s4  s1 
)

Definition at line 396 of file emit.cpp.

void emit_copy ( jitdata jd,
instruction iptr 
)

Definition at line 153 of file emit.cpp.

static void emit_dmove ( codegendata cd,
int  s,
int  d 
)
inlinestatic

Generates an double-move from register s to d.

If s and d are the same registers, no code will be generated.

Definition at line 289 of file emit-common.hpp.

void emit_exception_check ( codegendata cd,
instruction iptr 
)

Definition at line 447 of file emit.cpp.

void emit_fastpath_monitor_enter ( jitdata jd,
instruction iptr,
int  d 
)

Generates fast-path code for the below builtin.

Function: LOCK_monitor_enter Signature: (Ljava/lang/Object;)V Slow-path: bool lock_monitor_enter(java_handle_t*);

Definition at line 496 of file emit.cpp.

void emit_fastpath_monitor_exit ( jitdata jd,
instruction iptr,
int  d 
)

Generates fast-path code for the below builtin.

Function: LOCK_monitor_exit Signature: (Ljava/lang/Object;)V Slow-path: bool lock_monitor_exit(java_handle_t*);

Definition at line 512 of file emit.cpp.

static void emit_fmove ( codegendata cd,
int  s,
int  d 
)
inlinestatic

Generates a float-move from register s to d.

If s and d are the same registers, no code will be generated.

Definition at line 278 of file emit-common.hpp.

void emit_iconst ( codegendata cd,
s4  d,
s4  value 
)

Definition at line 220 of file emit.cpp.

static void emit_imove ( codegendata cd,
int  s,
int  d 
)
inlinestatic

Generates an integer-move from register s to d.

If s and d are the same registers, no code will be generated.

Definition at line 241 of file emit-common.hpp.

void emit_label ( codegendata cd,
s4  label 
)

Definition at line 550 of file emit-common.cpp.

void emit_label_bcc ( codegendata cd,
s4  label,
s4  condition,
u4  options 
)

Definition at line 612 of file emit-common.cpp.

void emit_label_bccz ( codegendata cd,
s4  label,
s4  condition,
s4  reg,
u4  options 
)

Definition at line 494 of file emit-common.cpp.

void emit_label_br ( codegendata cd,
s4  label 
)

Definition at line 624 of file emit-common.cpp.

void emit_lconst ( codegendata cd,
s4  d,
s8  value 
)

Definition at line 233 of file emit.cpp.

static void emit_lmove ( codegendata cd,
int  s,
int  d 
)
inlinestatic

Generates a long-move from register s to d.

If s and d are the same registers, no code will be generated.

Definition at line 257 of file emit-common.hpp.

s4 emit_load ( jitdata jd,
instruction iptr,
varinfo src,
s4  tempreg 
)

Definition at line 66 of file emit.cpp.

s4 emit_load_s1 ( jitdata jd,
instruction iptr,
s4  tempreg 
)

Definition at line 63 of file emit-common.cpp.

s4 emit_load_s2 ( jitdata jd,
instruction iptr,
s4  tempreg 
)

Definition at line 82 of file emit-common.cpp.

s4 emit_load_s3 ( jitdata jd,
instruction iptr,
s4  tempreg 
)

Definition at line 101 of file emit-common.cpp.

void emit_monitor_enter ( jitdata jd,
int32_t  syncslot_offset 
)

Generates synchronization code to enter a monitor.

Definition at line 507 of file emit.cpp.

void emit_monitor_exit ( jitdata jd,
int32_t  syncslot_offset 
)

Generates synchronization code to leave a monitor.

Definition at line 565 of file emit.cpp.

void emit_nullpointer_check ( codegendata cd,
instruction iptr,
s4  reg 
)

Definition at line 431 of file emit.cpp.

void emit_patcher_traps ( jitdata jd)

Definition at line 267 of file emit-common.cpp.

void emit_recompute_pv ( codegendata cd)

Emit code to recompute the procedure vector.

Definition at line 495 of file emit.cpp.

void emit_store ( jitdata jd,
instruction iptr,
varinfo dst,
s4  d 
)

Definition at line 113 of file emit.cpp.

void emit_store_dst ( jitdata jd,
instruction iptr,
s4  d 
)

Definition at line 255 of file emit-common.cpp.

uint32_t emit_trap ( codegendata cd)

Definition at line 480 of file emit.cpp.

void emit_trap_compiler ( codegendata cd)

Definition at line 463 of file emit.cpp.

void emit_trap_countdown ( codegendata cd,
s4 counter 
)

Definition at line 565 of file emit.cpp.

void emit_verbosecall_enter ( jitdata jd)

Emit profiling code for method frequency counting.

Emit profiling code for basicblock frequency counting. Emit profiling code to start CPU cycle counting. Emit profiling code to stop CPU cycle counting.

Definition at line 625 of file emit.cpp.

void emit_verbosecall_exit ( jitdata jd)

Definition at line 766 of file emit.cpp.