https://github.com/4vtomat closed
https://github.com/llvm/llvm-project/pull/77487
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/4vtomat updated
https://github.com/llvm/llvm-project/pull/77487
>From d52f1e4652f7791413c61cfb075755a46fca8cfa Mon Sep 17 00:00:00 2001
From: Brandon Wu
Date: Sun, 7 Jan 2024 18:10:59 -0800
Subject: [PATCH 1/3] [RISCV][clang] Optimize memory usage of intrinsic lookup
table
https://github.com/topperc approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/77487
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/4vtomat updated
https://github.com/llvm/llvm-project/pull/77487
>From 84ea759c43d8e9cb450d95d00fd802be622153a2 Mon Sep 17 00:00:00 2001
From: Brandon Wu
Date: Sun, 7 Jan 2024 18:10:59 -0800
Subject: [PATCH 1/3] [RISCV][clang] Optimize memory usage of intrinsic lookup
table
@@ -464,7 +466,8 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -464,7 +466,8 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -380,14 +380,14 @@ void RISCVIntrinsicManagerImpl::InitRVVIntrinsic(
OverloadedName += "_" + OverloadedSuffixStr.str();
// clang built-in function name, e.g. __builtin_rvv_vadd.
- std::string BuiltinName = "__builtin_rvv_" + std::string(Record.Name);
+ std::string
https://github.com/4vtomat updated
https://github.com/llvm/llvm-project/pull/77487
>From 84ea759c43d8e9cb450d95d00fd802be622153a2 Mon Sep 17 00:00:00 2001
From: Brandon Wu
Date: Sun, 7 Jan 2024 18:10:59 -0800
Subject: [PATCH 1/2] [RISCV][clang] Optimize memory usage of intrinsic lookup
table
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
https://github.com/4vtomat edited
https://github.com/llvm/llvm-project/pull/77487
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
https://github.com/topperc deleted
https://github.com/llvm/llvm-project/pull/77487
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
https://github.com/4vtomat deleted
https://github.com/llvm/llvm-project/pull/77487
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -380,14 +380,14 @@ void RISCVIntrinsicManagerImpl::InitRVVIntrinsic(
OverloadedName += "_" + OverloadedSuffixStr.str();
// clang built-in function name, e.g. __builtin_rvv_vadd.
- std::string BuiltinName = "__builtin_rvv_" + std::string(Record.Name);
+ std::string
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -416,8 +416,10 @@ class RVVIntrinsic {
RVVTypePtr getOutputType() const { return OutputType; }
const RVVTypes () const { return InputTypes; }
llvm::StringRef getBuiltinName() const { return BuiltinName; }
- llvm::StringRef getName() const { return Name; }
-
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -380,14 +380,14 @@ void RISCVIntrinsicManagerImpl::InitRVVIntrinsic(
OverloadedName += "_" + OverloadedSuffixStr.str();
// clang built-in function name, e.g. __builtin_rvv_vadd.
- std::string BuiltinName = "__builtin_rvv_" + std::string(Record.Name);
+ std::string
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
@@ -463,7 +464,7 @@ void
RISCVIntrinsicManagerImpl::CreateRVVIntrinsicDecl(LookupResult ,
bool RISCVIntrinsicManagerImpl::CreateIntrinsicIfFound(LookupResult ,
IdentifierInfo *II,
llvmbot wrote:
@llvm/pr-subscribers-clang
Author: Brandon Wu (4vtomat)
Changes
This patch optimize:
1. Reduce string size of RVVIntrinsicDef.
2. Reduce the type size of the index of intrinsics.
I use valgrind --tool=massif to analyze a simple program:
```
#include riscv_vector.h
llvmbot wrote:
@llvm/pr-subscribers-backend-risc-v
Author: Brandon Wu (4vtomat)
Changes
This patch optimize:
1. Reduce string size of RVVIntrinsicDef.
2. Reduce the type size of the index of intrinsics.
I use valgrind --tool=massif to analyze a simple program:
```
#include
https://github.com/4vtomat created
https://github.com/llvm/llvm-project/pull/77487
This patch optimize:
1. Reduce string size of RVVIntrinsicDef.
2. Reduce the type size of the index of intrinsics.
I use valgrind --tool=massif to analyze a simple program:
```
#include
vint32m1_t
36 matches
Mail list logo