{"id":810726,"url":"http://patchwork.ozlabs.org/api/1.2/patches/810726/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/patch/20170906160612.22769-31-richard.henderson@linaro.org/","project":{"id":14,"url":"http://patchwork.ozlabs.org/api/1.2/projects/14/?format=json","name":"QEMU Development","link_name":"qemu-devel","list_id":"qemu-devel.nongnu.org","list_email":"qemu-devel@nongnu.org","web_url":"","scm_url":"","webscm_url":"","list_archive_url":"","list_archive_url_format":"","commit_url_format":""},"msgid":"<20170906160612.22769-31-richard.henderson@linaro.org>","list_archive_url":null,"date":"2017-09-06T16:06:10","name":"[PULL,30/32] target/arm: Move ss check to init_disas_context","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"019717cadefa4983b6ddba6b60386f612f686f06","submitter":{"id":72104,"url":"http://patchwork.ozlabs.org/api/1.2/people/72104/?format=json","name":"Richard Henderson","email":"richard.henderson@linaro.org"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/qemu-devel/patch/20170906160612.22769-31-richard.henderson@linaro.org/mbox/","series":[{"id":1847,"url":"http://patchwork.ozlabs.org/api/1.2/series/1847/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/list/?series=1847","date":"2017-09-06T16:05:41","name":"[PULL,01/32] tcg: Add generic DISAS_NORETURN","version":1,"mbox":"http://patchwork.ozlabs.org/series/1847/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/810726/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/810726/checks/","tags":{},"related":[],"headers":{"Return-Path":"<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":["ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=nongnu.org\n\t(client-ip=2001:4830:134:3::11; helo=lists.gnu.org;\n\tenvelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n\treceiver=<UNKNOWN>)","ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=linaro.org header.i=@linaro.org\n\theader.b=\"Kic5+E7N\"; dkim-atps=neutral"],"Received":["from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11])\n\t(using TLSv1 with cipher AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3xnTmc1nqrz9s9Y\n\tfor <incoming@patchwork.ozlabs.org>;\n\tThu,  7 Sep 2017 02:38:40 +1000 (AEST)","from localhost ([::1]:37104 helo=lists.gnu.org)\n\tby lists.gnu.org with esmtp (Exim 4.71) (envelope-from\n\t<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>)\n\tid 1dpdLa-0001He-5k\n\tfor incoming@patchwork.ozlabs.org; Wed, 06 Sep 2017 12:38:38 -0400","from eggs.gnu.org ([2001:4830:134:3::10]:42041)\n\tby lists.gnu.org with esmtp (Exim 4.71)\n\t(envelope-from <richard.henderson@linaro.org>) id 1dpcqy-0000bM-Oq\n\tfor qemu-devel@nongnu.org; Wed, 06 Sep 2017 12:07:08 -0400","from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)\n\t(envelope-from <richard.henderson@linaro.org>) id 1dpcqu-00037Y-02\n\tfor qemu-devel@nongnu.org; Wed, 06 Sep 2017 12:07:00 -0400","from mail-pf0-x22a.google.com ([2607:f8b0:400e:c00::22a]:34785)\n\tby eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)\n\t(Exim 4.71) (envelope-from <richard.henderson@linaro.org>)\n\tid 1dpcqt-00032z-Pc\n\tfor qemu-devel@nongnu.org; Wed, 06 Sep 2017 12:06:55 -0400","by mail-pf0-x22a.google.com with SMTP id m1so13486478pfk.1\n\tfor <qemu-devel@nongnu.org>; Wed, 06 Sep 2017 09:06:55 -0700 (PDT)","from bigtime.twiddle.net (97-126-108-236.tukw.qwest.net.\n\t[97.126.108.236]) by smtp.gmail.com with ESMTPSA id\n\tt65sm262863pfk.59.2017.09.06.09.06.53\n\t(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);\n\tWed, 06 Sep 2017 09:06:53 -0700 (PDT)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references\n\t:mime-version:content-transfer-encoding;\n\tbh=FaKvXHHGiYR75jbxerCmzlpe42rCvutIo5e8u1b0PMw=;\n\tb=Kic5+E7N7vpQER4GVCBTf0GZvBmRq4YrkTVLov5upn1+R2IyNEMYA2Qyt0gGn/FYtz\n\tfkAxmJRyD4gs66YqfqIIyTz9wA2L7yeZ5OtxhjqThbUpxzLbt1etouzaBL1wMIMm7nxJ\n\tehk8NJ3EW93uxweCixsp4BNSG0Dnt+jaidMdI=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references:mime-version:content-transfer-encoding;\n\tbh=FaKvXHHGiYR75jbxerCmzlpe42rCvutIo5e8u1b0PMw=;\n\tb=qXjxI+EHWbDDwDjbxe9xWKPxj1NzTqyTia0spSEVxjNOsFB1ZNO/TB7x/S0x+Vx7/9\n\tevKSmwFeDuw25A6zV78LhprsvZbj+jhRg0QRktAi3fYPKwrMPL/wfD4SFH6MDAcwFpHb\n\t1K3YPMZUmvXAEzSc5hSuOcYBUY8DbFFQc0fhMbyZb/BdLGgotjLtybZtRPi201/nQ74U\n\tj7XERSH2unn4uV41C6pQUMbM5vBr0lH3DnDF+mI1PhWTp2YQ+2UaT8HWGtPYHnFelZKK\n\tlDjcmKsWBG3zMmZNVrr4EUsTq+4KbeRjefqFbffKfEC2xaLasItGwBpjSvZoHISeb90z\n\t/MKA==","X-Gm-Message-State":"AHPjjUhePp3Pr5CL4IRkqA9tuYbSVvNgAUs4pRQnuHY5loXC3+tQ2n4A\n\tmuG9xLhsFjgxTjCa3RiFJw==","X-Google-Smtp-Source":"ADKCNb5Lorwg+INXciyLUKwAJQXs4kg+VoBPUlKNKso5xHoQ/Of9fIsDxEsBqtX0y+XKbr5Oc+hzPA==","X-Received":"by 10.84.210.45 with SMTP id z42mr8814641plh.178.1504714014598; \n\tWed, 06 Sep 2017 09:06:54 -0700 (PDT)","From":"Richard Henderson <richard.henderson@linaro.org>","To":"qemu-devel@nongnu.org","Date":"Wed,  6 Sep 2017 09:06:10 -0700","Message-Id":"<20170906160612.22769-31-richard.henderson@linaro.org>","X-Mailer":"git-send-email 2.13.5","In-Reply-To":"<20170906160612.22769-1-richard.henderson@linaro.org>","References":"<20170906160612.22769-1-richard.henderson@linaro.org>","MIME-Version":"1.0","Content-Type":"text/plain; charset=UTF-8","Content-Transfer-Encoding":"8bit","X-detected-operating-system":"by eggs.gnu.org: Genre and OS details not\n\trecognized.","X-Received-From":"2607:f8b0:400e:c00::22a","Subject":"[Qemu-devel] [PULL 30/32] target/arm: Move ss check to\n\tinit_disas_context","X-BeenThere":"qemu-devel@nongnu.org","X-Mailman-Version":"2.1.21","Precedence":"list","List-Id":"<qemu-devel.nongnu.org>","List-Unsubscribe":"<https://lists.nongnu.org/mailman/options/qemu-devel>,\n\t<mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>","List-Archive":"<http://lists.nongnu.org/archive/html/qemu-devel/>","List-Post":"<mailto:qemu-devel@nongnu.org>","List-Help":"<mailto:qemu-devel-request@nongnu.org?subject=help>","List-Subscribe":"<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n\t<mailto:qemu-devel-request@nongnu.org?subject=subscribe>","Cc":"peter.maydell@linaro.org, Richard Henderson <rth@twiddle.net>","Errors-To":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org","Sender":"\"Qemu-devel\"\n\t<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>"},"content":"From: Richard Henderson <rth@twiddle.net>\n\nWe can check for single-step just once.\n\nReviewed-by: Emilio G. Cota <cota@braap.org>\nReviewed-by: Lluís Vilanova <vilanova@ac.upc.edu>\nSigned-off-by: Richard Henderson <rth@twiddle.net>\n---\n target/arm/translate.c | 13 ++++++++-----\n 1 file changed, 8 insertions(+), 5 deletions(-)","diff":"diff --git a/target/arm/translate.c b/target/arm/translate.c\nindex dabd5eb89a..0dd24aad90 100644\n--- a/target/arm/translate.c\n+++ b/target/arm/translate.c\n@@ -11883,6 +11883,11 @@ static int arm_tr_init_disas_context(DisasContextBase *dcbase,\n     dc->next_page_start =\n         (dc->base.pc_first & TARGET_PAGE_MASK) + TARGET_PAGE_SIZE;\n \n+    /* If architectural single step active, limit to 1.  */\n+    if (is_singlestepping(dc)) {\n+        max_insns = 1;\n+    }\n+\n     cpu_F0s = tcg_temp_new_i32();\n     cpu_F1s = tcg_temp_new_i32();\n     cpu_F0d = tcg_temp_new_i64();\n@@ -12037,11 +12042,9 @@ static void arm_tr_translate_insn(DisasContextBase *dcbase, CPUState *cpu)\n          * Also stop translation when a page boundary is reached.  This\n          * ensures prefetch aborts occur at the right place.  */\n \n-        if (is_singlestepping(dc)) {\n-            dc->base.is_jmp = DISAS_TOO_MANY;\n-        } else if ((dc->pc >= dc->next_page_start) ||\n-                   ((dc->pc >= dc->next_page_start - 3) &&\n-                    insn_crosses_page(env, dc))) {\n+        if (dc->pc >= dc->next_page_start ||\n+            (dc->pc >= dc->next_page_start - 3 &&\n+             insn_crosses_page(env, dc))) {\n             /* We want to stop the TB if the next insn starts in a new page,\n              * or if it spans between this page and the next. This means that\n              * if we're looking at the last halfword in the page we need to\n","prefixes":["PULL","30/32"]}