From: Kito Cheng <kito.cheng@sifive.com>
To: gcc-patches@gcc.gnu.org, kito.cheng@gmail.com,
jim.wilson.gcc@gmail.com, palmer@dabbelt.com, andrew@sifive.com,
jeffreyalaw@gmail.com, christoph.muellner@vrull.eu
Cc: Kito Cheng <kito.cheng@sifive.com>
Subject: [PATCH 5/5] RISC-V: Document the syntax of -march
Date: Mon, 8 Jan 2024 21:47:38 +0800 [thread overview]
Message-ID: <20240108134738.998804-6-kito.cheng@sifive.com> (raw)
In-Reply-To: <20240108134738.998804-1-kito.cheng@sifive.com>
---
gcc/doc/invoke.texi | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index 68d1f364ac0..81ee7ac758a 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -30037,6 +30037,22 @@ Generate code for given RISC-V ISA (e.g.@: @samp{rv64im}). ISA strings must be
lower-case. Examples include @samp{rv64i}, @samp{rv32g}, @samp{rv32e}, and
@samp{rv32imaf}.
+The syntax of the ISA string is defined as follows:
+
+@table @code
+@item The string must start with @samp{rv32} or @samp{rv64}, followed by
+@samp{i}, @samp{e}, or @samp{g}, referred to as the base ISA.
+@item The subsequent part of the string is a list of extension names. Extension
+names can be categorized as multi-letter (e.g.@: @samp{zba}) and single-letter
+(e.g.@: @samp{v}). Single-letter extensions can appear consecutively,
+but multi-letter extensions must be separated by underscores.
+@item An underscore can appear anywhere after the base ISA. It has no specific
+effect but is used to improve readability and can act as a separator.
+@item Extension names may include an optional version number, following the
+syntax @samp{<major>p<minor>} or @samp{<major>}, (e.g.@: @samp{m2p1} or
+@samp{m2}).
+@end table
+
When @option{-march=} is not specified, use the setting from @option{-mcpu}.
If both @option{-march} and @option{-mcpu=} are not specified, the default for
--
2.34.1
next prev parent reply other threads:[~2024-01-08 13:48 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-08 13:47 [PATCH 0/5] RISC-V: Relax the -march string for accept any order Kito Cheng
2024-01-08 13:47 ` [PATCH 1/5] RISC-V: Extract part parsing base ISA logic into a standalone function [NFC] Kito Cheng
2024-01-08 13:47 ` [PATCH 2/5] RISC-V: Relax the -march string for accept any order Kito Cheng
2024-01-08 13:47 ` [PATCH 3/5] RISC-V: Remove unused function in riscv_subset_list [NFC] Kito Cheng
2024-01-08 13:47 ` [PATCH 4/5] RISC-V: Update testsuite due to -march string relaxation Kito Cheng
2024-01-08 13:47 ` Kito Cheng [this message]
2024-01-09 18:31 ` [PATCH 0/5] RISC-V: Relax the -march string for accept any order Jeff Law
2024-01-10 0:58 ` Kito Cheng
2024-01-10 1:38 ` Fangrui Song
2024-01-16 14:33 ` Jeff Law
2024-01-19 7:20 ` Kito Cheng
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240108134738.998804-6-kito.cheng@sifive.com \
--to=kito.cheng@sifive.com \
--cc=andrew@sifive.com \
--cc=christoph.muellner@vrull.eu \
--cc=gcc-patches@gcc.gnu.org \
--cc=jeffreyalaw@gmail.com \
--cc=jim.wilson.gcc@gmail.com \
--cc=kito.cheng@gmail.com \
--cc=palmer@dabbelt.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).