Added basic loop unrolling. Blocks that end in a JMP, LOOP or conditional branch to a previous instruction in the block will be unrolled up to 10 times.
This commit is contained in:
parent
b35cf7de09
commit
7e099c277e
9 changed files with 594 additions and 148 deletions
|
|
@ -336,6 +336,7 @@ typedef struct uop_t
|
|||
int jump_dest_uop;
|
||||
int jump_list_next;
|
||||
void *jump_dest;
|
||||
uint32_t pc;
|
||||
} uop_t;
|
||||
|
||||
#define UOP_NR_MAX 4096
|
||||
|
|
@ -361,6 +362,9 @@ static inline uop_t *uop_alloc(ir_data_t *ir, uint32_t uop_type)
|
|||
uop->src_reg_b = invalid_ir_reg;
|
||||
uop->src_reg_c = invalid_ir_reg;
|
||||
|
||||
uop->pc = cpu_state.oldpc;
|
||||
|
||||
uop->jump_dest_uop = -1;
|
||||
uop->jump_list_next = -1;
|
||||
|
||||
if (uop_type & (UOP_TYPE_BARRIER | UOP_TYPE_ORDER_BARRIER))
|
||||
|
|
|
|||
Loading…
Reference in a new issue