Closed Bug 2087854 Opened 17 days ago Closed 15 days ago

[loong64] Clean up method delegation in Loong64's MacroAssembler

Categories

(Core :: JavaScript Engine: JIT, task)

Other
Unspecified
task

Tracking

()

RESOLVED FIXED
161 Branch
Tracking Status
firefox161 --- fixed

People

(Reporter: csmantle, Assigned: csmantle)

References

(Blocks 1 open bug)

Details

Attachments

(10 external files)

Currently, some methods in MacroAssembler for Loong64, especially those of the shared interface, use hand-rolled immediate loading and instruction selection.

For example, MacroAssembler::addPtr(ImmWord imm, Register dest) should have been one single call to MacroAssemblerLOONG64::ma_add_d(Register rd, Register rj, ImmWord imm), instead of the current temps.Acquire(); movePtr(); addPtr() sequence.

Cleaning these up would help their callers enjoy the existing, smarter isel, and also unify future optimizations into one centralized site.

storePtr(ImmWord, ...) is kept untouched, which is consistent with
RISCV64's current approach.

This is pure hygiene, since mozilla:BitwiseCast is currently
transitively pulled in.

See Also: → 2088092
Pushed by webmaster@csmantle.top: https://github.com/mozilla-firefox/firefox/commit/3bdf29bbde00 https://hg.mozilla.org/integration/autoland/rev/ea04f3bf5cd0 [loong64] Part 1: Unify delegation of MacroAssembler::mul{32,64,Ptr}. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/d7052b45fa03 https://hg.mozilla.org/integration/autoland/rev/31f61eceed8a [loong64] Part 2: Unify delegation of MacroAssembler::add{64,Ptr}. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/94088a1681c0 https://hg.mozilla.org/integration/autoland/rev/7191e4fec8ec [loong64] Part 3: Unify delegation of MacroAssembler::sub64. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/0e2d20f79853 https://hg.mozilla.org/integration/autoland/rev/2a2cd5edfcf0 [loong64] Part 4: Unify word-sized shortcuts for ma_{and,or,xor}. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/92a410f49cf7 https://hg.mozilla.org/integration/autoland/rev/e028dada5dd8 [loong64] Part 5: Unify delegation of store{8,16,32}(Imm32, Address). r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/d628a34d1290 https://hg.mozilla.org/integration/autoland/rev/2ac0f9d080c5 [loong64] Part 6: Use already-allocated temp in MacroAssembler::mulDoublePtr. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/ae83ea2d6e09 https://hg.mozilla.org/integration/autoland/rev/71353581275d [loong64] Part 7: Implement scratch-free MacroAssembler::mulBy3. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/01a5aeab7a7d https://hg.mozilla.org/integration/autoland/rev/00b439c5f047 [loong64] Part 8: Delegate expansion of immediate multiplication to MASM. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/5911acd3aac2 https://hg.mozilla.org/integration/autoland/rev/8e24ad8f153e [loong64] Part 9: Use expandable ma_mul_d in ma_mul32TestOverflow(..., Imm32, ...). r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/2ec07e22398d https://hg.mozilla.org/integration/autoland/rev/2f38afde114f [loong64] Part 10: (Drive-by) Add missing #include "mozilla/Casting.h" to MacroAssembler-loong64.cpp. r=spidermonkey-reviewers,jandem
QA Whiteboard: [qa-triage-done-c162/b161]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: