1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
|
Code Structure Decoding
***********************
Basic Flow Analysis
===================
* input: raw instruction list
* output: instruction block list
* a instruction block is defined by a start instruction and a finishing instruction +
a list of successor blocks
* split bytecode into multiple instruction blocks:
* the first instruction of a method starts a block
* the target of a branch instruction start a block
* a branch instruction finishes a block
* the instruction after a branch instruction starts a block
* the last instruction of a method finishes a block
Action/Low-level statement Delimitation
=============================
* input: control flow graph
* output: action flow graph
1) ASSIGN EXPRESSION
2) INVOKE EXPRESSION+
3) BRANCH
4) COND_BRANCH EXPRESSION
5) RETURN
1) stloc, starg, stfld, stsfld
3) call, callvirt
3) br.s, br
4) ble, beq, ...
5) ret
Deoptimization
==============
* replace ret instructions in leaves by a connection to a single
ret block from both leaves
Expression Aggregation
======================
Simple Copy Propagation
=======================
|