Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Debugger Statementについて
Search
Taketoshi Aono(青野健利 a.k.a brn)
March 20, 2018
Programming
1
550
Debugger Statementについて
Debugger Statementの紹介と使い方
proposal-debugger-operandsについて
Taketoshi Aono(青野健利 a.k.a brn)
March 20, 2018
Tweet
Share
More Decks by Taketoshi Aono(青野健利 a.k.a brn)
See All by Taketoshi Aono(青野健利 a.k.a brn)
document.write再考
brn
6
2.9k
Parsing Javascript
brn
12
9.1k
JSON & Object Tips
brn
1
430
CA 1Day Youth Bootcamp for Frontend LT
brn
0
860
Modern TypeScript
brn
2
770
javascript - behind the scene
brn
3
700
tc39 proposals
brn
0
820
プロダクト開発とTypeScript
brn
8
2.8k
React-Springでリッチなアニメーション
brn
1
640
Other Decks in Programming
See All in Programming
Java Webフレームワークの現状 / java web framework at burikaigi
kishida
9
2k
DMMオンラインサロンアプリのSwift化
hayatan
0
270
Lookerは可視化だけじゃない。UIコンポーネントもあるんだ!
ymd65536
1
140
rails newと同時に型を書く
aki19035vc
6
750
個人アプリを2年ぶりにアプデしたから褒めて / I just updated my personal app, praise me!
lovee
0
300
AWS Lambda functions with C# 用の Dev Container Template を作ってみた件
mappie_kochi
0
220
Оптимизируем производительность блока Казначейство
lamodatech
0
990
盆栽転じて家具となる / Bonsai and Furnitures
aereal
0
2.2k
『改訂新版 良いコード/悪いコードで学ぶ設計入門』活用方法−爆速でスキルアップする!効果的な学習アプローチ / effective-learning-of-good-code
minodriven
29
4.8k
バックエンドのためのアプリ内課金入門 (サブスク編)
qnighy
7
1.5k
watsonx.ai Dojo #6 継続的なAIアプリ開発と展開
oniak3ibm
PRO
0
270
振り返れば奴(Cline)がいる
keiyagi
0
130
Featured
See All Featured
Code Review Best Practice
trishagee
65
17k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
The Invisible Side of Design
smashingmag
299
50k
The Language of Interfaces
destraynor
156
24k
Music & Morning Musume
bryan
46
6.3k
How to train your dragon (web standard)
notwaldorf
89
5.8k
Building Flexible Design Systems
yeseniaperezcruz
328
38k
Making the Leap to Tech Lead
cromwellryan
133
9.1k
Facilitating Awesome Meetings
lara
51
6.2k
Building Adaptive Systems
keathley
39
2.4k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.2k
The Power of CSS Pseudo Elements
geoffreycrofte
75
5.4k
Transcript
Debugger Statement
Name @brn (ꫬꅿ⨳ⵃ) Occupation ؿٗٝزؒٝسؒٝآص،٥ط؎ذ؍ـؒٝآص، Company Cyberagent ،سذؙأةآؔ AI Messenger
OSS Contributor of V8 About http://info.b6n.ch
What is debugger? debugger statementהכ؝٦س⚥ח剅ֻֿהדرغحؖ饯⹛׃ـ ٖ؎ؙ׃גֻ堣腉
const ret = foo()! if (ret) {! debugger;! }!
None
In V8 BytecodeהJIT؝٦سדⰟ鸐ךⳢ椚遤ֲ
Bytecode DebuggerعٝسָٓDebuggerغ؎ز؝٦س鋅אֽה Runtime_HandleDebuggerStatementㄎן⳿׃גծ✲ח涫 ꐮׁגְ؝٦ٕغحؙㄎן⳿ׅ In V8
JIT Code JIT⻉ך麓玎דㄏ⟀ך⽃秪⻉הְֲ剑黝⻉ָ遤ָծך麓 玎דDebugger Statementכ⯓玎ך Runtime_HandleDebuggerStatementㄎן⳿׃ך؝٦سפה湫 䱸㢌䳔ׁ In V8
Break Point אְדזךדBreakpointחאְג ـٓؐؠך؎ٝألؙةַ䭷㹀ֿׅהָדֹ • In V8
None
In V8 DebugBreakכDebugger Statementה麩גוֿח䯏Ⰵַׁ ַזְךד✲חRuntime_HandleDebuggerStatementהַח כ㢌䳔דֹזְ
Bytecode DebugBreakعٝسָٓDebug::HandleDebugBreakㄎן⳿׃ גծ穠卓Debugger StatementהずׄⳢ椚遤ֲ In V8
JIT Code(X64) ـٖ؎ؙه؎ٝزכׅץגInt3ㄏ⟀ָ涪遤ׁגSIGTRAP䒷ֹ 饯ֿׅ interruptָ饯ֿהStackGuard::HandleInterruptsָㄎן⳿ׁ גծַֿDebug::HandleDebugBreakפ In V8
Future ⯓傈ךTC39 Meetingדproposal-debugger-operandָStage1ח ז
proposal-debugger-operand ـٖ؎ؙه؎ٝزךؚٕ٦ف⻉ח״♧俕ON/OFFծ勴⟝➰ֹـ ٖ؎ؙך鏣㹀瘝ָ遤ִ Future
const log = (v) => {! debugger { group: 'logging'
};! console.log(v);! };!
const route = (httpRequest) => {! debugger {! test: ()
=> httpRequest.tracing || !isProduction! };! console.log(v);! };!
㹋騧 涪儗חכDebugger㙵鴥דծٔٔ٦أ儗ח嶊ׅ Webpack⢪גזUglifyָ嶊׃גֻ v4ך㜥さכmode productionד䩛ח嶊ִ
class Logger {! fatal() {! console.error("Error");! debugger;! }! }!
תה ⢪ג➂㼰זְ⽩韋דָׅ涪儗ח⢪ֲה穠圓嚂דׅ