From nobody Fri Dec 19 19:55:41 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1610590746; cv=none; d=zohomail.com; s=zohoarc; b=FJK12kn8wpxHU6tfXnZ/r212SJHKva7htHdhFY1Cau9zPLuOihjLadhpM4uH2fS9Y5PCoby1ryyRRWovwB8XwUNQundjoQqzw03BkNwuwCCRFhiTGEa4TfltTBj6hkLL++2qlhChig7yVZlzPEVau1IRRH9WqmDGDJFi0tF0Afs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1610590746; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=XLAgXi9Czh5X/FA90bM/X3fbOzQ/DCfR5wliDIq/uwU=; b=X2SfYjZvZBDoGxHvDczPyRcEAPCir17eKRiwZIoccwC2uSlE3OqYpjiwYThuTmf8OuUVY9qfWoMAL5oEBJ4TKafbEiBzsL9UV3WPkRoyVbUnUdWEY9stpk9HpknTXR8Wgyg52R+xxJ+lorF2UX9W8OOytSy3//Y1wb61ryNOpNY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1610590746225657.0252889413188; Wed, 13 Jan 2021 18:19:06 -0800 (PST) Received: from localhost ([::1]:38074 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kzsE5-00059C-1a for importer@patchew.org; Wed, 13 Jan 2021 21:19:05 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:60128) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kzsCD-0003Kc-87 for qemu-devel@nongnu.org; Wed, 13 Jan 2021 21:17:09 -0500 Received: from mail-pj1-x102e.google.com ([2607:f8b0:4864:20::102e]:52227) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kzsCA-0003OA-5M for qemu-devel@nongnu.org; Wed, 13 Jan 2021 21:17:09 -0500 Received: by mail-pj1-x102e.google.com with SMTP id v1so2267512pjr.2 for ; Wed, 13 Jan 2021 18:17:04 -0800 (PST) Received: from localhost.localdomain (rrcs-173-197-107-21.west.biz.rr.com. [173.197.107.21]) by smtp.gmail.com with ESMTPSA id i7sm3771687pfc.50.2021.01.13.18.17.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Jan 2021 18:17:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=XLAgXi9Czh5X/FA90bM/X3fbOzQ/DCfR5wliDIq/uwU=; b=CWqyamgpNLVCTcaOifpWf9qMrPDKmRpnwEqYa+8QWZPRmcWm8AsnhlAdDlqFC7L9v0 phKy7CPE+fIU8U2kKt4YmbMdFSeqnZentsxDmao2qdD1ZDLZFaZ5GNdEVkepfjC6v/lD XLM16d5RVAAtg+RVlkt2HZLmKGCKj3ltCupMtJS1A2kJnxXlaY9Cz8vf8eQsalTpu/KS ZhreGFytp1LAfLhEzUT3XZm40o9mtQD3RyxRTJim9IAwwNnpFhRopfeext/SCR3EguhO j4hTMtUd/mVnVD3Mlt5K6cc90CwrnV5PWXAxQkCCLzu8jYaDK/JwJIBEbn+ajtmw6yr9 TMsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=XLAgXi9Czh5X/FA90bM/X3fbOzQ/DCfR5wliDIq/uwU=; b=EywQGYgEerftkjkbMslfAQZyZc9wNTlDjXVtTkN4+gp2/Slcakc0b3eD9mQPXuUBrD joa83lv4wIhvEda8jNvk3KfK+WkKqeNedogMc8R4MxIIfqLZdf6XGUSCF5VyqUKoEvO9 1L/IgbXeaG0iIMXV9rPqpOS4stK3TpoIcAsodPZaOxwO8D9XLDKfldXsfRox161VqwGx QONEV0OTTJut4sm/J8zArV9+p9LdLaHM0VNW/6wbhNqZ7Z2UpMG+0RIL/JKSwM/tuo9X 9wuEL6hVPYEPrpfBe+6lTFRxzLbdyHy97mQ/rnTNFdFjSOn1TKHJ4QNgzyethnmKGdGC Tp1A== X-Gm-Message-State: AOAM532Z28mvF54L/m7lxgjNQPUAi/ka1TMW5fgYg4kY+zYyOD2KKqKv vmQtKFPwL0B7/ksIJujDBiZ+vDffUybZzw== X-Google-Smtp-Source: ABdhPJxgN9Ra7bk83SeWxdLU8xykwwz8WjX0hYheJYj+LRKI1VM3QkydJ87ppWze0FcE3MNU5wpXjA== X-Received: by 2002:a17:902:d894:b029:db:e0c6:49a4 with SMTP id b20-20020a170902d894b02900dbe0c649a4mr5440528plz.1.1610590623192; Wed, 13 Jan 2021 18:17:03 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 03/24] tcg: Consolidate 3 bits into enum TCGTempKind Date: Wed, 13 Jan 2021 16:16:33 -1000 Message-Id: <20210114021654.647242-4-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210114021654.647242-1-richard.henderson@linaro.org> References: <20210114021654.647242-1-richard.henderson@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2607:f8b0:4864:20::102e; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x102e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: peter.maydell@linaro.org, =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @linaro.org) The temp_fixed, temp_global, temp_local bits are all related. Combine them into a single enumeration. Reviewed-by: Alex Benn=C3=A9e Reviewed-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Richard Henderson --- include/tcg/tcg.h | 20 +++++--- tcg/optimize.c | 8 +-- tcg/tcg.c | 126 ++++++++++++++++++++++++++++------------------ 3 files changed, 92 insertions(+), 62 deletions(-) diff --git a/include/tcg/tcg.h b/include/tcg/tcg.h index 95fe5604eb..571d4e0fa3 100644 --- a/include/tcg/tcg.h +++ b/include/tcg/tcg.h @@ -483,23 +483,27 @@ typedef enum TCGTempVal { TEMP_VAL_CONST, } TCGTempVal; =20 +typedef enum TCGTempKind { + /* Temp is dead at the end of all basic blocks. */ + TEMP_NORMAL, + /* Temp is saved across basic blocks but dead at the end of TBs. */ + TEMP_LOCAL, + /* Temp is saved across both basic blocks and translation blocks. */ + TEMP_GLOBAL, + /* Temp is in a fixed register. */ + TEMP_FIXED, +} TCGTempKind; + typedef struct TCGTemp { TCGReg reg:8; TCGTempVal val_type:8; TCGType base_type:8; TCGType type:8; - unsigned int fixed_reg:1; + TCGTempKind kind:3; unsigned int indirect_reg:1; unsigned int indirect_base:1; unsigned int mem_coherent:1; unsigned int mem_allocated:1; - /* If true, the temp is saved across both basic blocks and - translation blocks. */ - unsigned int temp_global:1; - /* If true, the temp is saved across basic blocks but dead - at the end of translation blocks. If false, the temp is - dead at the end of basic blocks. */ - unsigned int temp_local:1; unsigned int temp_allocated:1; =20 tcg_target_long val; diff --git a/tcg/optimize.c b/tcg/optimize.c index 1fb42eb2a9..2f827a9d2d 100644 --- a/tcg/optimize.c +++ b/tcg/optimize.c @@ -116,21 +116,21 @@ static TCGTemp *find_better_copy(TCGContext *s, TCGTe= mp *ts) TCGTemp *i; =20 /* If this is already a global, we can't do better. */ - if (ts->temp_global) { + if (ts->kind >=3D TEMP_GLOBAL) { return ts; } =20 /* Search for a global first. */ for (i =3D ts_info(ts)->next_copy; i !=3D ts; i =3D ts_info(i)->next_c= opy) { - if (i->temp_global) { + if (i->kind >=3D TEMP_GLOBAL) { return i; } } =20 /* If it is a temp, search for a temp local. */ - if (!ts->temp_local) { + if (ts->kind =3D=3D TEMP_NORMAL) { for (i =3D ts_info(ts)->next_copy; i !=3D ts; i =3D ts_info(i)->ne= xt_copy) { - if (ts->temp_local) { + if (i->kind >=3D TEMP_LOCAL) { return i; } } diff --git a/tcg/tcg.c b/tcg/tcg.c index c73128208c..143794a585 100644 --- a/tcg/tcg.c +++ b/tcg/tcg.c @@ -1211,7 +1211,7 @@ static inline TCGTemp *tcg_global_alloc(TCGContext *s) tcg_debug_assert(s->nb_globals =3D=3D s->nb_temps); s->nb_globals++; ts =3D tcg_temp_alloc(s); - ts->temp_global =3D 1; + ts->kind =3D TEMP_GLOBAL; =20 return ts; } @@ -1228,7 +1228,7 @@ static TCGTemp *tcg_global_reg_new_internal(TCGContex= t *s, TCGType type, ts =3D tcg_global_alloc(s); ts->base_type =3D type; ts->type =3D type; - ts->fixed_reg =3D 1; + ts->kind =3D TEMP_FIXED; ts->reg =3D reg; ts->name =3D name; tcg_regset_set_reg(s->reserved_regs, reg); @@ -1255,7 +1255,7 @@ TCGTemp *tcg_global_mem_new_internal(TCGType type, TC= Gv_ptr base, bigendian =3D 1; #endif =20 - if (!base_ts->fixed_reg) { + if (base_ts->kind !=3D TEMP_FIXED) { /* We do not support double-indirect registers. */ tcg_debug_assert(!base_ts->indirect_reg); base_ts->indirect_base =3D 1; @@ -1303,6 +1303,7 @@ TCGTemp *tcg_global_mem_new_internal(TCGType type, TC= Gv_ptr base, TCGTemp *tcg_temp_new_internal(TCGType type, bool temp_local) { TCGContext *s =3D tcg_ctx; + TCGTempKind kind =3D temp_local ? TEMP_LOCAL : TEMP_NORMAL; TCGTemp *ts; int idx, k; =20 @@ -1315,7 +1316,7 @@ TCGTemp *tcg_temp_new_internal(TCGType type, bool tem= p_local) ts =3D &s->temps[idx]; ts->temp_allocated =3D 1; tcg_debug_assert(ts->base_type =3D=3D type); - tcg_debug_assert(ts->temp_local =3D=3D temp_local); + tcg_debug_assert(ts->kind =3D=3D kind); } else { ts =3D tcg_temp_alloc(s); if (TCG_TARGET_REG_BITS =3D=3D 32 && type =3D=3D TCG_TYPE_I64) { @@ -1324,18 +1325,18 @@ TCGTemp *tcg_temp_new_internal(TCGType type, bool t= emp_local) ts->base_type =3D type; ts->type =3D TCG_TYPE_I32; ts->temp_allocated =3D 1; - ts->temp_local =3D temp_local; + ts->kind =3D kind; =20 tcg_debug_assert(ts2 =3D=3D ts + 1); ts2->base_type =3D TCG_TYPE_I64; ts2->type =3D TCG_TYPE_I32; ts2->temp_allocated =3D 1; - ts2->temp_local =3D temp_local; + ts2->kind =3D kind; } else { ts->base_type =3D type; ts->type =3D type; ts->temp_allocated =3D 1; - ts->temp_local =3D temp_local; + ts->kind =3D kind; } } =20 @@ -1392,12 +1393,12 @@ void tcg_temp_free_internal(TCGTemp *ts) } #endif =20 - tcg_debug_assert(ts->temp_global =3D=3D 0); + tcg_debug_assert(ts->kind < TEMP_GLOBAL); tcg_debug_assert(ts->temp_allocated !=3D 0); ts->temp_allocated =3D 0; =20 idx =3D temp_idx(ts); - k =3D ts->base_type + (ts->temp_local ? TCG_TYPE_COUNT : 0); + k =3D ts->base_type + (ts->kind =3D=3D TEMP_NORMAL ? 0 : TCG_TYPE_COUN= T); set_bit(idx, s->free_temps[k].l); } =20 @@ -1930,17 +1931,27 @@ void tcg_gen_callN(void *func, TCGTemp *ret, int na= rgs, TCGTemp **args) static void tcg_reg_alloc_start(TCGContext *s) { int i, n; - TCGTemp *ts; =20 - for (i =3D 0, n =3D s->nb_globals; i < n; i++) { - ts =3D &s->temps[i]; - ts->val_type =3D (ts->fixed_reg ? TEMP_VAL_REG : TEMP_VAL_MEM); - } - for (n =3D s->nb_temps; i < n; i++) { - ts =3D &s->temps[i]; - ts->val_type =3D (ts->temp_local ? TEMP_VAL_MEM : TEMP_VAL_DEAD); - ts->mem_allocated =3D 0; - ts->fixed_reg =3D 0; + for (i =3D 0, n =3D s->nb_temps; i < n; i++) { + TCGTemp *ts =3D &s->temps[i]; + TCGTempVal val =3D TEMP_VAL_MEM; + + switch (ts->kind) { + case TEMP_FIXED: + val =3D TEMP_VAL_REG; + break; + case TEMP_GLOBAL: + break; + case TEMP_NORMAL: + val =3D TEMP_VAL_DEAD; + /* fall through */ + case TEMP_LOCAL: + ts->mem_allocated =3D 0; + break; + default: + g_assert_not_reached(); + } + ts->val_type =3D val; } =20 memset(s->reg_to_temp, 0, sizeof(s->reg_to_temp)); @@ -1951,12 +1962,17 @@ static char *tcg_get_arg_str_ptr(TCGContext *s, cha= r *buf, int buf_size, { int idx =3D temp_idx(ts); =20 - if (ts->temp_global) { + switch (ts->kind) { + case TEMP_FIXED: + case TEMP_GLOBAL: pstrcpy(buf, buf_size, ts->name); - } else if (ts->temp_local) { + break; + case TEMP_LOCAL: snprintf(buf, buf_size, "loc%d", idx - s->nb_globals); - } else { + break; + case TEMP_NORMAL: snprintf(buf, buf_size, "tmp%d", idx - s->nb_globals); + break; } return buf; } @@ -2547,15 +2563,24 @@ static void la_bb_end(TCGContext *s, int ng, int nt) { int i; =20 - for (i =3D 0; i < ng; ++i) { - s->temps[i].state =3D TS_DEAD | TS_MEM; - la_reset_pref(&s->temps[i]); - } - for (i =3D ng; i < nt; ++i) { - s->temps[i].state =3D (s->temps[i].temp_local - ? TS_DEAD | TS_MEM - : TS_DEAD); - la_reset_pref(&s->temps[i]); + for (i =3D 0; i < nt; ++i) { + TCGTemp *ts =3D &s->temps[i]; + int state; + + switch (ts->kind) { + case TEMP_FIXED: + case TEMP_GLOBAL: + case TEMP_LOCAL: + state =3D TS_DEAD | TS_MEM; + break; + case TEMP_NORMAL: + state =3D TS_DEAD; + break; + default: + g_assert_not_reached(); + } + ts->state =3D state; + la_reset_pref(ts); } } =20 @@ -2583,7 +2608,7 @@ static void la_bb_sync(TCGContext *s, int ng, int nt) la_global_sync(s, ng); =20 for (int i =3D ng; i < nt; ++i) { - if (s->temps[i].temp_local) { + if (s->temps[i].kind =3D=3D TEMP_LOCAL) { int state =3D s->temps[i].state; s->temps[i].state =3D state | TS_MEM; if (state !=3D TS_DEAD) { @@ -3191,7 +3216,8 @@ static void check_regs(TCGContext *s) } for (k =3D 0; k < s->nb_temps; k++) { ts =3D &s->temps[k]; - if (ts->val_type =3D=3D TEMP_VAL_REG && !ts->fixed_reg + if (ts->val_type =3D=3D TEMP_VAL_REG + && ts->kind !=3D TEMP_FIXED && s->reg_to_temp[ts->reg] !=3D ts) { printf("Inconsistency for temp %s:\n", tcg_get_arg_str_ptr(s, buf, sizeof(buf), ts)); @@ -3228,15 +3254,14 @@ static void temp_load(TCGContext *, TCGTemp *, TCGR= egSet, TCGRegSet, TCGRegSet); mark it free; otherwise mark it dead. */ static void temp_free_or_dead(TCGContext *s, TCGTemp *ts, int free_or_dead) { - if (ts->fixed_reg) { + if (ts->kind =3D=3D TEMP_FIXED) { return; } if (ts->val_type =3D=3D TEMP_VAL_REG) { s->reg_to_temp[ts->reg] =3D NULL; } ts->val_type =3D (free_or_dead < 0 - || ts->temp_local - || ts->temp_global + || ts->kind !=3D TEMP_NORMAL ? TEMP_VAL_MEM : TEMP_VAL_DEAD); } =20 @@ -3253,7 +3278,7 @@ static inline void temp_dead(TCGContext *s, TCGTemp *= ts) static void temp_sync(TCGContext *s, TCGTemp *ts, TCGRegSet allocated_regs, TCGRegSet preferred_regs, int free_or_dead) { - if (ts->fixed_reg) { + if (ts->kind =3D=3D TEMP_FIXED) { return; } if (!ts->mem_coherent) { @@ -3436,7 +3461,8 @@ static void temp_save(TCGContext *s, TCGTemp *ts, TCG= RegSet allocated_regs) { /* The liveness analysis already ensures that globals are back in memory. Keep an tcg_debug_assert for safety. */ - tcg_debug_assert(ts->val_type =3D=3D TEMP_VAL_MEM || ts->fixed_reg); + tcg_debug_assert(ts->val_type =3D=3D TEMP_VAL_MEM + || ts->kind =3D=3D TEMP_FIXED); } =20 /* save globals to their canonical location and assume they can be @@ -3461,7 +3487,7 @@ static void sync_globals(TCGContext *s, TCGRegSet all= ocated_regs) for (i =3D 0, n =3D s->nb_globals; i < n; i++) { TCGTemp *ts =3D &s->temps[i]; tcg_debug_assert(ts->val_type !=3D TEMP_VAL_REG - || ts->fixed_reg + || ts->kind =3D=3D TEMP_FIXED || ts->mem_coherent); } } @@ -3474,7 +3500,7 @@ static void tcg_reg_alloc_bb_end(TCGContext *s, TCGRe= gSet allocated_regs) =20 for (i =3D s->nb_globals; i < s->nb_temps; i++) { TCGTemp *ts =3D &s->temps[i]; - if (ts->temp_local) { + if (ts->kind =3D=3D TEMP_LOCAL) { temp_save(s, ts, allocated_regs); } else { /* The liveness analysis already ensures that temps are dead. @@ -3500,7 +3526,7 @@ static void tcg_reg_alloc_cbranch(TCGContext *s, TCGR= egSet allocated_regs) * The liveness analysis already ensures that temps are dead. * Keep tcg_debug_asserts for safety. */ - if (ts->temp_local) { + if (ts->kind =3D=3D TEMP_LOCAL) { tcg_debug_assert(ts->val_type !=3D TEMP_VAL_REG || ts->mem_coh= erent); } else { tcg_debug_assert(ts->val_type =3D=3D TEMP_VAL_DEAD); @@ -3516,7 +3542,7 @@ static void tcg_reg_alloc_do_movi(TCGContext *s, TCGT= emp *ots, TCGRegSet preferred_regs) { /* ENV should not be modified. */ - tcg_debug_assert(!ots->fixed_reg); + tcg_debug_assert(ots->kind !=3D TEMP_FIXED); =20 /* The movi is not explicitly generated here. */ if (ots->val_type =3D=3D TEMP_VAL_REG) { @@ -3556,7 +3582,7 @@ static void tcg_reg_alloc_mov(TCGContext *s, const TC= GOp *op) ts =3D arg_temp(op->args[1]); =20 /* ENV should not be modified. */ - tcg_debug_assert(!ots->fixed_reg); + tcg_debug_assert(ots->kind !=3D TEMP_FIXED); =20 /* Note that otype !=3D itype for no-op truncation. */ otype =3D ots->type; @@ -3595,7 +3621,7 @@ static void tcg_reg_alloc_mov(TCGContext *s, const TC= GOp *op) } temp_dead(s, ots); } else { - if (IS_DEAD_ARG(1) && !ts->fixed_reg) { + if (IS_DEAD_ARG(1) && ts->kind !=3D TEMP_FIXED) { /* the mov can be suppressed */ if (ots->val_type =3D=3D TEMP_VAL_REG) { s->reg_to_temp[ots->reg] =3D NULL; @@ -3617,7 +3643,7 @@ static void tcg_reg_alloc_mov(TCGContext *s, const TC= GOp *op) * Store the source register into the destination slot * and leave the destination temp as TEMP_VAL_MEM. */ - assert(!ots->fixed_reg); + assert(ots->kind !=3D TEMP_FIXED); if (!ts->mem_allocated) { temp_allocate_frame(s, ots); } @@ -3654,7 +3680,7 @@ static void tcg_reg_alloc_dup(TCGContext *s, const TC= GOp *op) its =3D arg_temp(op->args[1]); =20 /* ENV should not be modified. */ - tcg_debug_assert(!ots->fixed_reg); + tcg_debug_assert(ots->kind !=3D TEMP_FIXED); =20 itype =3D its->type; vece =3D TCGOP_VECE(op); @@ -3794,7 +3820,7 @@ static void tcg_reg_alloc_op(TCGContext *s, const TCG= Op *op) i_preferred_regs =3D o_preferred_regs =3D 0; if (arg_ct->ialias) { o_preferred_regs =3D op->output_pref[arg_ct->alias_index]; - if (ts->fixed_reg) { + if (ts->kind =3D=3D TEMP_FIXED) { /* if fixed register, we must allocate a new register if the alias is not the same register */ if (arg !=3D op->args[arg_ct->alias_index]) { @@ -3886,7 +3912,7 @@ static void tcg_reg_alloc_op(TCGContext *s, const TCG= Op *op) ts =3D arg_temp(arg); =20 /* ENV should not be modified. */ - tcg_debug_assert(!ts->fixed_reg); + tcg_debug_assert(ts->kind !=3D TEMP_FIXED); =20 if (arg_ct->oalias && !const_args[arg_ct->alias_index]) { reg =3D new_args[arg_ct->alias_index]; @@ -3927,7 +3953,7 @@ static void tcg_reg_alloc_op(TCGContext *s, const TCG= Op *op) ts =3D arg_temp(op->args[i]); =20 /* ENV should not be modified. */ - tcg_debug_assert(!ts->fixed_reg); + tcg_debug_assert(ts->kind !=3D TEMP_FIXED); =20 if (NEED_SYNC_ARG(i)) { temp_sync(s, ts, o_allocated_regs, 0, IS_DEAD_ARG(i)); @@ -4059,7 +4085,7 @@ static void tcg_reg_alloc_call(TCGContext *s, TCGOp *= op) ts =3D arg_temp(arg); =20 /* ENV should not be modified. */ - tcg_debug_assert(!ts->fixed_reg); + tcg_debug_assert(ts->kind !=3D TEMP_FIXED); =20 reg =3D tcg_target_call_oarg_regs[i]; tcg_debug_assert(s->reg_to_temp[reg] =3D=3D NULL); --=20 2.25.1