You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Swift compiler crashes when building a C target for wasm32-unknown-wasi. This issue doesn't seem to occur when building for other targets.
Reproduction
git clone https://github.com/kkk669/swiftwasm-no-prototype-example
cd swiftwasm-no-prototype-example
swift build --experimental-swfit-sdk wasm32-unknown-wasi
Building for debugging...
[6/6] Compiling foobar foobar.swift
Build complete! (1.42s)
Environment
$ uname -aLinux Brown-rhinoceros-beetle 6.6.3-413.asahi.fc39.aarch64+16k #1 SMP PREEMPT_DYNAMIC Sat Jan 27 17:19:54 UTC 2024 aarch64 GNU/Linux
$ cat /etc/os-releaseNAME="Fedora Linux Asahi Remix"VERSION="39 (Thirty Nine)"ID=fedora-asahi-remixID_LIKE=fedoraVERSION_ID=39VERSION_CODENAME=""PLATFORM_ID="platform:f39"PRETTY_NAME="Fedora Linux Asahi Remix 39 (Thirty Nine)"ANSI_COLOR="0;38;2;60;110;180"LOGO=fedora-logo-iconCPE_NAME="cpe:/o:fedoraproject:fedora-asahi-remix:39"DEFAULT_HOSTNAME="fedora"HOME_URL="https://fedora-asahi-remix.org/"DOCUMENTATION_URL="https://docs.fedoraproject.org/en-US/fedora/f39/system-administrators-guide/"SUPPORT_URL="https://discussion.fedoraproject.org/c/neighbors/asahi/asahi-help/94"BUG_REPORT_URL="https://bugzilla.redhat.com/"REDHAT_BUGZILLA_PRODUCT="Fedora"REDHAT_BUGZILLA_PRODUCT_VERSION=39REDHAT_SUPPORT_PRODUCT="Fedora"REDHAT_SUPPORT_PRODUCT_VERSION=39
$ swift --versionSwift version 6.0-dev (LLVM d1625da873daa4c, Swift bae6450bf96dceb)Target: aarch64-unknown-linux-gnu
$ swift experimental-sdk listDEVELOPMENT-SNAPSHOT-2024-03-14-a-wasm
Rejecting calls to no-prototype declared functions sounds reasonable to me because WebAssembly has strict signature check.
But crashing the compiler process is apparently problematic, it should emit diagnostics instead.
Description
The Swift compiler crashes when building a C target for
wasm32-unknown-wasi
. This issue doesn't seem to occur when building for other targets.Reproduction
git clone https://github.com/kkk669/swiftwasm-no-prototype-example cd swiftwasm-no-prototype-example swift build --experimental-swfit-sdk wasm32-unknown-wasi
For more detailed logs, please see the README.md:
https://github.com/kkk669/swiftwasm-no-prototype-example
Stack dump
Full logs: https://github.com/kkk669/swiftwasm-no-prototype-example
Expected behavior
Environment
Additional information
The following modification resolves the issue.
related links:
The text was updated successfully, but these errors were encountered: