• Robin Murphy's avatar
    perf/arm-cmn: Make cycle counts less surprising · c5b15ddf
    Robin Murphy authored
    
    
    By default, CMN has automatic clock-gating with the implication that
    a DTC's cycle counter may not increment while the DTC is sufficiently
    idle. Given that we may have up to 4 DTCs to choose from when scheduling
    a cycles event, this may potentially lead to surprising results if
    trying to measure metrics based on activity in a different DTC domain
    from where cycles end up being counted. Furthermore, since the details
    of internal clock gating are not documented, we can't even reason about
    what "active" cycles for a DTC actually mean relative to the activity of
    other nodes within the same nominal DTC domain.
    
    Make the reasonable assumption that if the user wants to count cycles,
    they almost certainly want to count all of the cycles, and disable clock
    gating while a DTC's cycle counter is in use.
    Signed-off-by: default avatarRobin Murphy <robin.murphy@arm.com>
    Link: https://lore.kernel.org/r/c47cfdc09e907b1d7753d142a7e659982cceb246.1725296395.git.robin.murphy@arm.com
    
    Signed-off-by: default avatarWill Deacon <will@kernel.org>
    c5b15ddf
arm-cmn.c 79.6 KB