Skip to content

Commit 619f4dd

Browse files
committed
Update README.md.
1 parent dc1b9cf commit 619f4dd

File tree

1 file changed

+25
-7
lines changed

1 file changed

+25
-7
lines changed

README.md

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,35 @@ The program will automatically compile with the appropriate architecture-specifi
3232
## Usage
3333

3434
```bash
35-
./target/release/stacker <pid>
35+
stacker <SUBCOMMAND> [OPTIONS]
3636
```
3737

38-
Where `<pid>` is the process ID you want to trace.
38+
### Commands
3939

40-
### Example
40+
- **capture**: Capture stack traces into a JSON file
41+
- **options**: `--pid <pid>`, `--output <path>`
42+
- **example**:
43+
```bash
44+
stacker capture --pid 1234 --output capture.json
45+
```
4146

42-
```bash
43-
# Trace process with PID 1234
44-
./target/release/stacker 1234
45-
```
47+
- **symbolize**: Symbolize a previously captured JSON file
48+
- **options**: `--input <path>`, `--executable <path>`
49+
- **example**:
50+
```bash
51+
stacker symbolize --input capture.json --executable /proc/1234/exe
52+
```
53+
54+
- **onephase**: Capture and symbolize in one go (no file I/O)
55+
- **options**: `--pid <pid>`
56+
- **example**:
57+
```bash
58+
stacker onephase --pid 1234
59+
```
60+
61+
#### Notes on symbolization
62+
63+
- **Shared libraries and debug symbols**: If the traced process uses shared libraries, the exact libraries (and ideally their debug symbol packages) must be installed and discoverable during symbolization, especially when symbolizing on a different machine. Otherwise, symbol resolution may be incomplete or missing file/line information.
4664

4765
## Output
4866

0 commit comments

Comments
 (0)