Skip to content

Optimize emscripten targets with emcc #36899

Closed

Description

With today's asmjs and wasm targets, we optimize the LLVM IR ourselves, and pass that IR to emcc. emcc has its own optimization options though, including but not limited to LLVM's optimization passes, so we should probably leave all optimizations to emcc. Likewise LTO should be delegated to emscripten.

So we need to change the backend to treat these targets as unoptimized in LLVM, and instead pass the optimization arguments to emcc during the "link" step. This may involve adding new features to the target spec, or possibly just special casing emscripten in the backend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    E-help-wantedCall for participation: Help is requested to fix this issue.Call for participation: Help is requested to fix this issue.O-emscriptenTarget: 50% off wasm32-unknown-musl. the savings come out of stdio.h, but hey, you get SDL!Target: 50% off wasm32-unknown-musl. the savings come out of stdio.h, but hey, you get SDL!O-wasmTarget: WASM (WebAssembly), http://webassembly.org/Target: WASM (WebAssembly), http://webassembly.org/

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions