projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
79fd94e
)
RISCVISAInfo: Internalize struct FindByName
author
Fangrui Song
<i@maskray.me>
Thu, 24 Nov 2022 01:22:49 +0000
(17:22 -0800)
committer
Fangrui Song
<i@maskray.me>
Thu, 24 Nov 2022 01:22:49 +0000
(17:22 -0800)
llvm/lib/Support/RISCVISAInfo.cpp
patch
|
blob
|
history
diff --git
a/llvm/lib/Support/RISCVISAInfo.cpp
b/llvm/lib/Support/RISCVISAInfo.cpp
index
fe9cc4c
..
3dea408
100644
(file)
--- a/
llvm/lib/Support/RISCVISAInfo.cpp
+++ b/
llvm/lib/Support/RISCVISAInfo.cpp
@@
-144,6
+144,7
@@
static size_t findFirstNonVersionCharacter(StringRef Ext) {
return Pos;
}
+namespace {
struct FindByName {
FindByName(StringRef Ext) : Ext(Ext){};
StringRef Ext;
@@
-151,6
+152,7
@@
struct FindByName {
return ExtInfo.Name == Ext;
}
};
+} // namespace
static Optional<RISCVExtensionVersion> findDefaultVersion(StringRef ExtName) {
// Find default version of an extension.