Skip to content

Commit 43ad081

Browse files
Merge pull request #145 from firedancer-io/cali/plumb-enable-vm-tracing
plumb enable vm tracing
2 parents b55791d + f4079b0 commit 43ad081

File tree

2 files changed

+19
-9
lines changed

2 files changed

+19
-9
lines changed

commands.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,9 @@ $ solana-test-suite create-env [OPTIONS]
4040

4141
**Options**:
4242

43-
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /data/mjain/repos/solfuzz-agave/target/release/libsolfuzz_agave.so]
43+
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /home/cali/repos/solfuzz-agave/target/debug/libsolfuzz_agave.so]
4444
* `-h, --default-harness-type TEXT`: Harness type to use for Context protobufs [default: InstrHarness]
45-
* `-t, --target PATH`: Shared object (.so) target file paths (pairs with --keep-passing). Targets must have required function entrypoints defined [default: /data/mjain/repos/firedancer/build/native/clang/lib/libfd_exec_sol_compat.so]
45+
* `-t, --target PATH`: Shared object (.so) target file paths (pairs with --keep-passing). Targets must have required function entrypoints defined [default: /home/cali/repos/firedancer-testing/build/native/gcc/lib/libfd_exec_sol_compat.so]
4646
* `-o, --output-dir PATH`: Output directory for messages [required]
4747
* `-u, --repro-urls TEXT`: Comma-delimited list of FuzzCorp mismatch links
4848
* `-n, --section-names TEXT`: Comma-delimited list of FuzzCorp section names
@@ -72,7 +72,7 @@ $ solana-test-suite create-fixtures [OPTIONS]
7272

7373
* `-i, --input PATH`: Input protobuf file or directory of protobuf files [required]
7474
* `-h, --default-harness-type TEXT`: Harness type to use for Context protobufs [default: InstrHarness]
75-
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /data/mjain/repos/solfuzz-agave/target/release/libsolfuzz_agave.so]
75+
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /home/cali/repos/solfuzz-agave/target/debug/libsolfuzz_agave.so]
7676
* `-t, --target PATH`: Shared object (.so) target file paths (pairs with --keep-passing). Targets must have required function entrypoints defined
7777
* `-o, --output-dir PATH`: Output directory for fixtures [required]
7878
* `-p, --num-processes INTEGER`: Number of processes to use [default: 4]
@@ -96,9 +96,9 @@ $ solana-test-suite debug-mismatches [OPTIONS]
9696

9797
**Options**:
9898

99-
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /data/mjain/repos/solfuzz-agave/target/release/libsolfuzz_agave.so]
99+
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /home/cali/repos/solfuzz-agave/target/debug/libsolfuzz_agave.so]
100100
* `-h, --default-harness-type TEXT`: Harness type to use for Context protobufs [default: InstrHarness]
101-
* `-t, --target PATH`: Shared object (.so) target file paths (pairs with --keep-passing). Targets must have required function entrypoints defined [default: /data/mjain/repos/firedancer/build/native/clang/lib/libfd_exec_sol_compat.so]
101+
* `-t, --target PATH`: Shared object (.so) target file paths (pairs with --keep-passing). Targets must have required function entrypoints defined [default: /home/cali/repos/firedancer-testing/build/native/gcc/lib/libfd_exec_sol_compat.so]
102102
* `-o, --output-dir PATH`: Output directory for messages [required]
103103
* `-u, --repro-urls TEXT`: Comma-delimited list of FuzzCorp mismatch links
104104
* `-n, --section-names TEXT`: Comma-delimited list of FuzzCorp section names
@@ -168,6 +168,7 @@ $ solana-test-suite execute [OPTIONS]
168168
* `-r, --randomize-output-buffer`: Randomizes bytes in output buffer before shared library execution
169169
* `-l, --log-level INTEGER`: FD logging level [default: 2]
170170
* `-n, --no-print-effects`: Do not print effects to stdout
171+
* `-evm, --enable-vm-tracing`: Enable FD VM tracing
171172
* `--help`: Show this message and exit.
172173

173174
## `solana-test-suite fix-to-ctx`
@@ -215,7 +216,7 @@ $ solana-test-suite mass-regenerate-fixtures [OPTIONS]
215216

216217
* `-i, --input PATH`: Input test-vectors directory [required]
217218
* `-o, --output-dir PATH`: Output directory for regenerated fixtures [required]
218-
* `-t, --target PATH`: Shared object (.so) target file path to execute [default: /data/mjain/repos/solfuzz-agave/target/release/libsolfuzz_agave.so]
219+
* `-t, --target PATH`: Shared object (.so) target file path to execute [default: /home/cali/repos/solfuzz-agave/target/debug/libsolfuzz_agave.so]
219220
* `-f, --add-feature TEXT`: List of feature pubkeys to force add to the fixtures.
220221
* `-r, --remove-feature TEXT`: List of feature pubkeys to force remove from the fixtures.
221222
* `-k, --rekey-feature TEXT`: List of feature pubkeys to rekey in the fixtures, formatted 'old/new' (e.g. `--rekey-feature old/new`).
@@ -239,7 +240,7 @@ $ solana-test-suite regenerate-fixtures [OPTIONS]
239240
**Options**:
240241

241242
* `-i, --input PATH`: Either a file or directory containing messages [required]
242-
* `-t, --target PATH`: Shared object (.so) target file path to execute [default: /data/mjain/repos/solfuzz-agave/target/release/libsolfuzz_agave.so]
243+
* `-t, --target PATH`: Shared object (.so) target file path to execute [default: /home/cali/repos/solfuzz-agave/target/debug/libsolfuzz_agave.so]
243244
* `-o, --output-dir PATH`: Output directory for regenerated fixtures [required]
244245
* `-d, --dry-run`: Only print the fixtures that would be regenerated
245246
* `-f, --add-feature TEXT`: List of feature pubkeys to force add to the fixtures.
@@ -268,8 +269,8 @@ $ solana-test-suite run-tests [OPTIONS]
268269

269270
* `-i, --input PATH`: Input protobuf file or directory of protobuf files [required]
270271
* `-h, --default-harness-type TEXT`: Harness type to use for Context protobufs [default: InstrHarness]
271-
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /data/mjain/repos/solfuzz-agave/target/release/libsolfuzz_agave.so]
272-
* `-t, --target PATH`: Shared object (.so) target file paths [default: /data/mjain/repos/firedancer/build/native/clang/lib/libfd_exec_sol_compat.so]
272+
* `-s, --solana-target PATH`: Solana (or ground truth) shared object (.so) target file path [default: /home/cali/repos/solfuzz-agave/target/debug/libsolfuzz_agave.so]
273+
* `-t, --target PATH`: Shared object (.so) target file paths [default: /home/cali/repos/firedancer-testing/build/native/gcc/lib/libfd_exec_sol_compat.so]
273274
* `-o, --output-dir PATH`: Output directory for test results [default: test_results]
274275
* `-p, --num-processes INTEGER`: Number of processes to use [default: 4]
275276
* `-r, --randomize-output-buffer`: Randomizes bytes in output buffer before shared library execution

src/test_suite/test_suite.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,18 @@ def execute(
8888
"-n",
8989
help="Do not print effects to stdout",
9090
),
91+
enable_vm_tracing: bool = typer.Option(
92+
False,
93+
"--enable-vm-tracing",
94+
"-evm",
95+
help="Enable FD VM tracing",
96+
),
9197
):
9298
# Initialize output buffers and shared library
9399
initialize_process_output_buffers(randomize_output_buffer=randomize_output_buffer)
100+
if enable_vm_tracing:
101+
os.environ["ENABLE_VM_TRACING"] = "1"
102+
94103
try:
95104
lib = ctypes.CDLL(shared_library)
96105
lib.sol_compat_init(log_level)

0 commit comments

Comments
 (0)