函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\events\core.c Create Date:2022-07-27 14:58:45
Last Modify:2022-05-20 07:50:19 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:We directly increment event->count and keep a second value in* is kept in the range [-sample_period, 0] so that we can use the* sign as trigger.

函数原型:u64 perf_swevent_set_period(struct perf_event *event)

返回类型:u64

参数:

类型参数名称
struct perf_event *event>hw.period_left to count intervals. This period event
8477  hwc等于hw
8478  period等于last_period
8482  last_period等于sample_period
8484  again :
8485  old等于val等于local64_read( & period_left)
8486  如果val小于0则返回:0
8489  nr等于div64_u64 - unsigned 64bit divide with 64bit divisor*@dividend: 64bit dividend*@divisor: 64bit divisor* This implementation is a modified version of the algorithm proposed* by the book 'Hacker's Delight'. The original source and full proof
8490  offset等于nrperiod
8491  val减等于offset
8492  如果local64_cmpxchg( & period_left, old, val)不等于old则转到:again
8495  返回:nr
调用者
名称描述
perf_swevent_overflow
perf_swevent_add
hw_breakpoint_add