AI helps you reading Science
AI generates interpretation videos
AI extracts and analyses the key points of the paper to generate videos automatically
AI parses the academic lineage of this thesis
AI extracts a summary of this paper
PLDI, no. 6 (2014): 496-507
PPT (Upload PPT)
- The advent of mobile computing and, more recently, wearable computing means that processors necessarily have to get simpler
- This dynamism presents new challenges to the compiler.
- Properties in the prototype can either be accessed via inheritance through the “child” object, or directly through the prototype property in the constructor function object
- When method bindings are completely decoupled from types, inline cache hits on method calls require loading the method pointer from the object
- Method Bindings
The second culprit behind type unpredictability is encoding the bindings of the methods of an object into its hidden class.
- Function bindings are encoded into hidden classes in V8 by storing the values of function properties in the hidden class itself, rather than the offsets in the object like regular properties.
- The authors completely decouple method bindings from types by disallowing the storage of function property values in the hidden class altogether.
- When method bindings are completely decoupled from types, inline cache hits on method calls require loading the method pointer from the object.
- Only the binding to the syntactic function is needed for the purposes of calling a method
- The authors use the JSBench benchmark suite .
- Each benchmark in JSBench records about one minute worth of user interactions on a single representative webpage from the website, starting from the page load.
- The authors briefly characterize the popular benchmark suites Kraken 1.1 , Octane , and SunSpider 0.9.1 , to see differences with JSBench
- 6.1 Impact of The authors' Compiler Modifications
- V8 encodes into types two pieces of information unrelated to object structure: (1) the inherited prototype and (2) method bindings
- Table1: Heap memory allocated and heap collection time for JSBench (top) and the other benchmark suites (bottom)
- Inheritance is supported by having the special property __proto__ in the object pointing to the prototype object at object construction time
- ECMAScript. http://www.ecmascript.org/.
- Kraken Benchmarks. http://krakenbenchmark.mozilla.org/.
- Octane Benchmarks. https://developers.google.com/octane.
- SpiderMonkey Project. https://developer.mozilla.org/en-
- SunSpider Benchmarks. http://www.webkit.org/perf/sunspider/sunspider.html.
- J. Castanos, D. Edelsohn, K. Ishizaki, P. Nagpurkar, T. Nakatani, T. Ogasawara, and P. Wu. On the benefits and pitfalls of extending a statically typed language JIT compiler for dynamic scripting languages. In OOPSLA, 2012.
- C. Chambers, D. Ungar, and E. Lee. An efficient implementation of SELF, a dynamically-typed object-oriented language based on prototypes. In OOPSLA, 1989.
- L. P. Deutsch and A. M. Schiffman. Efficient implementation of the Smalltalk-80 system. In POPL, 1984.
- U. Holzle, C. Chambers, and D. Ungar. Optimizing dynamically-typed object-oriented languages with polymorphic inline caches. In ECOOP, 1991.
- C.-K. Luk, R. Cohn, R. Muth, H. Patil, A. Klauser, G. Lowney, S. Wallace, V. J. Reddi, and K. Hazelwood. Pin: Building customized program analysis tools with dynamic instrumentation. In PLDI, 2005.
- M. Mehrara and S. Mahlke. Dynamically accelerating clientside web applications through decoupled execution. In CGO, 2011.