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
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
alienxp03
September 14, 2015
Programming
140
0
Share
Metal Demo
alienxp03
September 14, 2015
More Decks by alienxp03
See All by alienxp03
Rails, Capistrano & AWS
alienxp03
0
98
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
JJUG CCC 2026 Spring: JSpecify で実現する Kotlin フレンドリーな Java API 設計
ternbusty
1
110
RTSPクライアントを自作してみた話
simotin13
0
380
Agentic UI beyond Chats Architecture Patterns & Open Standards @ngMunich 05/2026
manfredsteyer
PRO
0
180
New "Type" system on PicoRuby
pocke
1
390
作って学ぶ、 JSX (TSX) ランタイムの基本
syumai
7
1k
Stage 3 Decorators でできること / できないこと / TSKaigi 2026
susisu
1
1.4k
oxlintはeslint/typescript-eslintを置き換えられるのか
shomafujita
2
290
Oxlintのカスタムルールの現況
syumai
5
910
Spec-Driven Development with AI-Agents: From High-Level Requirements to Working Software
antonarhipov
2
400
These Five Tricks Can Make Your Apps Greener, Cheaper, & Nicer
hollycummins
0
250
OSもどきOS
arkw
0
340
肥大化するレガシーコードに立ち向かうためのインターフェース分離と依存の逆転 / JJUG CCC 2026 Spring
hirokunimaeta
0
270
Featured
See All Featured
Being A Developer After 40
akosma
91
590k
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
460
Chasing Engaging Ingredients in Design
codingconduct
0
200
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
160
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.8k
Heart Work Chapter 1 - Part 1
lfama
PRO
7
36k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
270
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
290
Reality Check: Gamification 10 Years Later
codingconduct
0
2.2k
The Illustrated Children's Guide to Kubernetes
chrisshort
51
52k
How To Speak Unicorn (iThemes Webinar)
marktimemedia
1
470
Why Our Code Smells
bkeepers
PRO
340
58k
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