Closed Bug 1578677 Opened 5 years ago Closed 5 years ago

Support --enable-rust-simd for standalone SpiderMonkey builds

Categories

(Firefox Build System :: General, enhancement)

enhancement
Not set
normal

Tracking

(firefox71 fixed)

RESOLVED FIXED
mozilla71
Tracking Status
firefox71 --- fixed

People

(Reporter: hsivonen, Assigned: hsivonen)

References

Details

Attachments

(1 file)

Bug 1490601 makes Rust functions available to SpiderMonkey such that they gain SIMD acceleration when SpiderMonkey is built as part of libxul with --enable-rust-simd.

There should be a way to specify --enable-rust-simd on a standalone SpiderMonkey build and have it cause the simd-accel feature to be set on the encoding_c crate.

This should be the default for SpiderMonkey benchmarks in CI.

Summary: Support --enable-rust-simd for standalone Firefox builds → Support --enable-rust-simd for standalone SpiderMonkey builds
Blocks: 1578339

I've verified with a debugger that the patch makes --enable-rust-simd work both for Firefox builds and for standalone SpiderMonkey builds.

What do I need to change to make CI use --enable-rust-simd when building standalone SpiderMonkey?

Assignee: nobody → hsivonen
Status: NEW → ASSIGNED
Flags: needinfo?(mh+mozilla)
Flags: needinfo?(mh+mozilla) → needinfo?(sphink)

Sorry, I haven't looked closely enough to be able to answer these questions yet. I'll just ask.

Normally, we prefer to keep the default standalone spidermonkey builds as close to the configuration of Firefox as possible. Is --enable-rust-simd the default when building with Firefox (where available)? If so, can it be defaulted to on in a standalone build as well? Our default configuration already includes Rust code, so I don't think there's any reason not to enable it if it's already defaulted to on with Firefox.

If there is some reason why it should not be the default, then you'd want to add it to the "configure-args" values in most or all of js/src/devtools/automation/variants/*. The changes in the patch you currently have posted should be reviewed by a build peer. I think glandium would be fine with including any variants/* changes in the same patch, or you could split it out and I could review it separately (but I'm just going to rubberstamp it r=me unless I disagree with your reasons for not making it default to on.)

Thank you for thinking of the standalone JS shell builds!

Flags: needinfo?(sphink)

(In reply to Steve Fink [:sfink] [:s:] from comment #3)

Is --enable-rust-simd the default when building with Firefox (where available)?

It's not the default if you pull the source and build. It is the default for CI and for the builds we ship.

This way, if nightly rustc breaks SIMD, I don't have all developers complaining at me right after everyone does rustup update and there's time to deal with things until we update the CI toolchain.

If there is some reason why it should not be the default, then you'd want to add it to the "configure-args" values in most or all of js/src/devtools/automation/variants/*.

Thanks.

Pushed by hsivonen@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/328d3abf28b5
Support --enable-rust-simd for standalone SpiderMonkey builds. r=glandium
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla71
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: