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
fdf9b08c
Commit
fdf9b08c
authored
Oct 10, 2017
by
Edward Betts
Committed by
Brenden Blanco
Oct 12, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
correct spelling mistakes
parent
b3347027
Changes
17
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
18 additions
and
18 deletions
+18
-18
examples/networking/dns_matching/dns_matching.py
examples/networking/dns_matching/dns_matching.py
+1
-1
man/man8/memleak.8
man/man8/memleak.8
+1
-1
man/man8/tcplife.8
man/man8/tcplife.8
+1
-1
src/cc/frontends/clang/loader.cc
src/cc/frontends/clang/loader.cc
+1
-1
src/cc/frontends/p4/test/testP4toEbpf.py
src/cc/frontends/p4/test/testP4toEbpf.py
+1
-1
src/cc/libbpf.c
src/cc/libbpf.c
+1
-1
src/lua/bcc/vendor/json.lua
src/lua/bcc/vendor/json.lua
+1
-1
src/lua/bpf/bpf.lua
src/lua/bpf/bpf.lua
+2
-2
src/python/bcc/table.py
src/python/bcc/table.py
+1
-1
tests/python/test_brb.c
tests/python/test_brb.c
+1
-1
tools/cpuunclaimed_example.txt
tools/cpuunclaimed_example.txt
+1
-1
tools/dcstat.py
tools/dcstat.py
+1
-1
tools/offwaketime_example.txt
tools/offwaketime_example.txt
+1
-1
tools/solisten.py
tools/solisten.py
+1
-1
tools/tcplife.lua
tools/tcplife.lua
+1
-1
tools/tcplife.py
tools/tcplife.py
+1
-1
tools/tcplife_example.txt
tools/tcplife_example.txt
+1
-1
No files found.
examples/networking/dns_matching/dns_matching.py
View file @
fdf9b08c
...
...
@@ -69,7 +69,7 @@ for e in entries:
add_cache_entry
(
cache
,
e
)
print
(
"
\
n
Try to lookup some domain names using nslookup from another terminal."
)
print
(
"For ex
ma
ple: nslookup foo.bar"
)
print
(
"For ex
am
ple: nslookup foo.bar"
)
print
(
"
\
n
BPF program will filter-in DNS packets which match with map entries."
)
print
(
"Packets received by user space program will be printed here"
)
print
(
"
\
n
Hit Ctrl+C to end..."
)
...
...
man/man8/memleak.8
View file @
fdf9b08c
...
...
@@ -70,7 +70,7 @@ Capture only allocations that are smaller than or equal to MAX_SIZE bytes.
Attach to allocation functions in specified object instead of resolving libc. Ignored when kernel allocations are profiled.
.TP
INTERVAL
Print a summary of oustanding allocations and their call stacks every INTERVAL seconds.
Print a summary of ou
t
standing allocations and their call stacks every INTERVAL seconds.
The default interval is 5 seconds.
.TP
COUNT
...
...
man/man8/tcplife.8
View file @
fdf9b08c
...
...
@@ -105,7 +105,7 @@ Lifespan of the session, in milliseconds.
This traces the kernel TCP set state function, which should be called much
less often than send/receive tracing, and therefore have lower overhead. The
overhead of the tool is relative to the rate of new TCP sessions: if this is
high, over 10,000 per second, then there may be noticable overhead just to
high, over 10,000 per second, then there may be notic
e
able overhead just to
print out 10k lines of formatted output per second.
You can find out the rate of new TCP sessions using "sar \-n TCP 1", and
...
...
src/cc/frontends/clang/loader.cc
View file @
fdf9b08c
...
...
@@ -135,7 +135,7 @@ int ClangLoader::parse(unique_ptr<llvm::Module> *mod, TableStorage &ts,
// -fno-color-diagnostics: this is a workaround for a bug in llvm terminalHasColors() as of
// 22 Jul 2016. Also see bcc #615.
// Enable -O2 for clang. In clang 5.0, -O0 may result in func
it
on marking as
// Enable -O2 for clang. In clang 5.0, -O0 may result in func
ti
on marking as
// noinline and optnone (if not always inlining).
// Note that first argument is ignored in clang compilation invocation.
vector
<
const
char
*>
flags_cstr
({
"-O0"
,
"-O2"
,
"-emit-llvm"
,
"-I"
,
dstack
.
cwd
(),
...
...
src/cc/frontends/p4/test/testP4toEbpf.py
View file @
fdf9b08c
...
...
@@ -37,7 +37,7 @@ def main():
errors
=
0
if
not
is_root
():
print
"Loading EBPF programs requires root privile
d
ge."
print
"Loading EBPF programs requires root privilege."
print
"Will only test compilation, not loading."
print
"(Run with sudo to test program loading.)"
...
...
src/cc/libbpf.c
View file @
fdf9b08c
...
...
@@ -161,7 +161,7 @@ int bpf_get_first_key(int fd, void *key, size_t key_size)
// of map's value. So we pass an invalid pointer for value, expect
// the call to fail and check if the error is ENOENT indicating the
// key doesn't exist. If we use NULL for the invalid pointer, it might
// trigger a page fault in kernel and affect perform
e
nce. Hence we use
// trigger a page fault in kernel and affect perform
a
nce. Hence we use
// ~0 which will fail and return fast.
// This should fail since we pass an invalid pointer for value.
if
(
bpf_lookup_elem
(
fd
,
key
,
(
void
*
)
~
0
)
>=
0
)
...
...
src/lua/bcc/vendor/json.lua
View file @
fdf9b08c
...
...
@@ -19,7 +19,7 @@ consecutive sequence of positive integers starting at 1. Arrays are encoded like
so: `[2, 3, false, "hi"]`. Any other type of Lua table is encoded as a json
object, encoded like so: `{"key1": 2, "key2": false}`.
Because the Lua nil value cannot be a key, and as a table value is considerd
Because the Lua nil value cannot be a key, and as a table value is consider
e
d
equivalent to a missing key, there is no way to express the json "null" value in
a Lua table. The only way this will output "null" is if your entire input obj is
nil itself.
...
...
src/lua/bpf/bpf.lua
View file @
fdf9b08c
...
...
@@ -475,7 +475,7 @@ end
local
function
LOAD
(
dst
,
src
,
off
,
vtype
)
local
base
=
V
[
src
].
const
assert
(
base
.
__dissector
,
'NYI: load() on variable that doesnt have dissector'
)
assert
(
base
.
__dissector
,
"NYI: load() on variable that doesn't have dissector"
)
-- Cast to different type if requested
vtype
=
vtype
or
base
.
__dissector
local
w
=
ffi
.
sizeof
(
vtype
)
...
...
@@ -971,7 +971,7 @@ return setmetatable(BC, {
bb_end
(
Vstate
[
code
.
bc_pc
])
end
-- Perform fixup of jump targets
-- We need to do this because the number of consumed and emited
-- We need to do this because the number of consumed and emit
t
ed
-- bytecode instructions is different
local
fixup
=
code
.
fixup
[
code
.
bc_pc
]
if
fixup
~=
nil
then
...
...
src/python/bcc/table.py
View file @
fdf9b08c
...
...
@@ -302,7 +302,7 @@ class TableBase(MutableMapping):
it will be used to produce a bucket value for the histogram keys.
If the value of strip_leading_zero is not False, prints a histogram
that is omitted leading zeros from the beginning. The maximum index
allowed is log2_index_max (65), which will accomodate any 64-bit
allowed is log2_index_max (65), which will accom
m
odate any 64-bit
integer in the histogram.
"""
if
isinstance
(
self
.
Key
(),
ct
.
Structure
):
...
...
tests/python/test_brb.c
View file @
fdf9b08c
...
...
@@ -120,7 +120,7 @@ static int br_common(struct __sk_buff *skb, int which_br) {
/* handle ethernet packet header */
{
dmac
.
addr
=
ethernet
->
dst
;
/* skb->tc_index may be preserved ac
c
ross router namespace if router simply rewrite packet
/* skb->tc_index may be preserved across router namespace if router simply rewrite packet
* and send it back.
*/
if
(
skb
->
tc_index
==
1
)
{
...
...
tools/cpuunclaimed_example.txt
View file @
fdf9b08c
...
...
@@ -53,7 +53,7 @@ Sampling run queues... Output every 1 seconds. Hit Ctrl-C to end.
[...]
It shows that 7 of the 8 CPUs (87.5%) are idle at the same time there are
queued threads waiting to run on CPU. This is an artifical situation caused
queued threads waiting to run on CPU. This is an artific
i
al situation caused
by binding threads to the same CPU, to demonstrate how the tool works.
...
...
tools/dcstat.py
View file @
fdf9b08c
...
...
@@ -64,7 +64,7 @@ BPF_ARRAY(stats, u64, S_MAXSTAT);
* __d_lookup_rcu()). It's counted via calls to lookup_fast().
*
* The implementation tries different, progressively slower, approaches to
* lookup a file. At what point do we call it a dcache miss? I've cho
o
sen when
* lookup a file. At what point do we call it a dcache miss? I've chosen when
* a d_lookup() (which is called during lookup_slow()) returns zero.
*
* I've also included a "SLOW" statistic to show how often the fast lookup
...
...
tools/offwaketime_example.txt
View file @
fdf9b08c
...
...
@@ -171,7 +171,7 @@ stack and the waker task name after "waker:". The wakeup stack is printed
in reverse order.
The number beneath the stacks is the total time spent from the blocking event
to the wakeup event. This is summed for all occur
a
nces with the same stack
to the wakeup event. This is summed for all occur
re
nces with the same stack
pairs.
...
...
tools/solisten.py
View file @
fdf9b08c
...
...
@@ -6,7 +6,7 @@
# USAGE: solisten.py [-h] [-p PID] [--show-netns]
#
# This is provided as a basic example of TCP connection & socket tracing.
# It could be useful
l
in scenarios where load balancers needs to be updated
# It could be useful in scenarios where load balancers needs to be updated
# dynamically as application is fully initialized.
#
# All IPv4 listen attempts are traced, even if they ultimately fail or the
...
...
tools/tcplife.lua
View file @
fdf9b08c
...
...
@@ -321,7 +321,7 @@ local function parse_arg(utils)
parser
:
flag
(
"-T --time"
,
"include time column on output (HH:MM:SS)"
)
parser
:
flag
(
"-t --timestamp"
,
"include timestamp on output (seconds)"
)
parser
:
flag
(
"-w --wide"
,
"wide column output (fits IPv6 addresses)"
)
parser
:
flag
(
"-s --csv"
,
"comma sep
e
rated values output"
)
parser
:
flag
(
"-s --csv"
,
"comma sep
a
rated values output"
)
parser
:
option
(
"-p --pid"
,
"trace this PID only"
):
convert
(
tonumber
)
parser
:
option
(
"-L --localport"
,
"comma-separated list of local ports to trace."
)
parser
:
option
(
"-D --remoteport"
,
"comma-separated list of remote ports to trace."
)
...
...
tools/tcplife.py
View file @
fdf9b08c
...
...
@@ -50,7 +50,7 @@ parser.add_argument("-t", "--timestamp", action="store_true",
parser
.
add_argument
(
"-w"
,
"--wide"
,
action
=
"store_true"
,
help
=
"wide column output (fits IPv6 addresses)"
)
parser
.
add_argument
(
"-s"
,
"--csv"
,
action
=
"store_true"
,
help
=
"comma sep
e
rated values output"
)
help
=
"comma sep
a
rated values output"
)
parser
.
add_argument
(
"-p"
,
"--pid"
,
help
=
"trace this PID only"
)
parser
.
add_argument
(
"-L"
,
"--localport"
,
...
...
tools/tcplife_example.txt
View file @
fdf9b08c
...
...
@@ -117,7 +117,7 @@ optional arguments:
-T, --time include time column on output (HH:MM:SS)
-t, --timestamp include timestamp on output (seconds)
-w, --wide wide column output (fits IPv6 addresses)
-s, --csv comma sep
e
rated values output
-s, --csv comma sep
a
rated values output
-p PID, --pid PID trace this PID only
-L LOCALPORT, --localport LOCALPORT
comma-separated list of local ports to trace.
...
...
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