get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/2232088/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 2232088,
    "url": "http://patchwork.ozlabs.org/api/patches/2232088/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/gcc/patch/20260502144900.3752411-1-xry111@xry111.site/",
    "project": {
        "id": 17,
        "url": "http://patchwork.ozlabs.org/api/projects/17/?format=api",
        "name": "GNU Compiler Collection",
        "link_name": "gcc",
        "list_id": "gcc-patches.gcc.gnu.org",
        "list_email": "gcc-patches@gcc.gnu.org",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20260502144900.3752411-1-xry111@xry111.site>",
    "list_archive_url": null,
    "date": "2026-05-02T14:48:12",
    "name": "LoongArch: Allow printing symbolic name with \"%c\" in inline asm",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "6cbfdd563a48c76d86dd164eb01fda9f9dd70443",
    "submitter": {
        "id": 84026,
        "url": "http://patchwork.ozlabs.org/api/people/84026/?format=api",
        "name": "Xi Ruoyao",
        "email": "xry111@xry111.site"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/gcc/patch/20260502144900.3752411-1-xry111@xry111.site/mbox/",
    "series": [
        {
            "id": 502535,
            "url": "http://patchwork.ozlabs.org/api/series/502535/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/gcc/list/?series=502535",
            "date": "2026-05-02T14:48:12",
            "name": "LoongArch: Allow printing symbolic name with \"%c\" in inline asm",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/502535/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2232088/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2232088/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "gcc-patches@gcc.gnu.org"
        ],
        "Delivered-To": [
            "patchwork-incoming@legolas.ozlabs.org",
            "gcc-patches@gcc.gnu.org"
        ],
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=xry111.site header.i=@xry111.site header.a=rsa-sha256\n header.s=default header.b=RNG2Nvvn;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org\n (client-ip=2620:52:6:3111::32; helo=vm01.sourceware.org;\n envelope-from=gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org;\n receiver=patchwork.ozlabs.org)",
            "sourceware.org;\n\tdkim=pass (1024-bit key,\n unprotected) header.d=xry111.site header.i=@xry111.site header.a=rsa-sha256\n header.s=default header.b=RNG2Nvvn",
            "sourceware.org;\n dmarc=pass (p=reject dis=none) header.from=xry111.site",
            "sourceware.org; spf=pass smtp.mailfrom=xry111.site",
            "server2.sourceware.org;\n arc=none smtp.remote-ip=89.208.246.23"
        ],
        "Received": [
            "from vm01.sourceware.org (vm01.sourceware.org\n [IPv6:2620:52:6:3111::32])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g79n61PbXz1yJ0\n\tfor <incoming@patchwork.ozlabs.org>; Sun, 03 May 2026 00:50:18 +1000 (AEST)",
            "from vm01.sourceware.org (localhost [127.0.0.1])\n\tby sourceware.org (Postfix) with ESMTP id 5BBA94BB3BA8\n\tfor <incoming@patchwork.ozlabs.org>; Sat,  2 May 2026 14:50:16 +0000 (GMT)",
            "from xry111.site (xry111.site [89.208.246.23])\n by sourceware.org (Postfix) with ESMTPS id D773E4BABF16\n for <gcc-patches@gcc.gnu.org>; Sat,  2 May 2026 14:49:50 +0000 (GMT)",
            "from stargazer (unknown\n [IPv6:2409:8a4c:e1c:abf0:bb72:8d18:d3cb:9175])\n (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n (Client did not present a certificate)\n (Authenticated sender: xry111@xry111.site)\n by xry111.site (Postfix) with ESMTPSA id 4833765992;\n Sat,  2 May 2026 10:49:15 -0400 (EDT)"
        ],
        "DKIM-Filter": [
            "OpenDKIM Filter v2.11.0 sourceware.org 5BBA94BB3BA8",
            "OpenDKIM Filter v2.11.0 sourceware.org D773E4BABF16"
        ],
        "DMARC-Filter": "OpenDMARC Filter v1.4.2 sourceware.org D773E4BABF16",
        "ARC-Filter": "OpenARC Filter v1.0.0 sourceware.org D773E4BABF16",
        "ARC-Seal": "i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1777733391; cv=none;\n b=Gtm6Lwea4a+T0l+B0KvOJM4Nxc8znxnS5TlVI0mQkRLT1p2v+AkHDC4CX5JGNdLX2nq6Nu2JZ/ac/qjuCjbxLzpKopEnB4VMh0vCrWVn+vd3R+k3Ez3e1ODC5sPXPNr2mD6DYVA+GF+gQLGnRf3ymv6vKsTMHL7LvdgDpkRHSXc=",
        "ARC-Message-Signature": "i=1; a=rsa-sha256; d=sourceware.org; s=key;\n t=1777733391; c=relaxed/simple;\n bh=dFHlnq3A4mxzysLA29OK6wjF+/1ITws4pIU9h4d8XcU=;\n h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version;\n b=VMKPX5Hrf6MB0YRYW0jYizl4bJ1wUwDlhymATo6Wd2qbXDbyMNqw3VqkFGmt1pP+OZ5uqfAERNs6t4sJBzRYPBDy+dMVzYLhYiZZoHgye8DkFf/0fcJxGpkOOKs0INUQYx/taFSCtQQJc1/+qLz/5KKPQSQ8bnNsfZIj4fgx/+o=",
        "ARC-Authentication-Results": "i=1; server2.sourceware.org",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=xry111.site;\n s=default; t=1777733359;\n bh=t5V4+U5JsvwoZ1ivASZFFqPZE4Hee7xjNuNd+d6Rvdw=;\n h=From:To:Cc:Subject:Date:From;\n b=RNG2Nvvnolga4YaP+Phptj4mdET00BY6HUlX7Omvb1ubwtdFg8RmocQM1UeR+tHiJ\n f7ttqYPT2E8FXj6r72GDBZ7Js2uaaJjITov8MB4qqTR0X1R7cGxHmlIqFK+uEIbj0t\n aiItAGmymGAUSMLigyiSZQ5gcViUooeSxgJKk/4c=",
        "From": "Xi Ruoyao <xry111@xry111.site>",
        "To": "gcc-patches@gcc.gnu.org",
        "Cc": "Lulu Cheng <chenglulu@loongson.cn>, WANG Xuerui <i@xen0n.name>,\n Mingcong Bai <jeffbai@aosc.io>, Zixing Liu <liushuyu@aosc.io>,\n Xi Ruoyao <xry111@xry111.site>",
        "Subject": "[PATCH] LoongArch: Allow printing symbolic name with \"%c\" in inline\n asm",
        "Date": "Sat,  2 May 2026 22:48:12 +0800",
        "Message-ID": "<20260502144900.3752411-1-xry111@xry111.site>",
        "X-Mailer": "git-send-email 2.54.0",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-BeenThere": "gcc-patches@gcc.gnu.org",
        "X-Mailman-Version": "2.1.30",
        "Precedence": "list",
        "List-Id": "Gcc-patches mailing list <gcc-patches.gcc.gnu.org>",
        "List-Unsubscribe": "<https://gcc.gnu.org/mailman/options/gcc-patches>,\n <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe>",
        "List-Archive": "<https://gcc.gnu.org/pipermail/gcc-patches/>",
        "List-Post": "<mailto:gcc-patches@gcc.gnu.org>",
        "List-Help": "<mailto:gcc-patches-request@gcc.gnu.org?subject=help>",
        "List-Subscribe": "<https://gcc.gnu.org/mailman/listinfo/gcc-patches>,\n <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe>",
        "Errors-To": "gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org"
    },
    "content": "The gcc.dg/ipa/pr122458.c test relies on this.  The doc says \"%c\" is\nfor \"constant operand\" and I think there's no harm to consider symbolic\nname a constant operand.\n\ngcc/\n\n\t* config/loongarch/loongarch.cc (loongarch_print_operand): Print\n\tthe symbol name for SYMBOL_REF with %c.\n---\n\nBootstrapped and regtested on loongarch64-linux-gnu.  Ok for trunk and\n16.2 (as pr122458.c is already in gcc-16)?\n\n gcc/config/loongarch/loongarch.cc | 4 +++-\n 1 file changed, 3 insertions(+), 1 deletion(-)",
    "diff": "diff --git a/gcc/config/loongarch/loongarch.cc b/gcc/config/loongarch/loongarch.cc\nindex bdafcd5c539..aa9bd9c0f93 100644\n--- a/gcc/config/loongarch/loongarch.cc\n+++ b/gcc/config/loongarch/loongarch.cc\n@@ -6722,7 +6722,9 @@ loongarch_print_operand (FILE *file, rtx op, int letter)\n \n \n     case 'c':\n-      if (CONST_INT_P (op))\n+      if (SYMBOL_REF_P (op))\n+\toutput_addr_const (asm_out_file, op);\n+      else if (CONST_INT_P (op))\n \tfprintf (file, HOST_WIDE_INT_PRINT_DEC, INTVAL (op));\n       else\n \toutput_operand_lossage (\"unsupported operand for code '%c'\", letter);\n",
    "prefixes": []
}