summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-mca/ResourcePressureView.cpp
diff options
context:
space:
mode:
authorMatt Davis <Matthew.Davis@sony.com>2018-07-12 16:56:17 +0000
committerMatt Davis <Matthew.Davis@sony.com>2018-07-12 16:56:17 +0000
commit0906a7fc53342cfb6869da2066274b03d7ceac9c (patch)
tree32214fd156f4cec604b6cf83078c6c427efaff79 /llvm/tools/llvm-mca/ResourcePressureView.cpp
parentc2c0138a04689a51116de03d9120ffcf73ddf37d (diff)
downloadbcm5719-llvm-0906a7fc53342cfb6869da2066274b03d7ceac9c.tar.gz
bcm5719-llvm-0906a7fc53342cfb6869da2066274b03d7ceac9c.zip
[llvm-mca] Simplify eventing by adding an onEvent templated method.
Summary: This patch eliminates some redundancy in iterating across Listeners for the Instruction and Stall HWEvents, by introducing a template onEvent routine. This change was suggested by @courbet in https://reviews.llvm.org/D48576. I hope that this patch addresses that suggestion appropriately. I do like this change better than what we had previously. Reviewers: andreadb, courbet, RKSimon Reviewed By: andreadb, courbet Subscribers: javed.absar, tschuett, gbedwell, llvm-commits, courbet Differential Revision: https://reviews.llvm.org/D48672 llvm-svn: 336916
Diffstat (limited to 'llvm/tools/llvm-mca/ResourcePressureView.cpp')
-rw-r--r--llvm/tools/llvm-mca/ResourcePressureView.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/tools/llvm-mca/ResourcePressureView.cpp b/llvm/tools/llvm-mca/ResourcePressureView.cpp
index 37bb059c907..fe9d5b7fabc 100644
--- a/llvm/tools/llvm-mca/ResourcePressureView.cpp
+++ b/llvm/tools/llvm-mca/ResourcePressureView.cpp
@@ -40,7 +40,7 @@ void ResourcePressureView::initialize() {
std::fill(ResourceUsage.begin(), ResourceUsage.end(), 0.0);
}
-void ResourcePressureView::onInstructionEvent(const HWInstructionEvent &Event) {
+void ResourcePressureView::onEvent(const HWInstructionEvent &Event) {
// We're only interested in Issue events.
if (Event.Type != HWInstructionEvent::Issued)
return;
OpenPOWER on IntegriCloud