Skip to content

[docs] Update static constructor list in system/lib/README.md - #28476

Open
juj wants to merge 1 commit into
emscripten-core:mainfrom
juj:docs_system_lib_ctors
Open

juj wants to merge 1 commit into
emscripten-core:mainfrom
juj:docs_system_lib_ctors

Conversation

@juj

@juj juj commented Dec 1, 2026

Copy link
Copy Markdown
Collaborator
  • Add the missing emscripten_wasm_worker_main_thread_initialize (48) and __emscripten_environ_constructor (100) constructors.
  • Replace "asan init (??)" with the actual constructor: asan.module_ctor, generated by LLVM's AddressSanitizer pass at priority 50 (kAsanEmscriptenCtorAndDtorPriority).
  • Turn the file references into GitHub links.

- Add the missing emscripten_wasm_worker_main_thread_initialize (48) and
  __emscripten_environ_constructor (100) constructors.
- Replace "asan init (??)" with the actual constructor: asan.module_ctor,
  generated by LLVM's AddressSanitizer pass at priority 50
  (kAsanEmscriptenCtorAndDtorPriority).
- Turn the file references into GitHub links.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Comment thread system/lib/README.md
- 100: `__emscripten_environ_constructor` ([libc/musl/src/env/__environ.c][__environ.c])
- 100: `WasmFS wasmFS` ([wasmfs/wasmfs.cpp][wasmfs.cpp])

Priorities 0 - 100 are reserved for system libraries and user-level

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you split this sentence so it reads correctly. How about:

"Priorities 0 - 100 are reserved for system libraries. User-level constructors should all run at 101 and above .."

This branch has not been deployed

No deployments
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.

2 participants