Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bcc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
bcc
Commits
18d3814c
Commit
18d3814c
authored
Apr 06, 2018
by
4ast
Committed by
GitHub
Apr 06, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1669 from iovisor/yhs_dev
fix compiler warning
parents
ca3bd8ae
61130a16
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
src/cc/perf_reader.c
src/cc/perf_reader.c
+4
-4
No files found.
src/cc/perf_reader.c
View file @
18d3814c
...
...
@@ -145,19 +145,19 @@ static void parse_sw(struct perf_reader *reader, void *data, int size) {
reader
->
raw_cb
(
reader
->
cb_cookie
,
raw
->
data
,
raw
->
size
);
}
static
uint64_t
read_data_head
(
struct
perf_event_mmap_page
*
perf_header
)
{
uint64_t
data_head
=
*
((
volatile
uint64_t
*
)
&
perf_header
->
data_head
)
;
static
uint64_t
read_data_head
(
volatile
struct
perf_event_mmap_page
*
perf_header
)
{
uint64_t
data_head
=
perf_header
->
data_head
;
asm
volatile
(
""
:::
"memory"
);
return
data_head
;
}
static
void
write_data_tail
(
struct
perf_event_mmap_page
*
perf_header
,
uint64_t
data_tail
)
{
static
void
write_data_tail
(
volatile
struct
perf_event_mmap_page
*
perf_header
,
uint64_t
data_tail
)
{
asm
volatile
(
""
:::
"memory"
);
perf_header
->
data_tail
=
data_tail
;
}
void
perf_reader_event_read
(
struct
perf_reader
*
reader
)
{
struct
perf_event_mmap_page
*
perf_header
=
reader
->
base
;
volatile
struct
perf_event_mmap_page
*
perf_header
=
reader
->
base
;
uint64_t
buffer_size
=
(
uint64_t
)
reader
->
page_size
*
reader
->
page_cnt
;
uint64_t
data_head
;
uint8_t
*
base
=
(
uint8_t
*
)
reader
->
base
+
reader
->
page_size
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment