---
name: "dtrace_syscall"
section: "4"
platform: "freebsd"
package: "base"
version: "16.0-CURRENT-20261027-61c70dc16a79"
release: "FreeBSD 16.0-CURRENT (2026-10-27)"
platforms: ["freebsd"]
url: "https://new.carta.tech/dtrace_syscall"
---

# dtrace\_syscall(4)

a DTrace provider for system calls

## NAME

**dtrace\_syscall** – a DTrace provider for system calls

## SYNOPSIS

**syscall****:***abi***:***syscall***:entry**

**syscall****:***abi***:***syscall***:return**

## DESCRIPTION

The **syscall** provider provides entry and return probes for system calls.

The module in the probe's description is *abi*, which indicates what system call ABI a *syscall* belongs to. **dtrace\_syscall** supports the following system call ABIs:

- **freebsd**

  Native ABI.

- **freebsd32**

  Non-native, 32-bit ABI.

- **linux**

  Refer to [linux(4)](/linux/4.md).

- **linux32**

  Refer to [linux(4)](/linux/4.md).

The arguments to the **entry** probes are the arguments passed to the system call.

The **return** probe stores the system call's return value in both *arg0* and *arg1*.

Inspect the [d(7)](/d/7.md)'s *errno* variable to check if a system call failed.

## EXAMPLES

### Example 1 : Count Up System Calls

The following script traces all system calls and counts them for every process on the system.

```
syscall:::entry {
    @[execname, pid] = count();
}
```

## SEE ALSO

[dtrace(1)](/dtrace/1.md), [intro(2)](/intro/2.md), [tracing(7)](/tracing/7.md) *The illumos Dynamic Tracing Guide*, 2008, Chapter syscall Provider, https://illumos.org/books/dtrace/chp-syscall.html. Brendan Gregg and Jim Mauro, *DTrace: Dynamic Tracing in Oracle Solaris, Mac OS X and FreeBSD*, Prentice Hall, pp. 315–327, 2011, Chapter Syscall Provider, https://www.brendangregg.com/dtracebook/.

## AUTHORS

This manual page was written by Mateusz Piotrowski ⟨*0mp@FreeBSD.org*⟩.
