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
マルチスレッディングの仕組み (2016)
Search
4D Japan
November 01, 2024
Technology
0
13
マルチスレッディングの仕組み (2016)
4D Japan
November 01, 2024
Tweet
Share
More Decks by 4D Japan
See All by 4D Japan
Unicodeの話 (2007)
miyako
0
3
Unicodeの話 (2008)
miyako
0
7
Google Apps Integration (2012)
miyako
0
5
Creating Custom Widgets (2012)
miyako
0
3
地図データの活用 (2016)
miyako
0
10
オブジェクトフィールド (2016)
miyako
0
3
新しい変換タグ (2016)
miyako
0
6
プログラムコードの最適化 (2016)
miyako
0
10
自動アップグレード (2016)
miyako
0
2
Other Decks in Technology
See All in Technology
OCI Security サービス 概要
oracle4engineer
PRO
0
6.5k
これまでの計測・開発・デプロイ方法全部見せます! / Findy ISUCON 2024-11-14
tohutohu
3
360
スクラムチームを立ち上げる〜チーム開発で得られたもの・得られなかったもの〜
ohnoeight
2
350
サイバーセキュリティと認知バイアス:対策の隙を埋める心理学的アプローチ
shumei_ito
0
380
Incident Response Practices: Waroom's Features and Future Challenges
rrreeeyyy
0
160
信頼性に挑む中で拡張できる・得られる1人のスキルセットとは?
ken5scal
2
530
オープンソースAIとは何か? --「オープンソースAIの定義 v1.0」詳細解説
shujisado
5
560
rootlessコンテナのすゝめ - 研究室サーバーでもできる安全なコンテナ管理
kitsuya0828
3
380
【若手エンジニア応援LT会】ソフトウェアを学んできた私がインフラエンジニアを目指した理由
kazushi_ohata
0
150
TanStack Routerに移行するのかい しないのかい、どっちなんだい! / Are you going to migrate to TanStack Router or not? Which one is it?
kaminashi
0
580
Platform Engineering for Software Developers and Architects
syntasso
1
510
iOS/Androidで同じUI体験をネ イティブで作成する際に気をつ けたい落とし穴
fumiyasac0921
1
110
Featured
See All Featured
Happy Clients
brianwarren
98
6.7k
It's Worth the Effort
3n
183
27k
Designing for humans not robots
tammielis
250
25k
Visualization
eitanlees
145
15k
Thoughts on Productivity
jonyablonski
67
4.3k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
26
2.1k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Fireside Chat
paigeccino
34
3k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
44
2.2k
Building a Scalable Design System with Sketch
lauravandoore
459
33k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
232
17k
Transcript
ϚϧνεϨοσΟϯάͷΈ inside multi-threading Laurent Esnault, Vice President of Engineering ϩϗϯɾΤϊʔ
༻ޠղઆ
ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
• ϓϩηεಉ࢜ͰεέδϡʔϧΛཧ - ໌ࣔత·ͨ҉ࣔత*%-& ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
• ϓϩηεಉ࢜ͰεέδϡʔϧΛཧ - ໌ࣔత·ͨ҉ࣔత*%-& • ར༻Ͱ͖ΔίΞݸͷΈ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
• ϓϩηεಉ࢜ͰεέδϡʔϧΛཧ - ໌ࣔత·ͨ҉ࣔత*%-& • ར༻Ͱ͖ΔίΞݸͷΈ • ϢʔβʔΠϯλϑΣʔε0, ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
• ϓϩηεಉ࢜ͰεέδϡʔϧΛཧ - ໌ࣔత·ͨ҉ࣔత*%-& • ར༻Ͱ͖ΔίΞݸͷΈ • ϢʔβʔΠϯλϑΣʔε0, ϓϦΤϯϓςΟϒϞʔυ ίΦϖϥςΟϒϞʔυ
༻ޠղઆ
• ϓϩηεಉ࢜ͰεέδϡʔϧΛཧ - ໌ࣔత·ͨ҉ࣔత*%-& • ར༻Ͱ͖ΔίΞݸͷΈ • ϢʔβʔΠϯλϑΣʔε0, ϓϦΤϯϓςΟϒϞʔυ •
04͕εέδϡʔϧΛཧ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
• ϓϩηεಉ࢜ͰεέδϡʔϧΛཧ - ໌ࣔత·ͨ҉ࣔత*%-& • ར༻Ͱ͖ΔίΞݸͷΈ • ϢʔβʔΠϯλϑΣʔε0, ϓϦΤϯϓςΟϒϞʔυ •
04͕εέδϡʔϧΛཧ • ۭ͍͍ͯΔίΞΛͯ͢ར༻Ͱ͖Δ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
• ϓϩηεಉ࢜ͰεέδϡʔϧΛཧ - ໌ࣔత·ͨ҉ࣔత*%-& • ར༻Ͱ͖ΔίΞݸͷΈ • ϢʔβʔΠϯλϑΣʔε0, ϓϦΤϯϓςΟϒϞʔυ •
04͕εέδϡʔϧΛཧ • ۭ͍͍ͯΔίΞΛͯ͢ར༻Ͱ͖Δ • ϢʔβʔΠϯλϑΣʔε/( ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
ϓϦΤϯϓςΟϒϞʔυ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
U U $16 $16 ϓϦΤϯϓςΟϒϞʔυ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
ϓϩηε" U U $16 $16 *%-& ϓϦΤϯϓςΟϒϞʔυ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
ϓϩηε" ϓϩηε# U U $16 $16 *%-& *%-& ϓϦΤϯϓςΟϒϞʔυ ίΦϖϥςΟϒϞʔυ
༻ޠղઆ
ϓϩηε" ϓϩηε" ϓϩηε# U U $16 $16 *%-& *%-& ϓϦΤϯϓςΟϒϞʔυ
ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
ϓϩηε" ϓϩηε" ϓϩηε# U U $16 $16 U U $16
$16 *%-& *%-& ϓϦΤϯϓςΟϒϞʔυ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
ϓϩηε" ϓϩηε# ϓϩηε" ϓϩηε" ϓϩηε# U U $16 $16 U
U $16 $16 *%-& *%-& ϓϦΤϯϓςΟϒϞʔυ ίΦϖϥςΟϒϞʔυ ༻ޠղઆ
ϓϦΤϯϓςΟϒϞʔυ
ϓϦΤϯϓςΟϒϞʔυ • %#%
ϓϦΤϯϓςΟϒϞʔυ • %#% • 42-
ϓϦΤϯϓςΟϒϞʔυ • %#% • 42- • )551
σϞϯετϨʔγϣϯ %ϓϩηεΛϓϦΤϯϓςΟϒϞʔυͰ࣮ߦ͢Δ
BE PREPARED NOT SCARED ৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
BE PREPARED NOT SCARED • Ϗοτ൛ • ίϯύΠϧϞʔυ • ϓϦΤϯϓςΟϒରԠίϚϯυ
৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
BE PREPARED NOT SCARED • Ϗοτ൛ • ίϯύΠϧϞʔυ • ϓϦΤϯϓςΟϒରԠίϚϯυ
৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
BE PREPARED NOT SCARED • Ϗοτ൛ • ίϯύΠϧϞʔυ • ϓϦΤϯϓςΟϒରԠίϚϯυ
৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
ΦϯϥΠϯυΩϡϝϯτ
ΦϯϥΠϯυΩϡϝϯτ
࣮ߦϞʔυ
࣮ߦϞʔυ ϝιουϓϩύςΟ
• ϓϦΤϯϓςΟϒ࣮ߦՄ ࣮ߦϞʔυ ϝιουϓϩύςΟ
• ϓϦΤϯϓςΟϒ࣮ߦՄ • ϓϦΤϯϓςΟϒ࣮ߦෆՄ ࣮ߦϞʔυ ϝιουϓϩύςΟ
• ϓϦΤϯϓςΟϒ࣮ߦՄ • ϓϦΤϯϓςΟϒ࣮ߦෆՄ • ಛʹઃఆ͠ͳ͍ ࣮ߦϞʔυ ϝιουϓϩύςΟ
• ϓϦΤϯϓςΟϒ࣮ߦՄ • ϓϦΤϯϓςΟϒ࣮ߦෆՄ • ಛʹઃఆ͠ͳ͍ ࣮ߦϞʔυ ίϯύΠϥʔʹΑΔνΣοΫ ϝιουϓϩύςΟ
• ϓϦΤϯϓςΟϒ࣮ߦՄ • ϓϦΤϯϓςΟϒ࣮ߦෆՄ • ಛʹઃఆ͠ͳ͍ • ϓϦΤϯϓςΟϒରԠ ࣮ߦϞʔυ ίϯύΠϥʔʹΑΔνΣοΫ
ϝιουϓϩύςΟ
• ϓϦΤϯϓςΟϒ࣮ߦՄ • ϓϦΤϯϓςΟϒ࣮ߦෆՄ • ಛʹઃఆ͠ͳ͍ • ϓϦΤϯϓςΟϒରԠ • ϓϦΤϯϓςΟϒඇରԠ
࣮ߦϞʔυ ίϯύΠϥʔʹΑΔνΣοΫ ϝιουϓϩύςΟ
σϞϯετϨʔγϣϯ ࣮ߦϞʔυ
ॳΊʹݺΕΔ ϓϩδΣΫτϝιου͚ͩ มߋ͢Εྑ͍ ϙΠϯτ
BE PREPARED NOT SCARED • Ϗοτ൛ • ίϯύΠϧϞʔυ • ϓϦΤϯϓςΟϒରԠίϚϯυ
• Πϯλʔϓϩηεม༻ېࢭ • ϢʔβʔΠϯλϑΣʔεແ͠ ৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
BE PREPARED NOT SCARED • Ϗοτ൛ • ίϯύΠϧϞʔυ • ϓϦΤϯϓςΟϒରԠίϚϯυ
• Πϯλʔϓϩηεม༻ېࢭ • ϢʔβʔΠϯλϑΣʔεແ͠ ৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
ίΦϖϥςΟϒ
ίΦϖϥςΟϒ <>myVar:=<>myVar+1
ίΦϖϥςΟϒ <>myVar:=<>myVar+1 IDLE IDLE
ϓϦΤϯϓςΟϒ <>myVar:=<>myVar+1 <>myVar:=<>myVar+1 <>myVar:=<>myVar+1 <>myVar:=<>myVar+1 IDLE IDLE
ϓϦΤϯϓςΟϒ <>myVar:=<>myVar+1 <>myVar:=<>myVar+1 <>myVar:=<>myVar+1 <>myVar:=<>myVar+1 IDLE IDLE IDLE
<>myVar:=<>myVar+1 CLEAR SEMAPHORE("myVar") If(Not(Semaphore("myVar";1000))) ϓϦΤϯϓςΟϒ End if
ΠϯλʔϓϩηεΛΘͣʹͲ͏ͬͯ ϓϩηεؒͰใΛΓऔΓ͢Δͷ
$"--803,&3
$"--803,&3 • ໊લ͕͞ΕͨϝοηʔδϘοΫε
$"--803,&3 • ໊લ͕͞ΕͨϝοηʔδϘοΫε • ϝιουΛ࣮ߦ͢ΔͨΊͷϓϩηε
$"--803,&3 • ໊લ͕͞ΕͨϝοηʔδϘοΫε • ϝιουΛ࣮ߦ͢ΔͨΊͷϓϩηε • $"--803,&3ͰϝοηʔδΛಧ͚Δ - Ҿ/FXQSPDFTTʹࣅ͍ͯΔ -
ҙͷϓϩδΣΫτϝιου - ҙͷύϥϝʔλʔ
myWorker ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε
myWorker CALL WORKER("myWorker"; "myMethod";$param) ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε
myWorker CALL WORKER("myWorker"; "myMethod";$param) ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε
myWorker CALL WORKER("myWorker"; "myMethod";$param) ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε you’ve got mail!
myWorker ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε CALL WORKER("myWorker"; "myMethod";$param)
myWorker ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε CALL WORKER("myWorker"; "myMethod";$param)
myWorker ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε myMethod($param) CALL WORKER("myWorker"; "myMethod";$param)
myWorker ΞϓϦέʔγϣϯϓϩηε myWorkerϓϩηε CALL WORKER("myWorker"; "myMethod";$param)
σϞϯετϨʔγϣϯ ϓϩηεؒͷσʔλ௨৴
BE PREPARED NOT SCARED • Ϗοτ൛ • ίϯύΠϧϞʔυ • ϓϦΤϯϓςΟϒରԠίϚϯυ
• Πϯλʔϓϩηεม༻ېࢭ • ϢʔβʔΠϯλϑΣʔεແ͠ ৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
BE PREPARED NOT SCARED • Ϗοτ൛ • ίϯύΠϧϞʔυ • ϓϦΤϯϓςΟϒରԠίϚϯυ
• Πϯλʔϓϩηεม༻ېࢭ • ϢʔβʔΠϯλϑΣʔεແ͠ ৺ߏ͕͑େࣄ ҟมࡂΛʰාΕΔͳ४උͤΑʱ ʢถͷඪޠʣ
Ͳ͏ͬͯϓϦΤϯϓςΟϒϓϩηεͷ ϢʔβʔΠϯλϑΣʔεΛ࡞͢Δͷ
$"--'03.
$"--'03. • ΠϯυຖʹϝοηʔδϘοΫε
$"--'03. • ΠϯυຖʹϝοηʔδϘοΫε • ϑΥʔϜͷίϯςΩετͰϝιουΛ࣮ߦ͢Δ
$"--'03. • ΠϯυຖʹϝοηʔδϘοΫε • ϑΥʔϜͷίϯςΩετͰϝιουΛ࣮ߦ͢Δ • $"--'03.ͰϝοηʔδΛಧ͚Δ - Ҿ$"--803,&3ʹࣅ͍ͯΔ -
ҙͷϓϩδΣΫτϝιου - ҙͷύϥϝʔλʔ
myWindow ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ
myWindow CALL FORM($myWindow; "myMethod";$param) ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ
myWindow CALL FORM($myWindow; "myMethod";$param) ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ
myWindow CALL FORM($myWindow; "myMethod";$param) ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ you’ve got mail!
myWindow CALL FORM($myWindow; "myMethod";$param) ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ
myWindow CALL FORM($myWindow; "myMethod";$param) ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ
myWindow CALL FORM($myWindow; "myMethod";$param) ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ myMethod($param)
myWindow CALL FORM($myWindow; "myMethod";$param) ϓϩηε·ͨϫʔΧʔ myWindowΠϯυ
σϞϯετϨʔγϣϯ Πϯυؒͷϝοηʔδૹड৴
Ϗοτ൛
Ϗοτ൛ Windows Mac
v12 Ϗοτ൛ Windows Mac
v12 Ϗοτ൛ Windows Mac v13 OD BC
v12 Ϗοτ൛ Windows Mac v13 OD BC v15 OD BC
v12 v15 Rx Ϗοτ൛ Windows Mac v13 OD BC v15
OD BC
v12 v15 Rx v15 R5 Ϗοτ൛ Windows Mac v13 OD
BC v15 OD BC
v12 v15 Rx v15 R5 v16 Ϗοτ൛ Windows Mac v13
OD BC v15 OD BC
ϓϦΤϯϓςΟϒϞʔυ ΫϥΠΞϯταʔόʔ σʔλϕʔε 42- )551 TUBUJD EZOBNJD ϥϯήʔδ
·ͱΊ
·ͱΊ • Ϗοτ൛ ֦ுੑ ͓ΑͼॲཧྗΞοϓͷجૅ εέʔϥϏϦςΟ ύϑΥʔϚϯε
·ͱΊ • Ϗοτ൛ ֦ுੑ ͓ΑͼॲཧྗΞοϓͷجૅ εέʔϥϏϦςΟ ύϑΥʔϚϯε • ඇಉظϝοηʔδ؆୯͔ͭೳతͳϓϩηεؒ௨৴ ηϚϑΥʔෆཁɾσουϩοΫճආ
·ͱΊ • Ϗοτ൛ ֦ுੑ ͓ΑͼॲཧྗΞοϓͷجૅ εέʔϥϏϦςΟ ύϑΥʔϚϯε • ඇಉظϝοηʔδ؆୯͔ͭೳతͳϓϩηεؒ௨৴ ηϚϑΥʔෆཁɾσουϩοΫճආ
• ૣɹɹΛೖखͯ͠׳Ε͓͖ͯ·͠ΐ͏ 3