Closed
Bug 1344476
Opened 7 years ago
Closed 7 years ago
Add helper function to emit JSOP_POP or JSOP_POPN for given amount
Categories
(Core :: JavaScript Engine, enhancement)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla55
Tracking | Status | |
---|---|---|
firefox55 | --- | fixed |
People
(Reporter: arai, Assigned: arai)
Details
Attachments
(1 file)
7.66 KB,
patch
|
shu
:
review+
|
Details | Diff | Splinter Review |
JSOP_POP is single byte, and JSOP_POPN is 3 bytes, so using JSOP_POP is shorter for popping 1 or 2 values. it would be better adding dedicated function that receives the amount of values to pop and emit better opcode sequence to it.
Assignee | ||
Updated•7 years ago
|
status-firefox54:
affected → ---
Assignee | ||
Comment 1•7 years ago
|
||
regarding bug 1147371 comment #36 > I chose |pop; pop| because it's 2 bytes, and |popn 2| is 3 bytes. added BytecodeEmitter::emitPopN that emits JSOP_POP when popping 1 or 2 values, and JSOP_POPN for other cases, and used emitPopN where popping possibly multiple values.
Comment 2•7 years ago
|
||
Comment on attachment 8844763 [details] [diff] [review] Add BytecodeEmitter::emitPopN to emit shorter bytecode for given pop count. Review of attachment 8844763 [details] [diff] [review]: ----------------------------------------------------------------- Nice, thanks.
Attachment #8844763 -
Flags: review?(shu) → review+
Assignee | ||
Comment 3•7 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/5dff3bf590ba88c906073e0a22a9f9b33a77b927 Bug 1344476 - Add BytecodeEmitter::emitPopN to emit shorter bytecode for given pop count. r=shu
Comment 4•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/5dff3bf590ba
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
status-firefox55:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
You need to log in
before you can comment on or make changes to this bug.
Description
•