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
6f53be35
Commit
6f53be35
authored
Apr 16, 2018
by
4ast
Committed by
GitHub
Apr 16, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1687 from iovisor/yhs_dev2
fix test_libbcc failure with 4.15.
parents
22166d00
c40b5fd6
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
tests/cc/test_perf_event.cc
tests/cc/test_perf_event.cc
+5
-1
No files found.
tests/cc/test_perf_event.cc
View file @
6f53be35
...
@@ -131,7 +131,11 @@ TEST_CASE("test attach perf event", "[bpf_perf_event]") {
...
@@ -131,7 +131,11 @@ TEST_CASE("test attach perf event", "[bpf_perf_event]") {
auto
ret
=
bpf
.
get_hash_table
<
int
,
int
>
(
"ret"
);
auto
ret
=
bpf
.
get_hash_table
<
int
,
int
>
(
"ret"
);
REQUIRE
(
ret
[
0
]
==
0
);
REQUIRE
(
ret
[
0
]
==
0
);
REQUIRE
(
counter
.
counter
>=
0
);
REQUIRE
(
counter
.
counter
>=
0
);
REQUIRE
(
counter
.
enabled
>=
1000000000
);
// the program slept one second between perf_event attachment and detachment
// in the above, so the enabled counter should be 1000000000ns or
// more. But in reality, most of counters (if not all) are 9xxxxxxxx,
// and I also saw one 8xxxxxxxx. So let us a little bit conservative here.
REQUIRE
(
counter
.
enabled
>=
800000000
);
REQUIRE
(
counter
.
running
>=
0
);
REQUIRE
(
counter
.
running
>=
0
);
REQUIRE
(
counter
.
running
<=
counter
.
enabled
);
REQUIRE
(
counter
.
running
<=
counter
.
enabled
);
#endif
#endif
...
...
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