icfpc-trace-optimizer

Profiles Littleman .man programs via official WASM per-tick traces to locate execution hotspots and benchmark local rewrites.

1|Updated Jul 30, 2026
One-click install
npx skills add https://github.com/d-experts/public-icfpc-2026 --skill icfpc-trace-optimizer-d-experts
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: icfpc-trace-optimizer
Source: https://github.com/d-experts/public-icfpc-2026/tree/main/member-18/.agents/skills/icfpc-trace-optimizer
Command: npx skills add https://github.com/d-experts/public-icfpc-2026 --skill icfpc-trace-optimizer-d-experts

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Optimizing ICFPC Littleman .man programs blindly is slow and error-prone: without knowing which blank cells the runner actually traversed or where I/O wait stalls occur, rewrites are guesswork. This Skill profiles representative public cases with the official WASM per-tick trace, separates traversed from unobserved blank cells, and pinpoints execution and I/O-wait hotspots so local structural rewrites can be benchmarked and judged before adoption. ## Core Features & Use Cases - Trace-guided profiling: Runs profile-trace.mjs against benchmark cases from trace-guided-v1.json to produce agent-readable JSON maps with room/cell execution coverage and s/S/r/R/U receive/send wait statistics. - Local rewrite exploration: Uses optimize-trace.mjs to search non-rigid neighborhoods around a critical pipe, emitting a candidate only when official analysis, structural validation, full public judging, and exact score improvement all pass. - Diagnostic judging and telemetry: Validates candidates with judge.mjs in diagnostic-only mode and records every run, artifact, and metric through skill-telemetry.mjs. - Use Case: Given a slow History Lesson submission, profile its representative public case, identify the longest runner wait hotspot by room/cell coordinates, generate a local structural rewrite candidate, and confirm an exact score improvement via diagnostic judging before handing off for submission. ## Quick Start Ask the agent to profile a chosen .man solution's representative public case with the official trace, identify the I/O-wait hotspots, and benchmark a local structural rewrite candidate.

Frequently Asked Questions about icfpc-trace-optimizer

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I profile a Littleman .man program with execution traces?▼

Run member-18/tools/profile-trace.mjs against a representative public case selected from benchmarks/trace-guided-v1.json. The output JSON includes a coverageMap with sourceRows and stateRows showing traversed blanks, unobserved blanks, and per-cell runner ticks.

How do I find I/O wait hotspots in an ICFPC Littleman solution?▼

The trace profile aggregates receive/send wait ticks for s, S, r, R, and U instructions, including episodes and maximum consecutive waits. Hotspots are reported with room and cell coordinates so you can target local structural rewrites.

When should I use trace-guided optimization instead of layout optimization?▼

Use trace-guided optimization when you need execution-path and wait-hotspot evidence to justify local rewrites. Layout-only compression, pipeopt-style reintroduction, or footprint-only goals belong to the separate icfpc-layout-optimizer skill.

Does the optimizer automatically save or submit improved candidates?▼

No. Candidates are only validated through diagnostic-only judging with --no-save --no-submit. Saving to the best store or official submission happens only when the user explicitly requests it, via the icfpc-local-judge handoff procedure.

Why does optimize-trace.mjs refuse to run on my profile JSON?▼

The explorer checks that the profile's source digest matches the input .man file. A mismatch means the profile is stale, so you must re-profile the current source before searching for rewrite candidates.