From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yb1-xb36.google.com (mail-yb1-xb36.google.com [IPv6:2607:f8b0:4864:20::b36]) by sourceware.org (Postfix) with ESMTPS id E0BC73894C38 for ; Tue, 13 Jul 2021 06:11:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org E0BC73894C38 Received: by mail-yb1-xb36.google.com with SMTP id r135so33085825ybc.0 for ; Mon, 12 Jul 2021 23:11:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=vHobaNKoN4rWGcgM0xqD3WetBL95KrYF9gxwZ/tZgCU=; b=g32JMex87RoPDqKlhIAF0NCB3yCGRqMzkNWQyJ3WBFJ2c1Q7DYbqomk31LkBbH2dIZ Ms6jEmDXclLE8VbYuTZJIVxssl5GOGyfdc9zcCJkBfLjqsle1rgGh84woy2Q2DB1x5Ih eW792OYq+Mkvy5MBh1RDm8V+WD1w+OzzOyz5oP6YPwqYixrt9IGTFW88+iOpuvJcp/h1 qpH3eSnqvRTdwrGReYrbLPn0l2QRMUkhnmUsdUHShGnnHfxRnlNg68JnicW4990ez4eB 9Gzh19sdyXuwpp2d7lMxl/WgId0mAYUFytfc/Xf2b1MK3q1+Tu6DI1M6mBIqro30q/iQ tWkw== X-Gm-Message-State: AOAM53321SKDzK1mymtsMBonF/iiqqD51xEsllv+c8NJYOCtP8SsvwMO lxNtmXNbXjruDI4p3bKjVQa2+dsLDdR/xplH7QU= X-Google-Smtp-Source: ABdhPJzNA44qWeRxoDbjKwwMLqqGGeodjPG+yZ9FVVLFgvtT4nLyDabfrixaBForynk0iWCWAmGSJFux7ugUfeWLHMY= X-Received: by 2002:a25:c085:: with SMTP id c127mr3708686ybf.506.1626156687273; Mon, 12 Jul 2021 23:11:27 -0700 (PDT) MIME-Version: 1.0 References: <20210712042913.93981-1-kito.cheng@sifive.com> <20210712044745.uwngjcw7cbmruww6@gmail.com> In-Reply-To: <20210712044745.uwngjcw7cbmruww6@gmail.com> From: Kito Cheng Date: Tue, 13 Jul 2021 14:11:16 +0800 Message-ID: Subject: Re: [PATCH v2] docs: Add 'S' to Machine Constraints for RISC-V To: Fangrui Song Cc: Kito Cheng , GCC Patches Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-6.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Jul 2021 06:11:29 -0000 committed to trunk. On Mon, Jul 12, 2021 at 12:48 PM Fangrui Song wrote: > > On 2021-07-12, Kito Cheng wrote: > >It was undocument before, but it might used in linux kernel for resolve > >code model issue, so LLVM community suggest we should document that, > >so that make it become supported/documented/non-internal machine constraints. > > > >gcc/ChangeLog: > > > > PR target/101275 > > * config/riscv/constraints.md ("S"): Update description and remove > > @internal. > > * doc/md.texi (Machine Constraints): Document the 'S' constraints > > for RISC-V. > >--- > > gcc/config/riscv/constraints.md | 3 +-- > > gcc/doc/md.texi | 3 +++ > > 2 files changed, 4 insertions(+), 2 deletions(-) > > > >diff --git a/gcc/config/riscv/constraints.md b/gcc/config/riscv/constraints.md > >index 8c15c6c0486..c87d5b796a5 100644 > >--- a/gcc/config/riscv/constraints.md > >+++ b/gcc/config/riscv/constraints.md > >@@ -67,8 +67,7 @@ (define_memory_constraint "A" > > (match_test "GET_CODE(XEXP(op,0)) == REG"))) > > > > (define_constraint "S" > >- "@internal > >- A constant call address." > >+ "A constraint that matches an absolute symbolic address." > > (match_operand 0 "absolute_symbolic_operand")) > > > > (define_constraint "U" > >diff --git a/gcc/doc/md.texi b/gcc/doc/md.texi > >index 00caf3844cc..2d120da96cf 100644 > >--- a/gcc/doc/md.texi > >+++ b/gcc/doc/md.texi > >@@ -3536,6 +3536,9 @@ A 5-bit unsigned immediate for CSR access instructions. > > @item A > > An address that is held in a general-purpose register. > > > >+@item S > >+A constraint that matches an absolute symbolic address. > >+ > > @end table > > > > @item RX---@file{config/rx/constraints.md} > >-- > >2.31.1 > > LGTM