Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve performance on subsequent runs by precompiling executable #50

Open
Jeehut opened this issue May 4, 2022 · 0 comments
Open

Improve performance on subsequent runs by precompiling executable #50

Jeehut opened this issue May 4, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@Jeehut
Copy link
Member

Jeehut commented May 4, 2022

Problem Statement

Currently, when running the Swift script even with no changes to the Script file, the whole Swift compiler is started fresh leading to the script taking a few seconds and letting one wait longer than needed.

Suggested Solution

Instead of simply running the Script file via swift-sh, wrap it in a command line container and build an executable file. Then reuse that executable file as long as the Script file contents are identical, e.g. by saving its SHA hash. This is like a caching mechanism.

@Jeehut Jeehut added the enhancement New feature or request label May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant