17 lines
1.3 KiB
Markdown
17 lines
1.3 KiB
Markdown
# Cryo: memory, save points, hot patches
|
|
|
|
The **Cryo** window (right, the snowflake) uses ext-cryo, without changing your code.
|
|
|
|

|
|
|
|
| Tab | What it does |
|
|
|---|---|
|
|
| **Live** | tick "Run with memory metrics" and run: memory over time, live objects, GC; **Snapshot** of the running program |
|
|
| **Files** | the `.cryo` snapshots: what retains memory per class, allocation sites, biggest retainers, duplicates, cycles, leak hints; two ticked: what grew and the line that keeps it; **why is it alive** (paths from a root) |
|
|
| **Save points** | **Freeze here** saves the whole running program (game loop, level, player…); **Resume here** runs it again exactly there, even after the code changed (then the scene alone) |
|
|
| **Hot patch / console** | the method under the cursor replaces the running one, constants set live, a PHP console inside the running game (`$engine`, `$scene`) |
|
|
| **Sandbox** | PHP run in an isolated sandbox (timeout, memory limit) |
|
|
| **A/B** | your change against the code before, the same run profiled for both, compared per changed function; Claude or OpenCode can propose the change |
|
|
|
|
**Reset** deletes `var/cryo` and `var/ab`. Needs the project's JumPHP 0.5.68 or newer. Claude has the same tools (`cryo_*`,
|
|
`ab_*`). More: [docs/cryo.md](../cryo.md).
|