QuickJS#1764
Conversation
There was a problem hiding this comment.
Pull request overview
This PR introduces CI coverage for building BabylonNative with the QuickJS JavaScript engine, primarily by switching the JsRuntimeHost dependency to a QuickJS-capable revision and wiring new QuickJS jobs into the GitHub Actions workflows.
Changes:
- Point
FetchContentforJsRuntimeHostat a QuickJS branch/revision. - Add new CI jobs to build with QuickJS on macOS, Win32, Linux, and Android.
- Extend the reusable Win32 and macOS build workflows to accept/select the QuickJS engine.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
CMakeLists.txt |
Switches JsRuntimeHost source to a QuickJS-capable fork/revision. |
.github/workflows/ci.yml |
Adds new QuickJS jobs across macOS/Win32/Linux/Android in CI. |
.github/workflows/build-win32.yml |
Adds QuickJS handling for napi-type to set the right CMake define and suffix. |
.github/workflows/build-macos.yml |
Adds a js-engine input and forwards it into the CMake configure step. |
| // Defer scene construction to a fresh macrotask so | ||
| // eval()/createScene() run at a shallow native-stack | ||
| // depth instead of nested inside the native snippet | ||
| // load callback. Deep scenes otherwise pile onto the | ||
| // native XHR dispatch frames and can overflow engines | ||
| // with a small C stack (e.g. QuickJS). |
There was a problem hiding this comment.
Wouldn't Babylon users hit the same problem? This isn't unique to validation tests, right?
There was a problem hiding this comment.
yes, it's a stack overflow issue. This should happen with other JS engines as well. debug/release build also have influence on the number of stack element count. QuickJS stack elements are bigger so the overflow happens sooner.
| FetchContent_Declare(JsRuntimeHost | ||
| GIT_REPOSITORY https://github.com/BabylonJS/JsRuntimeHost.git | ||
| GIT_TAG f07d99119887131a89a3580ada9c2a8dbc7782f7) | ||
| GIT_REPOSITORY https://github.com/CedricGuillemet/JsRuntimeHost.git |
There was a problem hiding this comment.
Just a reminder to switch this before merge.
Uh oh!
There was an error while loading. Please reload this page.