Lines Matching refs:ts

44     TCGTemp *ts;  member
112 static inline TempOptInfo *ts_info(TCGTemp *ts) in ts_info() argument
114 return ts->state_ptr; in ts_info()
122 static inline bool ts_is_const(TCGTemp *ts) in ts_is_const() argument
124 return ts_info(ts)->is_const; in ts_is_const()
132 static inline bool ts_is_copy(TCGTemp *ts) in ts_is_copy() argument
134 return ts_info(ts)->next_copy != ts; in ts_is_copy()
143 static void init_ts_info(OptContext *ctx, TCGTemp *ts) in init_ts_info() argument
145 size_t idx = temp_idx(ts); in init_ts_info()
153 ti = ts->state_ptr; in init_ts_info()
156 ts->state_ptr = ti; in init_ts_info()
159 ti->next_copy = ts; in init_ts_info()
160 ti->prev_copy = ts; in init_ts_info()
162 if (ts->kind == TEMP_CONST) { in init_ts_info()
164 ti->val = ts->val; in init_ts_info()
165 ti->z_mask = ts->val; in init_ts_info()
166 ti->s_mask = smask_from_value(ts->val); in init_ts_info()
188 TCGTemp *ts = mc->ts; in remove_mem_copy() local
189 TempOptInfo *ti = ts_info(ts); in remove_mem_copy()
213 static TCGTemp *find_better_copy(TCGTemp *ts) in find_better_copy() argument
218 if (temp_readonly(ts)) { in find_better_copy()
219 return ts; in find_better_copy()
222 ret = ts; in find_better_copy()
223 for (i = ts_info(ts)->next_copy; i != ts; i = ts_info(i)->next_copy) { in find_better_copy()
236 tcg_debug_assert(mc->ts == src_ts); in move_mem_copies()
237 mc->ts = dst_ts; in move_mem_copies()
243 static void reset_ts(OptContext *ctx, TCGTemp *ts) in reset_ts() argument
245 TempOptInfo *ti = ts_info(ts); in reset_ts()
253 ti->next_copy = ts; in reset_ts()
254 ti->prev_copy = ts; in reset_ts()
260 if (ts == nts) { in reset_ts()
268 move_mem_copies(find_better_copy(nts), ts); in reset_ts()
279 TCGTemp *ts, intptr_t start, intptr_t last) in record_mem_copy() argument
297 ts = find_better_copy(ts); in record_mem_copy()
298 ti = ts_info(ts); in record_mem_copy()
299 mc->ts = ts; in record_mem_copy()
335 return find_better_copy(mc->ts); in find_mem_copy_for()
344 TCGTemp *ts; in arg_new_constant() local
350 ts = tcg_constant_internal(type, val); in arg_new_constant()
351 init_ts_info(ctx, ts); in arg_new_constant()
353 return temp_arg(ts); in arg_new_constant()
791 TCGTemp *ts = arg_temp(op->args[i]); in init_arguments() local
792 init_ts_info(ctx, ts); in init_arguments()
800 TCGTemp *ts = arg_temp(op->args[i]); in copy_propagate() local
801 if (ts_is_copy(ts)) { in copy_propagate()
802 op->args[i] = temp_arg(find_better_copy(ts)); in copy_propagate()
827 TCGTemp *ts = arg_temp(op->args[i]); in finish_folding() local
828 reset_ts(ctx, ts); in finish_folding()
834 ts_info(ts)->z_mask = ctx->z_mask; in finish_folding()
835 ts_info(ts)->s_mask = ctx->s_mask; in finish_folding()