Closed Bug 1316815 Opened 8 years ago Closed 8 years ago

Wasm baseline: Make RegI32, RegI64, RegF32, RegF64 inherit from, not wrap, Register, Register64, FloatRegister

Categories

(Core :: JavaScript Engine: JIT, defect, P5)

defect

Tracking

()

RESOLVED FIXED
mozilla53
Tracking Status
firefox53 --- fixed

People

(Reporter: lth, Assigned: away)

References

Details

Attachments

(1 file)

Making the change specified in the Summary will probably simplify the compiler some (and will reduce code) while maintaining the strong typing we get from these classes, stronger than what using the Register/Register64/FloatRegister types directly would give us. This is probably mostly grunt work with a broad impact, all the ".reg" phrases will have to go away.
Dipping a toe into wasm. Grunt work accepted!
Assignee: nobody → dmajor
Attached patch patch v1Splinter Review
This was mostly automated. Here were my steps: * s/.reg.reg/.foo/g * s/.reg//g * s/.foo/.reg/g * Fix up allocInt64 and freeInt64, where I over-corrected * Fix up OutOfLineTruncateF32OrF64ToI32::generate, where the arms of the ternary were no longer the same type Lars, do you have any suggestions for what builds and/or testing I should do?
Attachment #8811100 - Flags: review?(lhansen)
Comment on attachment 8811100 [details] [diff] [review] patch v1 Review of attachment 8811100 [details] [diff] [review]: ----------------------------------------------------------------- This seems very plausible. (You'll have a little merge pain because of some things I landed today, but so will I for an outstanding fix after you land this :) To test, I usually just run "./jit_test.py ../build-debug/dist/bin/js wasm asm.js" in js/src/jit-test to test wasm changes, it'll test both the regular compiler and the baseline compiler. All of that runs on check-in, too, on all platforms. If you want to be more comprehensive, build Firefox, enable both wasm and wasm_baseline in about:config, clone https://github.com/WebAssembly/website, and load demo/AngryBots/index.html, you should be able to play the game without crashing.
Attachment #8811100 - Flags: review?(lhansen) → review+
Thanks for the pointers. I pulled a fresh m-i and reapplied my substitutions from scratch. jit-tests and the demo game look good.
Pushed by dmajor@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/2cd76a9f89d3 Make RegI32, RegI64, RegF32, RegF64 inherit from, not wrap, Register, Register64, FloatRegister. r=lth
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla53
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: