Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/1.2/patches/811257/?format=api
{ "id": 811257, "url": "http://patchwork.ozlabs.org/api/1.2/patches/811257/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20170907224051.21518-24-richard.henderson@linaro.org/", "project": { "id": 14, "url": "http://patchwork.ozlabs.org/api/1.2/projects/14/?format=api", "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": "<20170907224051.21518-24-richard.henderson@linaro.org>", "list_archive_url": null, "date": "2017-09-07T22:40:51", "name": "[PULL,23/23] tcg/ppc: Use constant pool for movi", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "bc937ee0bdbd4e3637a47713ddaa4e4a30173a7a", "submitter": { "id": 72104, "url": "http://patchwork.ozlabs.org/api/1.2/people/72104/?format=api", "name": "Richard Henderson", "email": "richard.henderson@linaro.org" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20170907224051.21518-24-richard.henderson@linaro.org/mbox/", "series": [ { "id": 2073, "url": "http://patchwork.ozlabs.org/api/1.2/series/2073/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=2073", "date": "2017-09-07T22:40:28", "name": "[PULL,01/23] tcg: Move USE_DIRECT_JUMP discriminator to tcg/cpu/tcg-target.h", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/2073/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/811257/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/811257/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=\"KMfepWU1\"; 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 3xpG3p35dQz9rxl\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 8 Sep 2017 08:54:30 +1000 (AEST)", "from localhost ([::1]:42567 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 1dq5gq-0005X3-FZ\n\tfor incoming@patchwork.ozlabs.org; Thu, 07 Sep 2017 18:54:28 -0400", "from eggs.gnu.org ([2001:4830:134:3::10]:52413)\n\tby lists.gnu.org with esmtp (Exim 4.71)\n\t(envelope-from <richard.henderson@linaro.org>) id 1dq5UK-0003JO-NQ\n\tfor qemu-devel@nongnu.org; Thu, 07 Sep 2017 18:41:37 -0400", "from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)\n\t(envelope-from <richard.henderson@linaro.org>) id 1dq5UG-0008TD-3w\n\tfor qemu-devel@nongnu.org; Thu, 07 Sep 2017 18:41:32 -0400", "from mail-pf0-x22e.google.com ([2607:f8b0:400e:c00::22e]:35371)\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 1dq5UF-0008RY-Ug\n\tfor qemu-devel@nongnu.org; Thu, 07 Sep 2017 18:41:28 -0400", "by mail-pf0-x22e.google.com with SMTP id g13so1630320pfm.2\n\tfor <qemu-devel@nongnu.org>; Thu, 07 Sep 2017 15:41:27 -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\th19sm770678pfh.142.2017.09.07.15.41.25\n\t(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);\n\tThu, 07 Sep 2017 15:41:25 -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\tbh=H+LLtzCzH8QndIjCRi1FVfoNlieFGUHJ+Q0JqTEk1F0=;\n\tb=KMfepWU1BTFsCzpiWSnTJDsNNF9XY8dKxpBTharm/iIT8MtltxGTkj65GxVIjyp2Mi\n\tUulfwoC3NDp8NeO+BwTl7oahTZ0ZrB8jDuglZ/28r+hOnu1jxZ77Lx+2DdAegF0AJhOy\n\tUlbyISnU8+SsH2VFZDfdlkpofR3XGk60wm5wM=", "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;\n\tbh=H+LLtzCzH8QndIjCRi1FVfoNlieFGUHJ+Q0JqTEk1F0=;\n\tb=Wv39fhSxtgf4ti3wo0E/ZOvpXiVc8IHRs489cvOMsHHyMxqWGiwem1zRY4QZxTDJRx\n\toXfDNYR1D+tIhLzGXjVvPS/nY5NhXt5Em/PjYJWQ2eNkH95+bu0bUglks/Gnh2QUOSnt\n\tCYprO4OEAzGpUyQe+V6gCVwsEslQJ2S2fTyBBzW3zPhR9m0pukOgULyl3LA88cSQEtHe\n\tq3LUQokD0UxOsaAZnsLYudJjqheaZ+ZsvlbyPANJOKwFYylwdxdqnjviLB/7WE2ogif/\n\tQiXlJJ18DktlFpdHL4I9OwuY21O2RbnINzw/nq90yI/XuU1oFjkjqcekBUVSCy0D53Am\n\tA6qQ==", "X-Gm-Message-State": "AHPjjUiVV6P/JMXcLytgcDB8fdjlUbO0f4TelamjsG2MfNMFieY9p96e\n\tc1RFpyn7NeB37+VOzq8zUA==", "X-Google-Smtp-Source": "ADKCNb580RProykv/FtOjQxwThKgfLAMc9hggbh/lJjN2aIJe2BcNjzz7mlm8RCzdsxi2b79CxpXMA==", "X-Received": "by 10.99.130.198 with SMTP id w189mr919111pgd.175.1504824086701; \n\tThu, 07 Sep 2017 15:41:26 -0700 (PDT)", "From": "Richard Henderson <richard.henderson@linaro.org>", "To": "qemu-devel@nongnu.org", "Date": "Thu, 7 Sep 2017 15:40:51 -0700", "Message-Id": "<20170907224051.21518-24-richard.henderson@linaro.org>", "X-Mailer": "git-send-email 2.13.5", "In-Reply-To": "<20170907224051.21518-1-richard.henderson@linaro.org>", "References": "<20170907224051.21518-1-richard.henderson@linaro.org>", "X-detected-operating-system": "by eggs.gnu.org: Genre and OS details not\n\trecognized.", "X-Received-From": "2607:f8b0:400e:c00::22e", "Subject": "[Qemu-devel] [PULL 23/23] tcg/ppc: Use constant pool for movi", "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\nSigned-off-by: Richard Henderson <rth@twiddle.net>\n---\n tcg/ppc/tcg-target.h | 1 +\n tcg/ppc/tcg-target.inc.c | 34 ++++++++++++++++++++++++++++++----\n 2 files changed, 31 insertions(+), 4 deletions(-)", "diff": "diff --git a/tcg/ppc/tcg-target.h b/tcg/ppc/tcg-target.h\nindex 3772cc6648..be52ad1d2e 100644\n--- a/tcg/ppc/tcg-target.h\n+++ b/tcg/ppc/tcg-target.h\n@@ -132,5 +132,6 @@ void tb_target_set_jmp_target(uintptr_t, uintptr_t, uintptr_t);\n #ifdef CONFIG_SOFTMMU\n #define TCG_TARGET_NEED_LDST_LABELS\n #endif\n+#define TCG_TARGET_NEED_POOL_LABELS\n \n #endif\ndiff --git a/tcg/ppc/tcg-target.inc.c b/tcg/ppc/tcg-target.inc.c\nindex df709c4a96..21d764c102 100644\n--- a/tcg/ppc/tcg-target.inc.c\n+++ b/tcg/ppc/tcg-target.inc.c\n@@ -22,6 +22,9 @@\n * THE SOFTWARE.\n */\n \n+#include \"elf.h\"\n+#include \"tcg-pool.inc.c\"\n+\n #if defined _CALL_DARWIN || defined __APPLE__\n #define TCG_TARGET_CALL_DARWIN\n #endif\n@@ -58,8 +61,6 @@\n \n static tcg_insn_unit *tb_ret_addr;\n \n-#include \"elf.h\"\n-\n bool have_isa_2_06;\n bool have_isa_3_00;\n \n@@ -224,9 +225,12 @@ static inline void tcg_out_bc_noaddr(TCGContext *s, int insn)\n static void patch_reloc(tcg_insn_unit *code_ptr, int type,\n intptr_t value, intptr_t addend)\n {\n- tcg_insn_unit *target = (tcg_insn_unit *)value;\n+ tcg_insn_unit *target;\n+ tcg_insn_unit old;\n+\n+ value += addend;\n+ target = (tcg_insn_unit *)value;\n \n- tcg_debug_assert(addend == 0);\n switch (type) {\n case R_PPC_REL14:\n reloc_pc14(code_ptr, target);\n@@ -234,6 +238,12 @@ static void patch_reloc(tcg_insn_unit *code_ptr, int type,\n case R_PPC_REL24:\n reloc_pc24(code_ptr, target);\n break;\n+ case R_PPC_ADDR16:\n+ assert(value == (int16_t)value);\n+ old = *code_ptr;\n+ old = deposit32(old, 0, 16, value);\n+ *code_ptr = old;\n+ break;\n default:\n tcg_abort();\n }\n@@ -676,6 +686,14 @@ static void tcg_out_movi_int(TCGContext *s, TCGType type, TCGReg ret,\n return;\n }\n \n+ /* Use the constant pool, if possible. */\n+ if (!in_prologue && USE_REG_TB) {\n+ new_pool_label(s, arg, R_PPC_ADDR16, s->code_ptr,\n+ -(intptr_t)s->code_gen_ptr);\n+ tcg_out32(s, LD | TAI(ret, TCG_REG_TB, 0));\n+ return;\n+ }\n+\n tmp = arg >> 31 >> 1;\n tcg_out_movi(s, TCG_TYPE_I32, ret, tmp);\n if (tmp) {\n@@ -1858,6 +1876,14 @@ static void tcg_out_qemu_st(TCGContext *s, const TCGArg *args, bool is_64)\n #endif\n }\n \n+static void tcg_out_nop_fill(tcg_insn_unit *p, int count)\n+{\n+ int i;\n+ for (i = 0; i < count; ++i) {\n+ p[i] = NOP;\n+ }\n+}\n+\n /* Parameters for function call generation, used in tcg.c. */\n #define TCG_TARGET_STACK_ALIGN 16\n #define TCG_TARGET_EXTEND_ARGS 1\n", "prefixes": [ "PULL", "23/23" ] }