public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: 钟居哲 <juzhe.zhong@rivai.ai>
To: gcc-patches <gcc-patches@gcc.gnu.org>
Cc: kito.cheng <kito.cheng@gmail.com>
Subject: Re: [PATCH] RISC-V: move struct vector_type_info from *.h to *.cc.
Date: Mon, 10 Oct 2022 22:00:24 +0800	[thread overview]
Message-ID: <B332E177E725CE5B+202210102200241443228@rivai.ai> (raw)
In-Reply-To: <20221010134928.171673-1-juzhe.zhong@rivai.ai>

[-- Attachment #1: Type: text/plain, Size: 2812 bytes --]

Ignore this patch plz. It's not finished.
The correct && full patch is this:
https://gcc.gnu.org/pipermail/gcc-patches/2022-October/603148.html 
Thanks.



juzhe.zhong@rivai.ai
 
From: juzhe.zhong
Date: 2022-10-10 21:49
To: gcc-patches
CC: kito.cheng; Ju-Zhe Zhong
Subject: [PATCH] RISC-V: move struct vector_type_info from *.h to *.cc.
From: Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
 
gcc/ChangeLog:
 
        * config/riscv/riscv-vector-builtins.cc (struct vector_type_info): Move from riscv-vector-builtins.h.
        * config/riscv/riscv-vector-builtins.h (struct vector_type_info): Move to riscv-vector-builtins.cc.
 
---
gcc/config/riscv/riscv-vector-builtins.cc | 16 ++++++++++++++++
gcc/config/riscv/riscv-vector-builtins.h  | 16 ----------------
2 files changed, 16 insertions(+), 16 deletions(-)
 
diff --git a/gcc/config/riscv/riscv-vector-builtins.cc b/gcc/config/riscv/riscv-vector-builtins.cc
index 0096e32f5e4..d7b567a7ba1 100644
--- a/gcc/config/riscv/riscv-vector-builtins.cc
+++ b/gcc/config/riscv/riscv-vector-builtins.cc
@@ -50,6 +50,22 @@ using namespace riscv_vector;
namespace riscv_vector {
+/* Static information about each vector type.  */
+struct vector_type_info
+{
+  /* The name of the type as declared by riscv_vector.h
+     which is recommend to use. For example: 'vint32m1_t'.  */
+  const char *name;
+
+  /* ABI name of vector type. The type is always available
+     under this name, even when riscv_vector.h isn't included.
+     For example:  '__rvv_int32m1_t'.  */
+  const char *abi_name;
+
+  /* The C++ mangling of ABI_NAME.  */
+  const char *mangled_name;
+};
+
/* Information about each RVV type.  */
static CONSTEXPR const vector_type_info vector_types[] = {
#define DEF_RVV_TYPE(USER_NAME, NCHARS, ABI_NAME, ARGS...)    \
diff --git a/gcc/config/riscv/riscv-vector-builtins.h b/gcc/config/riscv/riscv-vector-builtins.h
index 6ca0b073964..524fb0b02c2 100644
--- a/gcc/config/riscv/riscv-vector-builtins.h
+++ b/gcc/config/riscv/riscv-vector-builtins.h
@@ -26,22 +26,6 @@ namespace riscv_vector {
/* This is for segment instructions.  */
const unsigned int MAX_TUPLE_SIZE = 8;
-/* Static information about each vector type.  */
-struct vector_type_info
-{
-  /* The name of the type as declared by riscv_vector.h
-     which is recommend to use. For example: 'vint32m1_t'.  */
-  const char *user_name;
-
-  /* ABI name of vector type. The type is always available
-     under this name, even when riscv_vector.h isn't included.
-     For example:  '__rvv_int32m1_t'.  */
-  const char *abi_name;
-
-  /* The C++ mangling of ABI_NAME.  */
-  const char *mangled_name;
-};
-
/* Enumerates the RVV types, together called
    "vector types" for brevity.  */
enum vector_type_index
-- 
2.36.1
 

      reply	other threads:[~2022-10-10 14:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-10 13:49 juzhe.zhong
2022-10-10 14:00 ` 钟居哲 [this message]

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=B332E177E725CE5B+202210102200241443228@rivai.ai \
    --to=juzhe.zhong@rivai.ai \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=kito.cheng@gmail.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).