JM: TypeInference: nop GETGLOBAL and CALLGLOBAL on known values

RESOLVED FIXED

Status

()

defect
RESOLVED FIXED
9 years ago
6 years ago

People

(Reporter: bhackett, Unassigned)

Tracking

(Blocks 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

Reporter

Description

9 years ago
The shell testcase in bug 514765 consists primarily of a dispatch loop and functions which manipulate a few global arrays (e.g. MEM[...]).  These globals are never reassigned, so the addresses of the arrays could be baked into the code and the global accesses removed.  This would behave similarly to method write barriers, except that (a) no shape check on the global is needed (good for speed and robustness) (b) applies to objects other than methods, even constant primitives and (c) loading code which can change the global (e.g. through eval) triggers recompilation rather than shape change.

Benchmarks do this at least a little bit; the main benefit there is for CALLGLOBAL/CALLGNAME, which most calls in SS use and which are known singleton objects.
Reporter

Updated

9 years ago
Reporter

Updated

9 years ago
No longer blocks: 557407
Do we do this, nowadays?
Flags: needinfo?(bhackett1024)
Reporter

Comment 2

6 years ago
Yes.
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Flags: needinfo?(bhackett1024)
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.