From patchwork Wed Oct 18 21:51:13 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 735101 Delivered-To: patch@linaro.org Received: by 2002:adf:f0cd:0:b0:32d:baff:b0ca with SMTP id x13csp1226119wro; Wed, 18 Oct 2023 14:59:03 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH8IimlaxtM0m4qoJ7EpmXPmEy6I9HDwQAwBjppYr64YmkQA0w0nIetJydvxB/KTOcPr06r X-Received: by 2002:a05:620a:440d:b0:770:9bd2:b3be with SMTP id v13-20020a05620a440d00b007709bd2b3bemr611724qkp.5.1697666343223; Wed, 18 Oct 2023 14:59:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697666343; cv=none; d=google.com; s=arc-20160816; b=mn6cvPCdk35GbJr2R3OXVS1CaeIII8j03k+BkaSatJXT7XXhPkc/d+G+kThcqsS/aR ooj9q2ApwX4fKMUhLSZW/5Q5xC7wExLL66ZGLXkFPz2Rqaa8e6YG6fpVYbUF+VqMlC6w +hW7BZy5z6iMOl+hPWqj7Nv5J2dfjcnxiZCEbzsRNjm7STSgWTxyc6jVVgwZQ3iwUv7b sRgG6S3Y0dl/oWS+iP/faZHy0c93tkewOM6nbSgEOSdrLJTDzeMyMOWimibWnZmmVJFI MWiln6pcG6EMePYJNHiYalaqGba2WUtNT37WroPGGkWyRcyc0uL5EUk2ma62+ooEbNTR vDrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=BTsHGEmbn21c10ys+IjqGnSmEEiyrrhk+QQul6l60rI=; fh=f2WZoDMBYjCKWIIOoPI+rQtxlv4fmOm4u+dLdQLqpOk=; b=XQcRF+UJTZyGM7+aBpXNAXQnk5lvYlH8ry91qf06NDvWoGlLMJ07paAcRwHyI5a21p KKIMM7OPh8gBEHCir/QvILuoUv7mSUAkyBGx20em47NNPY9mFlQMppmfmUU5Ojji7/O7 J+Qu44gDy6OSSbsKoOTQRsf5iWdvYHd48GQ2wCRwojd0NkaNy5Xmp3kK8sPJv3SQms7v GV4dsxOS2T3ziQbyHfmRJE4QpDqLrF8wZTx/T8gY1XhtTHXIE52Qsd4UDZfvJcru7+ed ySldBELv+NiJESZ1mRuiuTOGyD7cS8dIHf2d26Z4uZehtklOn/PnF7Gj9mgQEp++6wB4 uFuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=nKnKRpkp; 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 h27-20020a05620a13fb00b00775869cf15fsi587653qkl.521.2023.10.18.14.59.03 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 18 Oct 2023 14:59:03 -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=nKnKRpkp; 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] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qtESp-000253-65; Wed, 18 Oct 2023 17:52:27 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qtESb-0001cj-Ar for qemu-devel@nongnu.org; Wed, 18 Oct 2023 17:52:13 -0400 Received: from mail-pf1-x432.google.com ([2607:f8b0:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qtESY-0004U1-DD for qemu-devel@nongnu.org; Wed, 18 Oct 2023 17:52:12 -0400 Received: by mail-pf1-x432.google.com with SMTP id d2e1a72fcca58-6b1e46ca282so5750796b3a.2 for ; Wed, 18 Oct 2023 14:52:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1697665929; x=1698270729; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=BTsHGEmbn21c10ys+IjqGnSmEEiyrrhk+QQul6l60rI=; b=nKnKRpkpSWxDkshiyJr7QXtzsFM1jq2Iz4ymY6lpSJ+omHKqlQQXr6Ifg9vT5VYuzM LZF1FU5jNlicH+Gv5iethsT9V8veDUW8U12WITfXrsa59o1fIQ8fq0dhHCWYLJX8cMu6 du+bTTH6vhykQlqOg4PBgxhwKHS6Mm1hdjI1SZHagQX9LbtRtK6u1KsejK8FsYlpuELh 0UbDs9Uu04YAWjqm+kV3bqX0ZYY26yUf+6bsTcTm53b4UTuEFjaMTTVsKfsavWwgRgzt 6UAnVL+2J/ITdlAS3CVrGwnriQNO/atOGPt+R7B0nX/WYZeOYhMXCdHbyVr2tpcL+avB VX6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697665929; x=1698270729; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=BTsHGEmbn21c10ys+IjqGnSmEEiyrrhk+QQul6l60rI=; b=Z2we735haMmFXwCgt0Zp5AhcUbP73mJsBe0IdvFIr5TWn0oH8FyVhph+DeeVJVe6E7 E0BikIHZjOd/p1kZFt3c2dYv/JA88HsiFkMyufbCd7l73Rb83D8ZuCO+HxkPMhB7stbt xlIfd2z+ainRhxORNygm9HvlhHKf9XRatBouO76RjKjIUIY49ivk2Kzfko2Z1CUQoN6Y TvRHQCr2vWSI7yx1f5KN2fJjpa0jRm9EvDKrta2V4VJouZEQZls4Ox+2Q9m/Sw8qZuDO 5Seo7mtypJXRgFBPjwh+EZQPkQZc4McfxRmooVwo5CoIcV1fV7GIc2vbTC3RzgeaTmix vDMQ== X-Gm-Message-State: AOJu0YyGfc4OPOWCABUHtGOl8Pn4S32lDRgXRY0QbdyqsmBjTEFyo2vV J5TGM/Vg+bcnvnFeDYIExa1xERYGa6xAgKXDxNE= X-Received: by 2002:a05:6a21:4881:b0:16b:79b3:2285 with SMTP id av1-20020a056a21488100b0016b79b32285mr391796pzc.56.1697665928827; Wed, 18 Oct 2023 14:52:08 -0700 (PDT) Received: from stoup.. ([71.212.149.95]) by smtp.gmail.com with ESMTPSA id w17-20020a63f511000000b005b61a024ec7sm2176380pgh.74.2023.10.18.14.52.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Oct 2023 14:52:08 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: deller@gmx.de Subject: [PATCH 39/61] target/hppa: Implement LDD, LDCD, LDDA, STD, STDA Date: Wed, 18 Oct 2023 14:51:13 -0700 Message-Id: <20231018215135.1561375-40-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231018215135.1561375-1-richard.henderson@linaro.org> References: <20231018215135.1561375-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::432; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x432.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.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson --- target/hppa/insns.decode | 15 +++++++++++---- target/hppa/translate.c | 4 ++++ 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/target/hppa/insns.decode b/target/hppa/insns.decode index 48f09c9b06..33eec3f4c3 100644 --- a/target/hppa/insns.decode +++ b/target/hppa/insns.decode @@ -215,9 +215,14 @@ ld 000011 ..... ..... .. . 0 -- 00 size:2 ...... @ldstx st 000011 ..... ..... .. . 1 -- 10 size:2 ...... @stim5 ldc 000011 ..... ..... .. . 1 -- 0111 ...... @ldim5 size=2 ldc 000011 ..... ..... .. . 0 -- 0111 ...... @ldstx size=2 +ldc 000011 ..... ..... .. . 1 -- 0101 ...... @ldim5 size=3 +ldc 000011 ..... ..... .. . 0 -- 0101 ...... @ldstx size=3 lda 000011 ..... ..... .. . 1 -- 0110 ...... @ldim5 size=2 lda 000011 ..... ..... .. . 0 -- 0110 ...... @ldstx size=2 +lda 000011 ..... ..... .. . 1 -- 0100 ...... @ldim5 size=3 +lda 000011 ..... ..... .. . 0 -- 0100 ...... @ldstx size=3 sta 000011 ..... ..... .. . 1 -- 1110 ...... @stim5 size=2 +sta 000011 ..... ..... .. . 1 -- 1111 ...... @stim5 size=3 stby 000011 b:5 r:5 sp:2 a:1 1 -- 1100 m:1 ..... disp=%im5_0 @fldstwx ...... b:5 x:5 sp:2 scale:1 ....... m:1 ..... \ @@ -244,6 +249,8 @@ fstd 001011 ..... ..... .. . 1 -- 100 0 . ..... @fldstdi # Offset Mem #### +@ldstim11 ...... b:5 t:5 sp:2 .............. \ + &ldst disp=%assemble_11a m=%ma2_to_m x=0 scale=0 size=3 @ldstim14 ...... b:5 t:5 sp:2 .............. \ &ldst disp=%lowsign_14 x=0 scale=0 m=0 @ldstim14m ...... b:5 t:5 sp:2 .............. \ @@ -275,11 +282,11 @@ fstw 011110 b:5 ..... sp:2 .............. \ fstw 011111 b:5 ..... sp:2 ...........0.. \ &ldst disp=%assemble_12a t=%rm64 m=0 x=0 scale=0 size=2 -fldd 010100 b:5 t:5 sp:2 .......... .. 1 . \ - &ldst disp=%assemble_11a m=%ma2_to_m x=0 scale=0 size=3 +ld 010100 ..... ..... .. ............0. @ldstim11 +fldd 010100 ..... ..... .. ............1. @ldstim11 -fstd 011100 b:5 t:5 sp:2 .......... .. 1 . \ - &ldst disp=%assemble_11a m=%ma2_to_m x=0 scale=0 size=3 +st 011100 ..... ..... .. ............0. @ldstim11 +fstd 011100 ..... ..... .. ............1. @ldstim11 #### # Floating-point Multiply Add diff --git a/target/hppa/translate.c b/target/hppa/translate.c index 7e723dcd24..308b8dd263 100644 --- a/target/hppa/translate.c +++ b/target/hppa/translate.c @@ -2951,6 +2951,10 @@ static bool trans_ldc(DisasContext *ctx, arg_ldst *a) TCGv_reg zero, dest, ofs; TCGv_tl addr; + if (unlikely(TARGET_REGISTER_BITS == 32 && a->size > MO_32)) { + return gen_illegal(ctx); + } + nullify_over(ctx); if (a->m) {