apache / datafusion

Apache DataFusion SQL Query Engine
https://datafusion.apache.org/
Apache License 2.0
6.33k stars 1.2k forks source link

"recursive" Dependency Causes "section too large" Error When Compiling for wasm #13513

Open berkaysynnada opened 21 hours ago

berkaysynnada commented 21 hours ago

Describe the bug

I am encountering a problem when trying to compile wasmtest with the following command:

RUSTFLAGS="-C link-arg=--max-memory=4294967296" cargo build --release --target wasm32-unknown-unknown

The build fails with the following error:

error: failed to build archive at `.../target/wasm32-unknown-unknown/release/deps/libpsm-cc498cff4b514c30.rlib`: LLVM error: section too large

The following warnings were emitted during compilation:

warning: psm@0.1.24: warning: ...

I suspect the issue is related to the psm dependency, and it is coming with recursive crate, which was introduced in #13310. I am unsure if this error can be resolved without removing or replacing this dependency.

To Reproduce

Go in datafusion/wasmtest andrun cargo build --target wasm32-unknown-unknown

Expected behavior

It needs to compile

Additional context

I tried again after removing recursive dep, and it works successfully