2012年6月21日 星期四

Thinking Flow

study qemu code: tcg_reg_alloc_op(): 1708
  1. what is fixed_reg TCGemp 
    1. in tcg_global_reg_new_internal, fixed_reg is set 1
    2. in tcg_global_mem_new_internal, fixed_reg is set 0
    3. so, it seems it indicates whether this temp is register or not
  2. In TCGContext, what is reg_to_temp?
    1. in tcg_reg_alloc(), s->reg_to_temp[reg] decides whether the HOST register is mapped to any TCGTemp.
    2. So I think, reg_to_temp indicates current HOST reg represents reg_to_temp[reg].
  3. What is val_type in TCGTemp?
    1. NOT CLEAR
    2. It seems it indicates the current type of this temp.
    3. It is possible that ts->fixed_reg && ts->val_type == TEMP_VAL_MEM; or                            NOT ts->fixed_reg and ts->val_type == TEMP_VAL_REG.
  4. When does TCGArgDef args_ct set?


沒有留言:

張貼留言