Submit Search
Upload
V8 javascript engine for フロントエンドデベロッパー
•
10 likes
•
5,946 views
Taketoshi 青野健利
Follow
V8 javascript engine がどうjavascriptを最適化し、実行するかの概要
Read less
Read more
Software
Report
Share
Report
Share
1 of 77
Download now
Download to read offline
Recommended
Google V8 engine
Google V8 engine
Xuân Thu Nguyễn
Amazon Elastcsearch Service 소개 및 활용 방법 (윤석찬)
Amazon Elastcsearch Service 소개 및 활용 방법 (윤석찬)
Amazon Web Services Korea
Enabling Vectorized Engine in Apache Spark
Enabling Vectorized Engine in Apache Spark
Kazuaki Ishizaki
Security Testing with OWASP ZAP in CI/CD - Simon Bennetts - Codemotion Amster...
Security Testing with OWASP ZAP in CI/CD - Simon Bennetts - Codemotion Amster...
Codemotion
Linux Binary Exploitation - Return-oritend Programing
Linux Binary Exploitation - Return-oritend Programing
Angel Boy
OWASP Poland Day 2018 - Frans Rosen - Attacking modern web technologies
OWASP Poland Day 2018 - Frans Rosen - Attacking modern web technologies
OWASP
OWASP AppSecEU 2018 – Attacking "Modern" Web Technologies
OWASP AppSecEU 2018 – Attacking "Modern" Web Technologies
Frans Rosén
XXE: How to become a Jedi
XXE: How to become a Jedi
Yaroslav Babin
Recommended
Google V8 engine
Google V8 engine
Xuân Thu Nguyễn
Amazon Elastcsearch Service 소개 및 활용 방법 (윤석찬)
Amazon Elastcsearch Service 소개 및 활용 방법 (윤석찬)
Amazon Web Services Korea
Enabling Vectorized Engine in Apache Spark
Enabling Vectorized Engine in Apache Spark
Kazuaki Ishizaki
Security Testing with OWASP ZAP in CI/CD - Simon Bennetts - Codemotion Amster...
Security Testing with OWASP ZAP in CI/CD - Simon Bennetts - Codemotion Amster...
Codemotion
Linux Binary Exploitation - Return-oritend Programing
Linux Binary Exploitation - Return-oritend Programing
Angel Boy
OWASP Poland Day 2018 - Frans Rosen - Attacking modern web technologies
OWASP Poland Day 2018 - Frans Rosen - Attacking modern web technologies
OWASP
OWASP AppSecEU 2018 – Attacking "Modern" Web Technologies
OWASP AppSecEU 2018 – Attacking "Modern" Web Technologies
Frans Rosén
XXE: How to become a Jedi
XXE: How to become a Jedi
Yaroslav Babin
Smart Join Algorithms for Fighting Skew at Scale
Smart Join Algorithms for Fighting Skew at Scale
Databricks
Cryptography 101 for Java Developers - JavaZone2019
Cryptography 101 for Java Developers - JavaZone2019
Michel Schudel
Apache Spark At Scale in the Cloud
Apache Spark At Scale in the Cloud
Databricks
Dangling DNS records takeover at scale
Dangling DNS records takeover at scale
Chandrapal Badshah
Understanding Memory Management In Spark For Fun And Profit
Understanding Memory Management In Spark For Fun And Profit
Spark Summit
Productizing Structured Streaming Jobs
Productizing Structured Streaming Jobs
Databricks
Amazon S3 Best Practice and Tuning for Hadoop/Spark in the Cloud
Amazon S3 Best Practice and Tuning for Hadoop/Spark in the Cloud
Noritaka Sekiyama
Hive tuning
Hive tuning
Michael Zhang
DNS hijacking using cloud providers – No verification needed
DNS hijacking using cloud providers – No verification needed
Frans Rosén
Introduction to Spark with Python
Introduction to Spark with Python
Gokhan Atil
A Tale of Three Apache Spark APIs: RDDs, DataFrames, and Datasets with Jules ...
A Tale of Three Apache Spark APIs: RDDs, DataFrames, and Datasets with Jules ...
Databricks
How to understand and analyze Apache Hive query execution plan for performanc...
How to understand and analyze Apache Hive query execution plan for performanc...
DataWorks Summit/Hadoop Summit
Web Cache Deception Attack
Web Cache Deception Attack
Omer Gil
Why your Spark job is failing
Why your Spark job is failing
Sandy Ryza
An Introduction to Higher Order Functions in Spark SQL with Herman van Hovell
An Introduction to Higher Order Functions in Spark SQL with Herman van Hovell
Databricks
Efficient Spark Analytics on Encrypted Data with Gidon Gershinsky
Efficient Spark Analytics on Encrypted Data with Gidon Gershinsky
Databricks
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
Frans Rosén
Logstash
Logstash
Rajgourav Jain
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
CODE BLUE
Polyglot payloads in practice by avlidienbrunn at HackPra
Polyglot payloads in practice by avlidienbrunn at HackPra
Mathias Karlsson
Living with garbage
Living with garbage
lucenerevolution
Living with Garbage by Gregg Donovan at LuceneSolr Revolution 2013
Living with Garbage by Gregg Donovan at LuceneSolr Revolution 2013
Gregg Donovan
More Related Content
What's hot
Smart Join Algorithms for Fighting Skew at Scale
Smart Join Algorithms for Fighting Skew at Scale
Databricks
Cryptography 101 for Java Developers - JavaZone2019
Cryptography 101 for Java Developers - JavaZone2019
Michel Schudel
Apache Spark At Scale in the Cloud
Apache Spark At Scale in the Cloud
Databricks
Dangling DNS records takeover at scale
Dangling DNS records takeover at scale
Chandrapal Badshah
Understanding Memory Management In Spark For Fun And Profit
Understanding Memory Management In Spark For Fun And Profit
Spark Summit
Productizing Structured Streaming Jobs
Productizing Structured Streaming Jobs
Databricks
Amazon S3 Best Practice and Tuning for Hadoop/Spark in the Cloud
Amazon S3 Best Practice and Tuning for Hadoop/Spark in the Cloud
Noritaka Sekiyama
Hive tuning
Hive tuning
Michael Zhang
DNS hijacking using cloud providers – No verification needed
DNS hijacking using cloud providers – No verification needed
Frans Rosén
Introduction to Spark with Python
Introduction to Spark with Python
Gokhan Atil
A Tale of Three Apache Spark APIs: RDDs, DataFrames, and Datasets with Jules ...
A Tale of Three Apache Spark APIs: RDDs, DataFrames, and Datasets with Jules ...
Databricks
How to understand and analyze Apache Hive query execution plan for performanc...
How to understand and analyze Apache Hive query execution plan for performanc...
DataWorks Summit/Hadoop Summit
Web Cache Deception Attack
Web Cache Deception Attack
Omer Gil
Why your Spark job is failing
Why your Spark job is failing
Sandy Ryza
An Introduction to Higher Order Functions in Spark SQL with Herman van Hovell
An Introduction to Higher Order Functions in Spark SQL with Herman van Hovell
Databricks
Efficient Spark Analytics on Encrypted Data with Gidon Gershinsky
Efficient Spark Analytics on Encrypted Data with Gidon Gershinsky
Databricks
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
Frans Rosén
Logstash
Logstash
Rajgourav Jain
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
CODE BLUE
Polyglot payloads in practice by avlidienbrunn at HackPra
Polyglot payloads in practice by avlidienbrunn at HackPra
Mathias Karlsson
What's hot
(20)
Smart Join Algorithms for Fighting Skew at Scale
Smart Join Algorithms for Fighting Skew at Scale
Cryptography 101 for Java Developers - JavaZone2019
Cryptography 101 for Java Developers - JavaZone2019
Apache Spark At Scale in the Cloud
Apache Spark At Scale in the Cloud
Dangling DNS records takeover at scale
Dangling DNS records takeover at scale
Understanding Memory Management In Spark For Fun And Profit
Understanding Memory Management In Spark For Fun And Profit
Productizing Structured Streaming Jobs
Productizing Structured Streaming Jobs
Amazon S3 Best Practice and Tuning for Hadoop/Spark in the Cloud
Amazon S3 Best Practice and Tuning for Hadoop/Spark in the Cloud
Hive tuning
Hive tuning
DNS hijacking using cloud providers – No verification needed
DNS hijacking using cloud providers – No verification needed
Introduction to Spark with Python
Introduction to Spark with Python
A Tale of Three Apache Spark APIs: RDDs, DataFrames, and Datasets with Jules ...
A Tale of Three Apache Spark APIs: RDDs, DataFrames, and Datasets with Jules ...
How to understand and analyze Apache Hive query execution plan for performanc...
How to understand and analyze Apache Hive query execution plan for performanc...
Web Cache Deception Attack
Web Cache Deception Attack
Why your Spark job is failing
Why your Spark job is failing
An Introduction to Higher Order Functions in Spark SQL with Herman van Hovell
An Introduction to Higher Order Functions in Spark SQL with Herman van Hovell
Efficient Spark Analytics on Encrypted Data with Gidon Gershinsky
Efficient Spark Analytics on Encrypted Data with Gidon Gershinsky
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
The Secret Life of a Bug Bounty Hunter – Frans Rosén @ Security Fest 2016
Logstash
Logstash
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
XSS Attacks Exploiting XSS Filter by Masato Kinugawa - CODE BLUE 2015
Polyglot payloads in practice by avlidienbrunn at HackPra
Polyglot payloads in practice by avlidienbrunn at HackPra
Similar to V8 javascript engine for フロントエンドデベロッパー
Living with garbage
Living with garbage
lucenerevolution
Living with Garbage by Gregg Donovan at LuceneSolr Revolution 2013
Living with Garbage by Gregg Donovan at LuceneSolr Revolution 2013
Gregg Donovan
Building a SIMD Supported Vectorized Native Engine for Spark SQL
Building a SIMD Supported Vectorized Native Engine for Spark SQL
Databricks
Living With Garbage
Living With Garbage
Gregg Donovan
Kick your database_to_the_curb_reston_08_27_19
Kick your database_to_the_curb_reston_08_27_19
confluent
Price of an Error
Price of an Error
Andrey Karpov
All you need to know about the JavaScript event loop
All you need to know about the JavaScript event loop
Saša Tatar
Javascript Everywhere
Javascript Everywhere
Pascal Rettig
Full Stack Scala
Full Stack Scala
Ramnivas Laddad
12 Monkeys Inside JS Engine
12 Monkeys Inside JS Engine
ChengHui Weng
R and cpp
R and cpp
Romain Francois
NoSQL and JavaScript: a love story
NoSQL and JavaScript: a love story
Alexandre Morgaut
Tips and tricks for building high performance android apps using native code
Tips and tricks for building high performance android apps using native code
Kenneth Geisshirt
Apache Spark, the Next Generation Cluster Computing
Apache Spark, the Next Generation Cluster Computing
Gerger
Event-driven IO server-side JavaScript environment based on V8 Engine
Event-driven IO server-side JavaScript environment based on V8 Engine
Ricardo Silva
Android RenderScript on LLVM
Android RenderScript on LLVM
John Lee
Apache Spark for Library Developers with William Benton and Erik Erlandson
Apache Spark for Library Developers with William Benton and Erik Erlandson
Databricks
V8
V8
changehee lee
Будь первым
Будь первым
FDConf
200 Open Source Projects Later: Source Code Static Analysis Experience
200 Open Source Projects Later: Source Code Static Analysis Experience
Andrey Karpov
Similar to V8 javascript engine for フロントエンドデベロッパー
(20)
Living with garbage
Living with garbage
Living with Garbage by Gregg Donovan at LuceneSolr Revolution 2013
Living with Garbage by Gregg Donovan at LuceneSolr Revolution 2013
Building a SIMD Supported Vectorized Native Engine for Spark SQL
Building a SIMD Supported Vectorized Native Engine for Spark SQL
Living With Garbage
Living With Garbage
Kick your database_to_the_curb_reston_08_27_19
Kick your database_to_the_curb_reston_08_27_19
Price of an Error
Price of an Error
All you need to know about the JavaScript event loop
All you need to know about the JavaScript event loop
Javascript Everywhere
Javascript Everywhere
Full Stack Scala
Full Stack Scala
12 Monkeys Inside JS Engine
12 Monkeys Inside JS Engine
R and cpp
R and cpp
NoSQL and JavaScript: a love story
NoSQL and JavaScript: a love story
Tips and tricks for building high performance android apps using native code
Tips and tricks for building high performance android apps using native code
Apache Spark, the Next Generation Cluster Computing
Apache Spark, the Next Generation Cluster Computing
Event-driven IO server-side JavaScript environment based on V8 Engine
Event-driven IO server-side JavaScript environment based on V8 Engine
Android RenderScript on LLVM
Android RenderScript on LLVM
Apache Spark for Library Developers with William Benton and Erik Erlandson
Apache Spark for Library Developers with William Benton and Erik Erlandson
V8
V8
Будь первым
Будь первым
200 Open Source Projects Later: Source Code Static Analysis Experience
200 Open Source Projects Later: Source Code Static Analysis Experience
More from Taketoshi 青野健利
ServiceWorkerとES6 Modules時代のTypescript開発考察
ServiceWorkerとES6 Modules時代のTypescript開発考察
Taketoshi 青野健利
javascriptのデータ構造の話
javascriptのデータ構造の話
Taketoshi 青野健利
非同期javascriptの過去と未来
非同期javascriptの過去と未来
Taketoshi 青野健利
仮想DOMの実装とパフォーマンス
仮想DOMの実装とパフォーマンス
Taketoshi 青野健利
JavascriptのGC入門
JavascriptのGC入門
Taketoshi 青野健利
V8 Iginition Interpreter
V8 Iginition Interpreter
Taketoshi 青野健利
GraphQL with React
GraphQL with React
Taketoshi 青野健利
Jspmとtypescriptで開発する
Jspmとtypescriptで開発する
Taketoshi 青野健利
React and-rx
React and-rx
Taketoshi 青野健利
WebWorker and Atomics
WebWorker and Atomics
Taketoshi 青野健利
More from Taketoshi 青野健利
(10)
ServiceWorkerとES6 Modules時代のTypescript開発考察
ServiceWorkerとES6 Modules時代のTypescript開発考察
javascriptのデータ構造の話
javascriptのデータ構造の話
非同期javascriptの過去と未来
非同期javascriptの過去と未来
仮想DOMの実装とパフォーマンス
仮想DOMの実装とパフォーマンス
JavascriptのGC入門
JavascriptのGC入門
V8 Iginition Interpreter
V8 Iginition Interpreter
GraphQL with React
GraphQL with React
Jspmとtypescriptで開発する
Jspmとtypescriptで開発する
React and-rx
React and-rx
WebWorker and Atomics
WebWorker and Atomics
Recently uploaded
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
aagamshah0812
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
Fatema Valibhai
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
MyIntelliSource, Inc.
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
Jhone kinadey
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
ABDERRAOUF MEHENNI
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
Wave PLM
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
9953056974 Low Rate Call Girls In Saket, Delhi NCR
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
shikhaohhpro
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
ICS
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
mohitmore19
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
SolGuruz
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
anilsa9823
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
Willy Marroquin (WillyDevNET)
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Call Girls In Delhi Whatsup 9873940964 Enjoy Unlimited Pleasure
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
panagenda
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
anilsa9823
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
MyIntelliSource, Inc.
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
kalichargn70th171
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Alberto González Trastoy
Recently uploaded
(20)
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
HR Software Buyers Guide in 2024 - HRSoftware.com
HR Software Buyers Guide in 2024 - HRSoftware.com
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
SyndBuddy AI 2k Review 2024: Revolutionizing Content Syndication with AI
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
CALL ON ➥8923113531 🔝Call Girls Badshah Nagar Lucknow best Female service
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
V8 javascript engine for フロントエンドデベロッパー
1.
V8 javascript engine
2.
: @brn (
) : : Cyberagent RightSegment AI Messenger : http://abcdef.gets.b6n.ch/ Twitter: https://twitter.com/brn227
3.
V8 V8 Google javascript
Google Chrome javascript
4.
V8 V8 • •
Hidden Class • Inline Caching • GC • 2016 • CPU Mips Arm X64 X86 7
5.
V8 javascript
6.
V8 Code base V8
108 C++ …
7.
V8 Source AST Bytecode
Graph Assembly
8.
Parsing V8 AST AST
AbstractSyntaxTree
9.
Abstract Syntax Tree if (x) { x = 100 }
10.
Abstract Syntax Tree IF CONDITION THEN BLOCK EXPRESSION STATEMENT ASSIGN VAR PROXY (X)
LITERAL (100) if (x) { x = 100
11.
Parsing Web javascript
12.
Parsing V8
13.
Lazy Parsing function x() {return 1;} FUNCTION(X)
14.
Lazy Parsing function x() {return 1;} x() FUNCTION NAME (x) RETURN LITERAL(1)
15.
Lazy Parsing V8
16.
PreParsing v8::internal::PreParser • •
17.
Dive into Parsing V8
Parsing https://docs.google.com/presentation/d/1b- ALt6W01nIxutFVFmXMOyd_6ou_6qqP6S0Prmb1iDs/present? slide=id.p
18.
Abstract Syntax Tree V8
yacc lex
19.
AST Rewriter V8 AST
20.
AST Rewriter javascript Spread var x = [1,2,3]; var y = […x]; V8
AltJS
21.
AST Rewriter do { $R = []; for ($i of x) %AppendElement($R, $i); $R } // src/parsing/parser.cc do for-of
22.
Abstract Syntax Tree AST
V8 AST AST …
23.
Abstract Syntax Tree var x = 100
24.
Abstract Syntax Tree var EXPRESSION STATEMENT CALL RUNTIME [IniOalizeVarGlobal] LITERAL (x) LITERAL (100) x 100 ?
25.
Abstract Syntax Tree V8
Runtime C++ AST AST
26.
AST to Bytecode AST
AST Bytecode V8 Bytecode 1Byte Bytecode VM Ignition
27.
Igniton V8 Ignition Bytecode AST
28.
Igniton Ignition CPU Ignition BytecodeHandler Bytecode
29.
Igniton
30.
// 擬似的なjavascriptコード ! var Bytecodes = [0,1,2,3] var index = 0; function dispatch(next) { BytecodeHandlers[next](); } const BytecodeHandlers = { ['0']() {...; dispatch(Bytecodes[index++])}, ['1']() {...; dispatch(Bytecodes[index++])}, ['2']() {...; dispatch(Bytecodes[index++])}, ['3']() {...; dispatch(Bytecodes[index++])} } const firstBytecode = Bytecodes[index++]; BytecodeHandlers[firstBytecode](firstBytecode);
31.
Igniton Dispatch Table 00 01
02 04 08 0f 10 10 Node Node Node MachineCode MachineCode IGNITION_HANDLER Entry Function(Machine Code) グラフからコードを生成 生成したコードを、 DispatchTableの対応する バイトコードのインデックスへ 登録
32.
Igniton Ignition AST V8
AST v8::internal::AstVisitor<Subclass> AstVisitor Visitor AST
33.
Visitor Pattern class Visitor { void Visit(Ast* ast) { ast->Accept(this); } void VisitXXX(XXX* ast) { ast->property->accept(this); } } class Ast(XXX) { void Accept(Visitor* visitor) { visitor->VisitXXX(this) } }
34.
Igniton Bytecode BytecodeArray BytecodeArray
35.
Igniton Dispatch Table Entry Function(Machine
Code) BytecodeArray Dispatch Tableから対応するHandlerを取り出して実行 0 1 3 4 5 6 7 8 8 6 1
36.
Code Generation V8 CodeStub Builtins Runtime BytecodeHandler
37.
Code Generation Bytecode Bytecode
BytecodeHandler
38.
IGNITION_HANDLER(JumpIfToBooleanFalse, InterpreterAssembler) {! Node*
value = GetAccumulator();! // Accumulatorの値を取得! Node* relative_jump = BytecodeOperandUImmWord(0);! // 引数のoperandを取得! Label if_true(this), if_false(this);! BranchIfToBooleanIsTrue(value, &if_true, &if_false);! // valueがtrueならif_true、falseならif_false! Bind(&if_true);! Dispatch();! Bind(&if_false);! // operandのbytecodeまでjump! Jump(relative_jump);! }!
39.
Code Generation Graph
40.
Code Generation C++ DSL
41.
IGNITION_HANDLER(ForInContinue, InterpreterAssembler) {! ...! Branch(WordEqual(index,
cache_length), &if_true, &if_false);! Bind(&if_true);! {! SetAccumulator(BooleanConstant(false));! Goto(&end);! }! Bind(&if_false);! {! SetAccumulator(BooleanConstant(true));! Goto(&end);! }! ...! }!
42.
Code Generation MacroAssembler MacroAssembler Assembler V8
masm MacroAssembler
43.
#define __ ACCESS_MASM(masm)! ! static
void Generate_StackOverflowCheck(...) {! ! __ LoadRoot(kScratchRegister, Heap::kRealStackLimitRootIndex);! __ movp(scratch, rsp);! ! __ subp(scratch, kScratchRegister);! __ sarp(scratch, Immediate(kPointerSizeLog2));! ! __ cmpp(scratch, num_args);! ! __ j(less_equal, stack_overflow, stack_overflow_distance);! }!
44.
Code Generation GraphResolver CodeGenerator
Graph MacroAssembler Assembler
45.
Code Generation MacroAssembler Graph
Graph • CodeStubAssembler • CodeAssembler • RawMachineAssembler • MachineOperatorBuilder
46.
Code Generation e.x Load CodeStubAssembler::Load CodeAssembler::raw_assembler()->Load() RawMachineAssembler::Load AddNode(MachineAssembler::Load()) Graph Leaf Node
47.
Optimization javascript javascript javascript V8 JIT(
)
48.
Optimization V8 3 •
Hidden Class • Inline Caching • TurboFan
49.
Hidden Class javascript class
prototype • •
50.
Hidden Class V8 function Point(x, y) { this.x = x; this.y = y }; var point = new Point(1, 1); Point
51.
Map V8 • •
• Map Map Map
52.
Map function Point(x, y) { this.x = x; this.y = y; } Map FixedArray [ {a: {offset: 0}}, {b: {offset: 1}} ]
53.
Map javascript
54.
Map Transition V8 transition
Map Map
55.
Map Transition function Point(x, y) { this.x = x; this.y = y; } Map FixedArray [ {x: {offset: 0}}, {y: {offset: 1}}, transiOon: {address: …} ] var x = new Point(1, 1); x.z = 1; Map FixedArray [ {x: {offset: 0}}, {y: {offset: 1}}, {z: {offset: 2}} ] transition
56.
Inline Caching Inline Caching
57.
class X {add()
{return 1}}! class Y {add() {return 2}}! var m = [new X(), new X(), new Y()];! for (let i = 0; i < m.length; i++) {! m[i].add();! }! !
58.
Inline Caching 初回 V8 add Receiver Map Cached address 1. Search 2.
Check 4. Cache 3. Call
59.
Inline Caching 二回目以降 V8 add Receiver Map Cached address 1. Search
and Call
60.
Inline Caching Inline Caching
4 • Premonomorphic • Monomorphic • Polymorphic • Megamorphic
61.
Premonomorphic Premonomorphic IC Stub
62.
Monomorphic Monomorphic Receiver IC
63.
Polymorphic Polymorphic Receiver Polymorphic Map
Monomorphic IC
64.
Megamorphic Megamorphic
65.
(Load/Store)IC_Miss LoadIC_Miss StoreIC_Miss IC C++
66.
(Load/Store)IC_Miss 二回目以降 V8 add Receiver (y) Map Cached address (x) 1. Search 2. Compare
Map x !== y 3. (Load/Store)IC_Miss
67.
Optimized Compilation V8 Bytecode
Generic Runtime
68.
Hot Spot V8 •
•
69.
Loop Tracing V8 V8 OnStackReplacement
70.
On Stack Replacement for (let i = 0; i < 10000; i++) { doSomething(i); } JumpLoop LoopHeader SlowCode
FastCode PC( )
71.
Function Call Tracing Ignition
Return Bytecode BytecodeHandler Interrupt Body
72.
Function Interruption function Y() { … } RETURN OP Replace Body しきい値チェック
73.
TurboFan V8 Graph Graph
TurboFan
74.
TurboFan TurboFan • Loop
peeling / Loop elimination • Escape analysis • Lowering • Effect and control linearize • Dead code elimination • Control flow optimization • Memory optimization
75.
Deoptimization Map overlow 0
… V8 Bytecode
76.
Pipeline OpOmize Assembler TurboFan Source AST Parser Bytecode Graph IgniOon Compile Optimization Deoptimization
77.
V8 GC V8
GC
Download now