Making OpenCL? Simple with Haskell - AMD Developer Central
Making OpenCL? Simple with Haskell - AMD Developer Central Making OpenCL? Simple with Haskell - AMD Developer Central
USING HASKELL AT AMD Monads are a simple idea but they are not easy to explain and use in practice. At least for many people. – Originally looking at Garrett‟s Monad transformers I said it seemed complicated. His response was “ you need to look at them sideways”! (He was right ) Haskell is not the Miranda that I learned as an undergraduate, it is big and a lot of very complicated type theory stuff. Really scary for many people! – Benjamin C. Pierce has a great talk discussing just this phenomena; Types Considered Harmful, May 2008. Invited talk at Mathematical Foundations of Programming Semantics (MFPS).” “I have long advocated type systems…but I‟ve changed my mind” 50 | Making OpenCL Simple | January, 2011 | Public
USING HASKELL AT AMD Many Universities in the US do not teach Haskell! Perception of Haskell is often low: – “You probably know every Haskell programmer” – “Why not use Python or …” Finally, it is not easy to find interns with the required Haskell experience to work on these kinds of projects. To be fair no one has said don’t use Haskell! 51 | Making OpenCL Simple | January, 2011 | Public
- Page 1 and 2: Making OpenCL Simple with Haskell B
- Page 3 and 4: AGENDA Motivation Whistle stop intr
- Page 5 and 6: OPENCL PROGRAM STRUCTURE 5 | Making
- Page 7 and 8: HELLO WORLD OPENCL C SOURCE __const
- Page 9 and 10: HELLO WORLD - HOST PROGRAM // creat
- Page 11 and 12: USING HASKELL OUR GOAL IS TO WRITE
- Page 13 and 14: LEARN FROM COMMON USES In OpenCL w
- Page 15 and 16: IT’S A HETEROGENEOUS WORLD A mod
- Page 17 and 18: OPENCL EXECUTION MODEL An OpenCL a
- Page 19 and 20: THE BIG IDEA BEHIND OPENCL OpenCL e
- Page 21 and 22: OPENCL MEMORY MODEL •Private Memo
- Page 23 and 24: OPENCL SUMMARY __kernel void dp_mul
- Page 25 and 26: PROGRAMMING KERNELS: OPENCL C Deri
- Page 27 and 28: PROGRAMMING KERNELS: DATA TYPES Sca
- Page 29 and 30: THE BASICS - HELLO WORLD main = do
- Page 31 and 32: MAPPING OPENCL API getPlatforms ::
- Page 33 and 34: Lifting to something more in the sp
- Page 35 and 36: MOVE TO AN IMPLICIT MODEL 35 | Maki
- Page 37 and 38: CONTEXTUAL/QUEUED MONADS Function l
- Page 39 and 40: EMBEDDING MONADS In fact, the only
- Page 41 and 42: 41 | Making OpenCL Simple | January
- Page 43 and 44: HELLO WORLD REVISITED import Langua
- Page 45 and 46: REALLY WE WOULD LIKE TO WRITE impor
- Page 47 and 48: WHAT WE REALLY WANT Build a delaye
- Page 49: Issues we face using Haskell at AMD
- Page 53: DISCLAIMER The information presente
USING HASKELL AT <strong>AMD</strong><br />
Monads are a simple idea but they are not easy to explain and use in<br />
practice. At least for many people.<br />
– Originally looking at Garrett‟s Monad transformers I said it seemed<br />
complicated. His response was “ you need to look at them sideways”!<br />
(He was right )<br />
<strong>Haskell</strong> is not the Miranda that I learned as an undergraduate, it is big and<br />
a lot of very complicated type theory stuff. Really scary for many people!<br />
– Benjamin C. Pierce has a great talk discussing just this phenomena;<br />
Types Considered Harmful, May 2008. Invited talk at Mathematical<br />
Foundations of Programming Semantics (MFPS).”<br />
“I have long advocated type systems…but I‟ve changed my mind”<br />
50 | <strong>Making</strong> <strong>OpenCL</strong> <strong>Simple</strong> | January, 2011 | Public