From patchwork Sun Apr 10 05:57:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 559484 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:6886:0:0:0:0 with SMTP id m6csp1583997map; Sat, 9 Apr 2022 22:59:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy/s0stJgcxHmS+HJzFawLj7HzaZgVJIF5usWmQNQQuk/c+5+xHL/Ed5/ZHcYRMV1okM1Nh X-Received: by 2002:ac8:3d49:0:b0:2eb:cbf8:4140 with SMTP id u9-20020ac83d49000000b002ebcbf84140mr13393994qtf.279.1649570370651; Sat, 09 Apr 2022 22:59:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649570370; cv=none; d=google.com; s=arc-20160816; b=mBiD2e6lZcUeCcc44fg9WCFhNpoTTh1Nt1Hp7BPGIQagyQt/x2hnC9PBY8ClhoiyRz wBUAQy4cJBwBbCunVXaCdz8XMeRUPXV8dDor6Z4IL7Ev/siqzozaJN+lAPYe4V8trWAu SA9YJTkRGcb0ZqRg+JEopXeJhqb3V35haAVd5fqg0RraVCGSrpZHrGFMe1slkSWXhjwy Z6qTD8i8tuD9uc9jUQtYOw5DuVyh256Md5kYQJl9BnOIoNFhcvJAG9Mh2gjnqak0abka rLCiFNHqjgXuuAsoRyL5jO+n0q20FjRpUf0wg9WiqD7Zr/ThVr0B4ZMexM+sVLtOuXwy GzqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=rLOhJvvj7gL9dKj7DvOFNAonGDNAYGQD5IOiVrmpC+4=; b=BgnwUORckUOJg5KxoGOwBYgc2SV0jxNmFouNwdBBBbqXLy7AykRQdRlpwo42bUOYej k+jEfjzShCZP5fNVfHL7aLbPb3mdaoxnPulBImvlF1Da6j3RMXOa8Z042SzvyIFZWnTo ooO1xdZk2MgqFWwgGbTMZK0rW+PSZGn+TSAhLnxkLtUFQ5VTaYZkJ/yXOpCpL+hjyxs8 UCIw7/8fgaD/+IYDw3wJyLfFhP96C4pQCJw9ijVfEewgJdkSc1BLE7vzdRnVVl26R6ZP MbS4VAJAs4WjZ5x2x3aF0dUw3F8jwfisbC9pieVs6cfjQXsfP+koF2sZ/G7+grS3v60x wBqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gvf3jxfy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i5-20020a378605000000b0067e8a0e35b6si2690469qkd.277.2022.04.09.22.59.30 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 09 Apr 2022 22:59:30 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gvf3jxfy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:38944 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ndQbi-0001y7-5j for patch@linaro.org; Sun, 10 Apr 2022 01:59:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40990) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ndQZn-0001wl-N1 for qemu-devel@nongnu.org; Sun, 10 Apr 2022 01:57:31 -0400 Received: from mail-pf1-x42f.google.com ([2607:f8b0:4864:20::42f]:35761) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ndQZl-0002yr-64 for qemu-devel@nongnu.org; Sun, 10 Apr 2022 01:57:31 -0400 Received: by mail-pf1-x42f.google.com with SMTP id f3so11936402pfe.2 for ; Sat, 09 Apr 2022 22:57:28 -0700 (PDT) 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=rLOhJvvj7gL9dKj7DvOFNAonGDNAYGQD5IOiVrmpC+4=; b=gvf3jxfymqplg7m2aamXw5cSmTrPxbG7H6v6wi+7bHPg4GIOObNmEKAhAYjh3jn7TS AqF6awPVYSUDKw6rMDEjNH1bN+K89Kq1wWBpySB1wx1s/gc37dG/+lupS35K78Cg2drb hVP5qAavydPuYP2YXFdVDZHVoRiD5iObgTZNanQlG4Voa72fUz9+VSKOPp+Gc0wF0zmo fT4/UQuwM3cJEpk9pYvGNYBDq6M6xEw4v30S1NOC2NVnTaHVxYp68+e+fjcoabJGvA5l Jm/zheF4rqh1EgeQUqemzAyn96gGrC6KbfL/U8c5XRGVQMRrt68L9ESG6l2RW7vaVbxR biDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=rLOhJvvj7gL9dKj7DvOFNAonGDNAYGQD5IOiVrmpC+4=; b=U9LsErPwbe9r/yVPSpOL/tHMm7AlvXu21i+w9gegW0yglw6gRQ9TfqTxLK/jUogyCh gf7VXOx+9PySSmdgssYbZ+FxojOqjSPEzUPcNYfTe6rHCfDClh6FeYW/H9BC3WSfYTev 3rnf5aSG9eN9ije8VCwYPwOw8M58npd3niGzvxXhgCBBZ9oJhHMqpyC6H8nWrS1q00Ff txcWlkmlgeF7Mp+dgqDvN0L7Rb5nVUCv9ixHZVkaeOenBmdLPLcimEqwZY7JTYGFA0rt igilGNQvfvkJoVfBPgstIdOcsJXFQMe1cHqmAQV0uTb27zNioJmrnHnlo2PcCNSm3lIB rPXA== X-Gm-Message-State: AOAM5331zXezwX+ycpsh79SqvqlFfltaoqMk7TooY1sRq2tcP9UxqK1D pYrovJHY0MvKwCILIiw8y3+pNiv87g9vog== X-Received: by 2002:a63:535c:0:b0:39d:353e:64d5 with SMTP id t28-20020a63535c000000b0039d353e64d5mr2526210pgl.355.1649570247925; Sat, 09 Apr 2022 22:57:27 -0700 (PDT) Received: from localhost.localdomain (174-21-142-130.tukw.qwest.net. [174.21.142.130]) by smtp.gmail.com with ESMTPSA id l18-20020a056a00141200b004f75395b2cesm30481862pfu.150.2022.04.09.22.57.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 09 Apr 2022 22:57:27 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH 1/7] target/arm: Enable FEAT_CSV2 for -cpu max Date: Sat, 9 Apr 2022 22:57:19 -0700 Message-Id: <20220410055725.380246-2-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220410055725.380246-1-richard.henderson@linaro.org> References: <20220410055725.380246-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42f; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x42f.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, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-arm@nongnu.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" This extension concerns branch speculation, which TCG does not implement. Thus we can trivially enable this feature. Signed-off-by: Richard Henderson Reviewed-by: Peter Maydell --- target/arm/cpu64.c | 1 + target/arm/cpu_tcg.c | 1 + 2 files changed, 2 insertions(+) diff --git a/target/arm/cpu64.c b/target/arm/cpu64.c index def0f1fdcb..c1006a067c 100644 --- a/target/arm/cpu64.c +++ b/target/arm/cpu64.c @@ -805,6 +805,7 @@ static void aarch64_max_initfn(Object *obj) t = FIELD_DP64(t, ID_AA64PFR0, SVE, 1); t = FIELD_DP64(t, ID_AA64PFR0, SEL2, 1); /* FEAT_SEL2 */ t = FIELD_DP64(t, ID_AA64PFR0, DIT, 1); /* FEAT_DIT */ + t = FIELD_DP64(t, ID_AA64PFR0, CSV2, 1); /* FEAT_CSV2 */ cpu->isar.id_aa64pfr0 = t; t = cpu->isar.id_aa64pfr1; diff --git a/target/arm/cpu_tcg.c b/target/arm/cpu_tcg.c index 5cce9116d0..2750cbebec 100644 --- a/target/arm/cpu_tcg.c +++ b/target/arm/cpu_tcg.c @@ -71,6 +71,7 @@ void arm32_max_features(ARMCPU *cpu) cpu->isar.id_mmfr4 = t; t = cpu->isar.id_pfr0; + t = FIELD_DP32(t, ID_PFR0, CSV2, 2); /* FEAT_CVS2 */ t = FIELD_DP32(t, ID_PFR0, DIT, 1); /* FEAT_DIT */ t = FIELD_DP32(t, ID_PFR0, RAS, 1); /* FEAT_RAS */ cpu->isar.id_pfr0 = t;