Skip to content

Commit

Permalink
Try tracing DLL loads
Browse files Browse the repository at this point in the history
  • Loading branch information
kartik-s committed Dec 13, 2024
1 parent 240543a commit 0a3cec5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ jobs:
working-directory: ../sbcl
run: |
choco install sbcl -source tools-for-build
choco install procmon
- name: build sbcl
working-directory: ../sbcl
env:
Expand Down Expand Up @@ -88,6 +89,7 @@ jobs:
popd
popd
D:\a\_temp\setup-msys2\msys2.CMD -c "gcc -Wall -o example example.c -lcalc -lsbcl_librarian"
.\trace.ps1
D:\a\_temp\setup-msys2\msys2.CMD -c 'echo "(+ 1 2)" | PATH="$PATH:$LIBSBCL_PATH" ./example'
D:\a\_temp\setup-msys2\msys2.CMD -c 'echo "(+ 1 2)" | PATH="$PATH:$LIBSBCL_PATH" $CONDA_PREFIX/python ./example.py'
D:\a\_temp\setup-msys2\msys2.CMD -c 'PATH="$PATH:$LIBSBCL_PATH:/mingw64/bin" $CONDA_PREFIX/python ./exhaust_heap.py | grep "returned to Python after heap exhaustion (attempt 1)"'
Binary file added examples/libcalc/libcalc.pmc
Binary file not shown.
6 changes: 6 additions & 0 deletions examples/libcalc/trace.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Procmon.exe /BackingFile log.pml /AcceptEula /LoadConfig libcalc.pmc /Minimized /Quiet
Start-Process -FilePath Procmon.exe /WaitForIdle -Wait
Start-Process -FilePath ./example.exe -Wait
Start-Process -FilePath Procmon.exe /Terminate -Wait
Procmon.exe /OpenLog log.pml /LoadConfig libcalc.pmc /SaveAs log.csv /SaveApplyFilter
cat log.csv

0 comments on commit 0a3cec5

Please sign in to comment.