From patchwork Sat Apr 30 17:53:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 568155 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:6886:0:0:0:0 with SMTP id m6csp7375342map; Sat, 30 Apr 2022 11:06:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJykMlCxZNeXs+6knf8+FZIDPu7oLwTZxa3O06cSaoMxmpn+N2e5yF3oTOoZDkx6WDPo1iFV X-Received: by 2002:a05:622a:13:b0:2f3:64ce:c72a with SMTP id x19-20020a05622a001300b002f364cec72amr4307983qtw.620.1651341961446; Sat, 30 Apr 2022 11:06:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651341961; cv=none; d=google.com; s=arc-20160816; b=mqENbulSEo1O+hLm0mDq0d/UDvJQYntq9WX84Lw1Gok546ENDMoei65k8kSrwU2YqN wQ5Y3nCGeE2s7gQN0aMUH0uhF/xgE53EHh9cAuz1uT0Vd0ophwqH41K2XJNO7UpTsMxQ 2mysg4YDq2CG93Z4z6JJGSal8r1j5sVLMc4wOXPFUQ0UC20QOjkqOEwkBCXB7MWpcrMQ fkLW/y7ZVWmWiBZP21WbTwYTVLEKgK8OZ5MYhoPb3WT/z6cqJSzeXvICa/rfonuPZJ7d x/FwmKN0w4RkloOa7B8hPMMCcBkMxclKjaEoSgWXaOnQRhah/wPm5zvN7ykXuAMuIeeG ckEw== 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=8VjWHa4+EEAsb2rxF9krBBAxcFamsv8YuijfZ6HxZ44=; b=WwXpk88VCrhp5dh7POG88PAobk8HrU5BvRO2m2N8lyKgqPX3C4k19AB/C6h1nWM6Ty XAa2c7rLjVDialKBAOVfwbZs1Kxk7GX2CXG4Tbh3nyZwAQWJLSqQ3aXBmlTk+hzJAvVY ufNXXXAoEzwLTwFmVEEioPqlpAINZToQ9yGpwhAZsyepbF6Ml+lkieMRcTWk2+kaeJmE GzIddX5O38P2XuTQBpTl1uaYon1Xrkqzq17pkFsPIGWabjKV+iWYFS7/8aSjtwM83vaM r+NUmeGKAK6CN7I6ishQBq74zRPyzkg3Sq5+j10QUvaoPRsJjXcSwI/+3T6P0cV6Jdda e/qg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=yuurYXXg; 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 jo7-20020a056214500700b004462a228634si4653228qvb.569.2022.04.30.11.06.01 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 30 Apr 2022 11:06:01 -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=yuurYXXg; 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]:58296 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nkrTl-0004QB-26 for patch@linaro.org; Sat, 30 Apr 2022 14:06:01 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33410) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nkrI6-0004gq-If for qemu-devel@nongnu.org; Sat, 30 Apr 2022 13:53:58 -0400 Received: from mail-pl1-x635.google.com ([2607:f8b0:4864:20::635]:36735) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nkrI4-00083c-Rz for qemu-devel@nongnu.org; Sat, 30 Apr 2022 13:53:58 -0400 Received: by mail-pl1-x635.google.com with SMTP id n14so2721606plf.3 for ; Sat, 30 Apr 2022 10:53:55 -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=8VjWHa4+EEAsb2rxF9krBBAxcFamsv8YuijfZ6HxZ44=; b=yuurYXXgMZ3znhmT+9XI7ISihB5SlP784UloyulyQCAL7Xcf4lRpLH5nErKZApL/CZ 8SNOyFC33PzQFjgODNBDMv6ZmMs7sVhAel/zjvq5Yv9Z96Lad3x0NXylkTguPFEvgE2u rnfi0A0UMNxnb+4g2svLct+lHA5HIruxg0HXtE/h7JZ9pCrtk2fK5YOXI6bZZqvUiDH1 Gjqq2sPUbAE60MmSCuSG3P4l8G2ubdQ61bx4Mwbhlf7QmtBUleL+dyA/+X7GqzFyDDs2 vHCHb0t+Jii68HpfQtYkL7MOshc3CuoPCPy5p6bZX0Cu7ShLCRQeVVfzy8IaM4zb2H5E vavA== 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=8VjWHa4+EEAsb2rxF9krBBAxcFamsv8YuijfZ6HxZ44=; b=yOdOsxjpJr0E+uquCbPMzcUXLVoypl73pX80i5KYomMcaENHne1DMP6lPHzz1SqF+A TMD+gXwC/3pcoW6TDEOGrKUfdE46wwryKt+uuvmu5W+PTbLF9er0CRsQUl/vrQLUfZGx 1i/dqGtH6TmvxpA0vpl1XQ+5CnPPBxhBHLjquyVtku7+LR6Ccaupy6Nppg/gwHE+JLbj FhzKyyMfY+h3v6TF+wT+zPuQii1VA+GKqloMReBS7G524H1KR7ZdFmRkOtKs2Ex+C3MO Jro/THGjl3WDV6a3gWRCZcMe3/F1156gtcP5gquOLjLT6lxsIZfVL9u6YBit5I8LEayf TOcA== X-Gm-Message-State: AOAM532r4ronrjUyCvA/2AsZi4a0WYOPJ3PiFKvfQ/DeaYNmZXvkPaT/ pQpHj6UDQDtkMS91TfVwkcb9VkXI/R6RFA== X-Received: by 2002:a17:902:c941:b0:15d:37b0:2d26 with SMTP id i1-20020a170902c94100b0015d37b02d26mr4565192pla.67.1651341234865; Sat, 30 Apr 2022 10:53:54 -0700 (PDT) Received: from stoup.. ([71.212.142.129]) by smtp.gmail.com with ESMTPSA id 5-20020a170902c20500b0015e8d4eb282sm1740910pll.204.2022.04.30.10.53.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 30 Apr 2022 10:53:54 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH v4 12/17] target/m68k: Implement TRAPV Date: Sat, 30 Apr 2022 10:53:37 -0700 Message-Id: <20220430175342.370628-13-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220430175342.370628-1-richard.henderson@linaro.org> References: <20220430175342.370628-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::635; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x635.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: laurent@vivier.eu Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Richard Henderson Reviewed-by: Laurent Vivier --- target/m68k/translate.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index bb5ed1b7b1..0cd7ef89e3 100644 --- a/target/m68k/translate.c +++ b/target/m68k/translate.c @@ -4911,6 +4911,14 @@ DISAS_INSN(trapcc) do_trapcc(s, &c); } +DISAS_INSN(trapv) +{ + DisasCompare c; + + gen_cc_cond(&c, s, 9); /* V set */ + do_trapcc(s, &c); +} + static void gen_load_fcr(DisasContext *s, TCGv res, int reg) { switch (reg) { @@ -6074,6 +6082,7 @@ void register_m68k_insns (CPUM68KState *env) BASE(nop, 4e71, ffff); INSN(rtd, 4e74, ffff, RTD); BASE(rts, 4e75, ffff); + INSN(trapv, 4e76, ffff, M68000); INSN(rtr, 4e77, ffff, M68000); BASE(jump, 4e80, ffc0); BASE(jump, 4ec0, ffc0);