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
Metal Demo
Search
alienxp03
September 14, 2015
Programming
140
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Metal Demo
alienxp03
September 14, 2015
More Decks by alienxp03
See All by alienxp03
Rails, Capistrano & AWS
alienxp03
0
99
iOS Tools
alienxp03
1
210
RxSwift+MVVM
alienxp03
1
510
From a student to a developer
alienxp03
1
110
Other Decks in Programming
See All in Programming
AI駆動開発を妨げる技術的負債の解消アプローチ / ai-refactoring-approach
minodriven
17
8.9k
SREは、MCPとSRE Agentをこう使え!
kazumax55
0
150
Signal Forms: Details & Live Coding @enterJS 2026 in Mannheim
manfredsteyer
PRO
0
230
継続モナドとリアクティブプログラミング
yukikurage
3
490
なぜ関数型プログラミングで「型」と「証明」が語られるのか #fp_matsuri
kajitack
3
800
スマートグラスで並列バイブコーディング
hyshu
0
290
Hunting Vulnerabilities in Symfony with LLMs
vinceamstoutz
0
580
Vue × Nuxt × Oxc どこまで使える?実運用の現在地
andpad
0
370
信頼性について考えてみる(SRE NEXT 2026 miniLT)
hayama17
0
160
OSINT for SRE: 学術論文とポストモーテムから探る システム障害の共通パターン / SRE NEXT 2026
tomoyk
1
3.4k
分散システム、なんですぐ死んでしまうん?耐障害性を高めたいあなたのためのレジリエンスパターン入門
mshibuya
7
5.7k
PHPだって関数型したい 〜できること、できないこと〜 / fp-in-php
jsoizo
0
190
Featured
See All Featured
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
Building Adaptive Systems
keathley
44
3.1k
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
2
420
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
260
Un-Boring Meetings
codingconduct
0
340
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
Chasing Engaging Ingredients in Design
codingconduct
0
230
Skip the Path - Find Your Career Trail
mkilby
1
160
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
330
My Coaching Mixtape
mlcsv
0
170
Facilitating Awesome Meetings
lara
57
7k
A better future with KSS
kneath
240
18k
Transcript
GPU Programming in Metal • Twitter: @alienxp03 • Not a
GPU programmer
Metal • Introduced in iOS 8 • Only for iOS
devices • Usage - Graphic rendering - Parallel data computation
Basic guide • Initialise Metal
Basic guide • Call the compiled shader function
Basic guide • Set parameters
Basic guide • Threadgroups
Basic guide • Run the computation • Get the result
Shader language • Using C++11 with some extension and limitation
pow(x, y) • 12,228 integers - CPU : 0.028833416668931 secs
- GPU : 0.0302730000112206 secs
pow(x, y) • 33,554,432 integers (2 ^ 25 ) -
CPU : 73.7681545416708 secs - GPU : 38.1098593333445 secs
Implementation • Didn’t compare precise::pow vs fast::pow • Initialise the
array on CPU, then pass it to GPU for computation • Using CPU cache memory
None
iOS 9 • Metal is now available on OS X
too • MTLResourceOptions
iOS 9 • Instrument, Metal System Trace
None
Lesson learned • We have GPU too, and it’s pretty
powerful • And it’s idle almost the whole time
Real world application • For data simulation or visualisation •
Though the truth is, I have no idea • Just did it for fun
GPU Programming in Metal • Twitter: @alienxp03 • Not a
GPU programmer