15. The Metal Compute Pipeline
Contrariwise, if it was so, it might be; and if it were so, it would be; but as it isn’t, it ain’t. That’s logic.—Lewis Carroll
One of the big promises of Metal is that it allows programmers to do general-purpose GPU programming (GPGPU programming). Over the years, as GPUs have gotten more powerful, clever programmers have realized that they can offload to the GPU a lot of work that is not necessarily graphics related. This chapter focuses on GPGPU programming in Metal.