Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.2:Rings:1-MinimalX
libpfm
moved-tx2-uncore-event-to-separate-file.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File moved-tx2-uncore-event-to-separate-file.patch of Package libpfm
From: Shay Gal-On <sgalon@cavium.com> Date: Thu Nov 21 10:41:26 2019 -0800 Subject: Moved TX2 uncore event to separate file Git-commit: 6641952170c23c5ab69c1af19197a9d8284c1e53 References: jsc#SLE-10000 Signed-off-by: Tony Jones <tonyj@suse.de> Moved TX2 uncore event to separate file To make event files cleaner. Also added link to marvell doc publishing the uncore event lists. Signed-off-by: Shay Gal-On <sgalon@marvell.com> diff --git a/lib/Makefile b/lib/Makefile index f45515d..686264b 100644 --- a/lib/Makefile +++ b/lib/Makefile @@ -360,11 +360,13 @@ INC_ARM=pfmlib_arm_priv.h \ events/arm_cortex_a15_events.h \ events/arm_cortex_a57_events.h \ events/arm_cortex_a53_events.h \ - events/arm_cavium_tx2_events.h + events/arm_cavium_tx2_events.h \ + events/arm_marvell_tx2_unc_events.h INC_ARM64=events/arm_cortex_a57_events.h \ - events/arm_cortex_a53_events.h \ - events/arm_cavium_tx2_events.h + events/arm_cortex_a53_events.h \ + events/arm_cavium_tx2_events.h \ + events/arm_marvell_tx2_unc_events.h INCDEP=$(INC_COMMON) $(INCARCH) diff --git a/lib/events/arm_cavium_tx2_events.h b/lib/events/arm_cavium_tx2_events.h index 18d8931..198d33d 100644 --- a/lib/events/arm_cavium_tx2_events.h +++ b/lib/events/arm_cavium_tx2_events.h @@ -835,64 +835,3 @@ static const arm_entry_t arm_thunderx2_pe[]={ .desc = "Scu hwpf next line requests generated" }, }; - -#define ARM_TX2_CORE_EVENT_COUNT (sizeof(arm_thunderx2_pe)/sizeof(arm_entry_t)) - -/* L3C event IDs */ -#define L3_EVENT_READ_REQ 0xD -#define L3_EVENT_WRITEBACK_REQ 0xE -#define L3_EVENT_EVICT_REQ 0x13 -#define L3_EVENT_READ_HIT 0x17 -#define L3_EVENT_MAX 0x18 - -/* DMC event IDs */ -#define DMC_EVENT_COUNT_CYCLES 0x1 -#define DMC_EVENT_WRITE_TXNS 0xB -#define DMC_EVENT_DATA_TRANSFERS 0xD -#define DMC_EVENT_READ_TXNS 0xF -#define DMC_EVENT_MAX 0x10 - -static const arm_entry_t arm_thunderx2_unc_dmc_pe[]={ - {.name = "UNC_DMC_READS", - .modmsk = ARMV8_ATTRS, - .code = DMC_EVENT_READ_TXNS, - .desc = "Memory read transactions" - }, - {.name = "UNC_DMC_WRITES", - .modmsk = ARMV8_ATTRS, - .code = DMC_EVENT_WRITE_TXNS, - .desc = "Memory write transactions" - }, -}; - -#define ARM_TX2_CORE_DMC_COUNT (sizeof(arm_thunderx2_unc_dmc_pe)/sizeof(arm_entry_t)) - -static const arm_entry_t arm_thunderx2_unc_llc_pe[]={ - {.name = "UNC_LLC_READ", - .modmsk = ARMV8_ATTRS, - .code = L3_EVENT_READ_REQ, - .desc = "Read requests to LLC" - }, - {.name = "UNC_LLC_EVICT", - .modmsk = ARMV8_ATTRS, - .code = L3_EVENT_EVICT_REQ, - .desc = "Evict requests to LLC" - }, - {.name = "UNC_LLC_READ_HIT", - .modmsk = ARMV8_ATTRS, - .code = L3_EVENT_READ_HIT, - .desc = "Read requests to LLC which hit" - }, - {.name = "UNC_LLC_WB", - .modmsk = ARMV8_ATTRS, - .code = L3_EVENT_WRITEBACK_REQ, - .desc = "Writeback requests to LLC" - } -}; - -#define ARM_TX2_CORE_LLC_COUNT (sizeof(arm_thunderx2_unc_llc_pe)/sizeof(arm_entry_t)) -//Uncore accessor functions -int -pfm_tx2_unc_get_event_encoding(void *this, pfmlib_event_desc_t *e); -int -pfm_tx2_unc_get_perf_encoding(void *this, pfmlib_event_desc_t *e); diff --git a/lib/events/arm_marvell_tx2_unc_events.h b/lib/events/arm_marvell_tx2_unc_events.h new file mode 100755 index 0000000..9b0a1b4 --- /dev/null +++ b/lib/events/arm_marvell_tx2_unc_events.h @@ -0,0 +1,90 @@ +/* + * Copyright (c) 2019 Marvell Technology Group Ltd + * Contributed by Shay Gal-On <sgalon@marvell.com> + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies + * of the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, + * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A + * PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT + * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF + * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE + * OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + * Marvell ThunderX2 + * + * ARM Architecture Reference Manual, ARMv8, for ARMv8-A architecture profile, + * ARM DDI 0487B.a (ID033117) + * + * Marvell ThunderX2 C99XX Core and Uncore PMU Events (Abridged) can be found at + * https://www.marvell.com/documents/hrur6mybdvk5uki1w0z7/ + * + */ + + +/* L3C event IDs */ +#define L3_EVENT_READ_REQ 0xD +#define L3_EVENT_WRITEBACK_REQ 0xE +#define L3_EVENT_EVICT_REQ 0x13 +#define L3_EVENT_READ_HIT 0x17 +#define L3_EVENT_MAX 0x18 + +/* DMC event IDs */ +#define DMC_EVENT_COUNT_CYCLES 0x1 +#define DMC_EVENT_WRITE_TXNS 0xB +#define DMC_EVENT_DATA_TRANSFERS 0xD +#define DMC_EVENT_READ_TXNS 0xF +#define DMC_EVENT_MAX 0x10 + +static const arm_entry_t arm_thunderx2_unc_dmc_pe[]={ + {.name = "UNC_DMC_READS", + .modmsk = ARMV8_ATTRS, + .code = DMC_EVENT_READ_TXNS, + .desc = "Memory read transactions" + }, + {.name = "UNC_DMC_WRITES", + .modmsk = ARMV8_ATTRS, + .code = DMC_EVENT_WRITE_TXNS, + .desc = "Memory write transactions" + }, +}; + +#define ARM_TX2_CORE_DMC_COUNT (sizeof(arm_thunderx2_unc_dmc_pe)/sizeof(arm_entry_t)) + +static const arm_entry_t arm_thunderx2_unc_llc_pe[]={ + {.name = "UNC_LLC_READ", + .modmsk = ARMV8_ATTRS, + .code = L3_EVENT_READ_REQ, + .desc = "Read requests to LLC" + }, + {.name = "UNC_LLC_EVICT", + .modmsk = ARMV8_ATTRS, + .code = L3_EVENT_EVICT_REQ, + .desc = "Evict requests to LLC" + }, + {.name = "UNC_LLC_READ_HIT", + .modmsk = ARMV8_ATTRS, + .code = L3_EVENT_READ_HIT, + .desc = "Read requests to LLC which hit" + }, + {.name = "UNC_LLC_WB", + .modmsk = ARMV8_ATTRS, + .code = L3_EVENT_WRITEBACK_REQ, + .desc = "Writeback requests to LLC" + } +}; + +#define ARM_TX2_CORE_LLC_COUNT (sizeof(arm_thunderx2_unc_llc_pe)/sizeof(arm_entry_t)) +//Uncore accessor functions +int +pfm_tx2_unc_get_event_encoding(void *this, pfmlib_event_desc_t *e); +int +pfm_tx2_unc_get_perf_encoding(void *this, pfmlib_event_desc_t *e); diff --git a/lib/pfmlib_arm_armv8.c b/lib/pfmlib_arm_armv8.c index 35ff70f..291ac60 100644 --- a/lib/pfmlib_arm_armv8.c +++ b/lib/pfmlib_arm_armv8.c @@ -33,7 +33,8 @@ #include "events/arm_cortex_a57_events.h" /* A57 event tables */ #include "events/arm_cortex_a53_events.h" /* A53 event tables */ #include "events/arm_xgene_events.h" /* Applied Micro X-Gene tables */ -#include "events/arm_cavium_tx2_events.h" /* Cavium ThunderX2 tables */ +#include "events/arm_cavium_tx2_events.h" /* Marvell ThunderX2 tables */ +#include "events/arm_marvell_tx2_unc_events.h" /* Marvell ThunderX2 PMU tables */ static int pfm_arm_detect_cortex_a57(void *this)
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor