JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Solaris Dynamic Tracing Guide
search filter icon
search icon

Document Information

Preface

1.  Introduction

2.  Types, Operators, and Expressions

3.  Variables

4.  D Program Structure

5.  Pointers and Arrays

6.  Strings

7.  Structs and Unions

8.  Type and Constant Definitions

9.  Aggregations

10.  Actions and Subroutines

11.  Buffers and Buffering

12.  Output Formatting

13.  Speculative Tracing

14.  dtrace(1M) Utility

15.  Scripting

16.  Options and Tunables

17.  dtrace Provider

18.  lockstat Provider

19.  profile Provider

20.  fbt Provider

21.  syscall Provider

22.  sdt Provider

23.  sysinfo Provider

24.  vminfo Provider

25.  proc Provider

26.  sched Provider

27.  io Provider

28.  mib Provider

29.  fpuinfo Provider

30.  pid Provider

31.  plockstat Provider

Overview

Mutex Probes

Reader/Writer Lock Probes

Stability

32.  fasttrap Provider

33.  User Process Tracing

34.  Statically Defined Tracing for User Applications

35.  Security

36.  Anonymous Tracing

37.  Postmortem Tracing

38.  Performance Considerations

39.  Stability

40.  Translators

41.  Versioning

Glossary

Index

Reader/Writer Lock Probes

Reader/write locks permit multiple readers or a single writer, but not both, to be in a critical section at one time. These locks are typically used for structures that are searched more frequently than they are modified, or when threads spend substantial time in a critical section. Users interact with reader/writer locks using the Solaris rwlock(3C) or POSIX pthread_rwlock_init(3C) interfaces.

The probes pertaining to readers/writer locks are in Table 31-2. For each probe, arg0 contains a pointer to the rwlock_t or pthread_rwlock_tstructure (these are identical types) that represents the adaptive lock. arg1 contains a boolean value that indicates whether the operation was as a writer.

Table 31-2 Readers/Writer Lock Probes

rw-acquire
Hold event probe that fires immediately after a readers/writer lock is acquired.
rw-block
Contention event probe that fires before a thread blocks while attempting to acquire a lock. If enabled, the rw-acquire probe or the rw-error probe will fire after rw-block.
rw-release
Hold event probe that fires immediately after a reader/writer lock is released
rw-error
Error event probe that fires when an error is encountered during a reader/writer lock operation. arg1 is the errno value of the error encountered.