STAPVARS(3stap)

πŸ’– NAME πŸ’–

stapvars β€” systemtap variables, bestie. that's it, that's the whole name. slay ✨


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the tea: the sections below are gonna walk you through all the public variables that the standard tapsets give you. (btw if you wanna know where those tapsets are even installed, the path is shown in the stappaths (7) manual page πŸ‘€)

every single variable gets described with a type, plus its behavior and restrictions, because we're thorough like that πŸ’…

and the syntax? it's literally the exact same syntax you get printed out with the stap option -p2. no cap. fr fr.

examples, because a vibe check needs receipts:

example1:long

Variable "example1" contains an integer. simple. iconic.

example2:string [long]

Variable "example2" is an array of strings, indexed by integers. she's got range πŸ’œ


🌸 ARGV 🌸

  • argc:long β€” this one holds the value of the $# value, which is the number of command line arguments passed to the systemtap script. and the way she gets initialized?? an implicit begin(-1) probe. periodt. πŸ‘‘
  • argv:string [long] β€” she holds each command line argument as a string, one by one. so like, argv[1] will equal @1 β€” but only if there was at least one command line argument to begin with. fair.
⚠️ lowkey important: arguments beyond #32 are not transcribed, and they produce a warning message inside that begin(-1) probe that initializes this array. so if you're out here throwing 33+ args at it, expect a lil warning bestie 😭

πŸŽ€ NULL πŸŽ€

  • NULL:long β€” simply defined as the number 0. that's it. no lore. no backstory. just zero. a minimalist queen 🫢

πŸ“ FILES πŸ“

want more files and their corresponding paths? they're all hanging out in the stappaths (7) manual page. go say hi 🌈


⭐ SEE ALSO ⭐


and that's the whole page, bestie!! this lil masterpiece lives under STAPVARS(3stap) β€” that's the 3stap manual section, iykyk πŸ’… take care of her, she's got main character energy πŸ‘‘βœ¨πŸ’–

πŸ“¦ where this page comes from