Skip to content

druntime: Update to wasi-sdk 34 - #5266

Open
QuantumSegfault wants to merge 1 commit into
ldc-developers:masterfrom
QuantumSegfault:update-wasi-sdk-34
Open

druntime: Update to wasi-sdk 34#5266
QuantumSegfault wants to merge 1 commit into
ldc-developers:masterfrom
QuantumSegfault:update-wasi-sdk-34

Conversation

@QuantumSegfault

Copy link
Copy Markdown
Contributor

Updates the supported version of wasi-libc to the one distributed by wasi-sdk 34.

Also updates the version of Wasmtime used by CI to 48.0.1

The diff is smaller than it normally would be, as I incorporated some changes between 33 and 34 when I initially implemented (inadvertently).

Phobos is not yet updated to make use of flockfile. This will be done alongside other changes needed for WASIp3 later on (i.e. once it actually matters).

@QuantumSegfault
QuantumSegfault force-pushed the update-wasi-sdk-34 branch 4 times, most recently from 34fce3b to 0a08725 Compare August 25, 2026 16:22
@QuantumSegfault

Copy link
Copy Markdown
Contributor Author

@thewilsonator

All good now. Ready to merge

Comment thread runtime/druntime/src/core/sync/event.d Outdated

// Test single-thread (non-shared) use.
version (WASI) {} // WASI is single-threaded
else // (& futex wait w/ timeout traps in single-threaded builds)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm wondering if this shouldn't be handled in the implementation then, as I did for Emscripten.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

That probably makes more sense. It's just pthread_cond_timedwait that's problematic for WASI.

I've updated it.

alias uint_fast8_t = ubyte; ///
alias int_fast16_t = short; ///
alias uint_fast16_t = ushort; ///
alias int_fast16_t = int; ///

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nitpick: maybe add a comment that this highly unintuitive thing is the correct one?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

How come? This is far from the only case. In fact, it seems that fast16_t is rarely short. The BSDs, Solaris, Linux, (non-MinGW) Windows all have differing fast16.

Darwin and MinGW being the exceptions, rather than the rule here.

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.

4 participants