[FEATURE]: Enable Bun bytecode option for faster executable startup time #3166

Open
opened 2026-02-16 17:38:56 -05:00 by yindo · 1 comment
Owner

Originally created by @remorses on GitHub (Nov 27, 2025).

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

Currently opencode takes about 1 second to start which is slow. We could use Bun bytecode true option during executable creation to make it a bit faster.

Currently it cannot be enabled because it does not work with top level await.

Originally created by @remorses on GitHub (Nov 27, 2025). ### Feature hasn't been suggested before. - [x] I have verified this feature I'm about to request hasn't been suggested before. ### Describe the enhancement you want to request Currently opencode takes about 1 second to start which is slow. We could use Bun bytecode true option during executable creation to make it a bit faster. Currently it cannot be enabled because it does not work with top level await.
yindo added the discussion label 2026-02-16 17:38:56 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Nov 27, 2025):

This issue might be a duplicate of existing issues or related to similar optimization efforts. Please check:

  • #820: Slow chat startup with blocking npx commands - addresses startup performance from a different angle
  • #2411: mcp init is slow in bun, but fast in nodejs - highlights Bun-specific startup performance issues
  • #4525: MCP startup optimization, only start if usable in project - complementary optimization approach to reduce work at startup

These issues all contribute to the broader goal of reducing OpenCode startup time. The bytecode optimization you're proposing could be particularly beneficial given the Bun-specific performance issues documented in #2411.

Feel free to ignore if this feature request addresses a specific use case not covered by the related issues above.

@github-actions[bot] commented on GitHub (Nov 27, 2025): This issue might be a duplicate of existing issues or related to similar optimization efforts. Please check: - #820: Slow chat startup with blocking npx commands - addresses startup performance from a different angle - #2411: mcp init is slow in bun, but fast in nodejs - highlights Bun-specific startup performance issues - #4525: MCP startup optimization, only start if usable in project - complementary optimization approach to reduce work at startup These issues all contribute to the broader goal of reducing OpenCode startup time. The bytecode optimization you're proposing could be particularly beneficial given the Bun-specific performance issues documented in #2411. Feel free to ignore if this feature request addresses a specific use case not covered by the related issues above.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#3166