/usr/share/systemtap/tapset
NameSizeModeActions
arm/-0755rm
arm64/-0755rm
bpf/-0755rm
dyninst/-0755rm
i386/-0755rm
ia64/-0755rm
linux/-0755rm
mips/-0755rm
powerpc/-0755rm
riscv/-0755rm
s390/-0755rm
x86_64/-0755rm
ansi.stp41780644editdlrm
argv.stp27210644editdlrm
choose_defined.stpm2080644editdlrm
container_of.stpm2350644editdlrm
context.stp61030644editdlrm
errno.stp91180644editdlrm
floatingpoint.stp69360644editdlrm
indent-default.stp590644editdlrm
indent.stp45900644editdlrm
init.stp2690644editdlrm
input.stp2630644editdlrm
java.stp13460644editdlrm
libperl5.26.3-64.stp13390644editdlrm
libpython2.7-64.stp5220644editdlrm
livepatch.stp30060644editdlrm
logging.stp41320644editdlrm
macros.stpm5620644editdlrm
null.stp170644editdlrm
offsetof.stpm1830644editdlrm
oneshot.stp380644editdlrm
pn.stp15880644editdlrm
print_stats.stpm17190644editdlrm
private30.stpm800644editdlrm
prometheus.stp1290644editdlrm
prometheus.stpm83800644editdlrm
python.stp4740644editdlrm
python2.stp294350644editdlrm
python3.stp366550644editdlrm
queue_stats.stp94870644editdlrm
random.stp4320644editdlrm
README3710644editdlrm
regex.stp41070644editdlrm
registers.stp110810644editdlrm
sizeof.stpm2120644editdlrm
speculative.stp17460644editdlrm
sreg_arch.stpm2630644editdlrm
stap_staticmarkers.stp96700644editdlrm
stopwatch.stp30630644editdlrm
string.stp75140644editdlrm
switchfile.stp6120644editdlrm
system.stp5930644editdlrm
this.stp1600644editdlrm
timers.stp9240644editdlrm
tls.stp80990644editdlrm
tokenize.stp21240644editdlrm
try_assign.stpm7680644editdlrm
type_defined.stpm3740644editdlrm
tzinfo.stp9300644editdlrm
uconversions-guru.stp60780644editdlrm
uconversions.stp366400644editdlrm
Edit: /usr/share/systemtap/tapset/tokenize.stp (2124B)
// Tokenize tapset // Copyright (C) 2010-2018 Red Hat, Inc. // // This file is part of systemtap, and is free software. You can // redistribute it and/or modify it under the terms of the GNU General // Public License (GPL); either version 2, or (at your option) any // later version. %{ #define STAP_NEED_CONTEXT_TOKENIZE 1 %} /** * sfunction tokenize - Return the next non-empty token in a string * * @delim: set of characters that delimit the tokens * * Description: This function returns the next token in the string * passed in the previous call to tokenize. If no delimiter is found, * the entire remaining input string is * returned. It returns empty * when no more tokens are available. */ function tokenize:string(delim:string) { return tokenize("", delim) } /** * sfunction tokenize - Return the next non-empty token in a string * * @input: string to tokenize. If empty, returns the next non-empty token * in the string passed in the previous call to tokenize(). * @delim: set of characters that delimit the tokens * * Description: This function returns the next non-empty token in the * given input string, where the tokens are delimited by characters in * the delim string. If the input string is non-empty, it returns the * first token. If the input string is empty, it returns the next * token in the string passed in the previous call to tokenize. * If no delimiter is found, the entire remaining input string is * returned. It returns empty when no more tokens are available. */ function tokenize:string(input:string, delim:string) %{ /* unprivileged */ /* unmodified-fnargs */ char *token = NULL; char *token_end = NULL; if (STAP_ARG_input[0]) { strlcpy(CONTEXT->tok_str, STAP_ARG_input, MAXSTRINGLEN); CONTEXT->tok_start = &CONTEXT->tok_str[0]; CONTEXT->tok_end = &CONTEXT->tok_str[0] + strlen(CONTEXT->tok_str); } do { token = strsep(& CONTEXT->tok_start, STAP_ARG_delim); } while (token && !token[0]); if (token) { token_end = (CONTEXT->tok_start ? CONTEXT->tok_start - 1 : CONTEXT->tok_end); memcpy(STAP_RETVALUE, token, token_end - token + 1); } %}