[PATCH] D70187: Add accessors for MCSubtargetInfo CPU and Feature tables
Marc-Antoine Perennou via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 13 08:27:41 PST 2019
Keruspe created this revision.
Keruspe added a reviewer: craig.topper.
Keruspe added a project: LLVM.
Herald added subscribers: llvm-commits, JDevlieghere.
Keruspe updated this revision to Diff 229109.
Keruspe added a comment.
Fixed repository in diff
This is needed for `-C target-cpu=help` and `-C target-feature=help` in rustc
This patch has been around for quite a while in rust's llvm fork:
Author: Cameron Hart <cameron.hart at gmail.com>
Date: Sun Jul 10 23:55:53 2016 +1000
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D70187
Files:
llvm/include/llvm/MC/MCSubtargetInfo.h
Index: llvm/include/llvm/MC/MCSubtargetInfo.h
===================================================================
--- llvm/include/llvm/MC/MCSubtargetInfo.h
+++ llvm/include/llvm/MC/MCSubtargetInfo.h
@@ -267,6 +267,14 @@
/// prefetching.
///
virtual unsigned getMinPrefetchStride() const;
+
+ ArrayRef<SubtargetSubTypeKV> getCPUTable() const {
+ return ProcDesc;
+ }
+
+ ArrayRef<SubtargetFeatureKV> getFeatureTable() const {
+ return ProcFeatures;
+ }
};
} // end namespace llvm
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D70187.229109.patch
Type: text/x-patch
Size: 503 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191113/db82554e/attachment.bin>
More information about the llvm-commits
mailing list