Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Save to My Library
Look up keyword or section
Like this
4Activity

Table Of Contents

0 of .
Results for:
No results containing your search query
P. 1
SystemTap - Language Reference

SystemTap - Language Reference

Ratings: (0)|Views: 377 |Likes:
Published by lupin88
SystemTap Language Reference

November 13, 2009

This document was derived from other documents contributed to the SystemTap project by employees of Red Hat, IBM and Intel. Copyright c 2007-2009 Red Hat Inc. Copyright c 2007-2009 IBM Corp. Copyright c 2007 Intel Corporation. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant S
SystemTap Language Reference

November 13, 2009

This document was derived from other documents contributed to the SystemTap project by employees of Red Hat, IBM and Intel. Copyright c 2007-2009 Red Hat Inc. Copyright c 2007-2009 IBM Corp. Copyright c 2007 Intel Corporation. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant S

More info:

Published by: lupin88 on Sep 02, 2010
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as PDF or read online from Scribd
See more
See less

11/08/2012

pdf

 
SystemTap Language Reference
November 13, 2009
1
 
This document was derived from other documents contributed to the SystemTap project by employees of Red Hat, IBM and Intel.Copyrightc
2007-2009 Red Hat Inc.Copyrightc
2007-2009 IBM Corp.Copyrightc
2007 Intel Corporation.Permission is granted to copy, distribute and/or modify this document under the terms of the GNU FreeDocumentation License, Version 1.2 or any later version published by the Free Software Foundation; withno Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.The GNU Free Documentation License is available from
http://www.gnu.org/licenses/fdl.html
or bywriting to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.2
 
CONTENTS CONTENT
Contents
1 SystemTap overview 10
1.1 About this guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101.2 Reasons to use SystemTap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101.3 Event-action language . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101.4 Sample SystemTap scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101.4.1 Basic SystemTap syntax and control structures . . . . . . . . . . . . . . . . . . . . . . 101.4.2 Primes between 0 and 49 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111.4.3 Recursive functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121.5 The stap command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131.6 Safety and security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2 Types of SystemTap scripts 14
2.1 Probe scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142.2 Tapset scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
3 Components of a SystemTap script 14
3.1 Probe denitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143.2 Probe aliases . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153.2.1 Prologue-style aliases (=) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153.2.2 Epilogue-style aliases (+=) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163.2.3 Probe alias usage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163.2.4 Unused alias variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163.4 Auxiliary functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173.5 Embedded C . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173.6 Embedded C functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
4 Probe points 18
4.1 General syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184.1.1 Prexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194.1.2 Suxes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194.1.3 Wildcarded le names, function names . . . . . . . . . . . . . . . . . . . . . . . . . . . 194.1.4 Optional probe points . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194.2 Built-in probe point types (DWARF probes) . . . . . . . . . . . . . . . . . . . . . . . . . . . 203

Activity (4)

You've already reviewed this. Edit your review.
1 hundred reads
1 thousand reads
Cole Kowalski liked this
lupin88 liked this

You're Reading a Free Preview

Download
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->