Skip to content

Add dharamendrak submission#32

Open
dharamendrak wants to merge 4 commits into
mpage:mainfrom
dharamendrak:dharamendrak-submission
Open

Add dharamendrak submission#32
dharamendrak wants to merge 4 commits into
mpage:mainfrom
dharamendrak:dharamendrak-submission

Conversation

@dharamendrak

Copy link
Copy Markdown

Free-threaded scheduler: persistent thread-pool of 24 workers on queue.SimpleQueue, chain fast-path for linear DAGs, inline-execution to skip queue round-trips on chain links, and heap-based LPT priority only when both max_fan_in and max_fan_out exceed worker count.

Submission Checklist

  • My file is named submissions/<github_username>.py.
  • My submission runs locally.
  • My output matches the expected output.
  • I did not hardcode the final output.

Approach Description

[PLACEHOLDER: describe your approach, concurrency strategy, and any tradeoffs]

Free-threaded scheduler: persistent thread-pool of 24 workers on
queue.SimpleQueue, chain fast-path for linear DAGs, inline-execution
to skip queue round-trips on chain links, and heap-based LPT priority
only when both max_fan_in and max_fan_out exceed worker count.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

✅ Results

Metric Value
Speedup 5.781842638037996x
Passed true
Graphs 5

Per-graph results

Graph Speedup Status
chain.json 0.9890295941833903x
diamond.json 14.163327486852207x
realistic.json 21.91083374294908x
tree.json 20.714834151094532x
wide.json 20.78368500981925x

View the leaderboard

dharamendrak and others added 3 commits May 16, 2026 13:14
Collect newly-ready children into a list under the lock, then enqueue
them after release. The queue's internal lock no longer nests inside
the main bookkeeping lock — less serialization at 24 workers.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Collect heap drains into a list under the lock, then push to queue
afterwards. Keeps the queue's internal lock out of the main critical
section, mirroring the FIFO worker change.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
For pure linear DAGs, detect via one pass building a successor dict
instead of materializing the full dependents map first. Saves the
O(V+E) construction cost on chain graphs.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant