Skip to content

Instantly share code, notes, and snippets.

View philmb3487's full-sized avatar

Philippe Michaud-Boudreault philmb3487

View GitHub Profile
@courtneyfaulkner
courtneyfaulkner / devices.c
Created December 11, 2013 22:20
List OpenCL platforms and devices
#include <stdio.h>
#include <stdlib.h>
#ifdef __APPLE__
#include <OpenCL/opencl.h>
#else
#include <CL/cl.h>
#endif
int main() {
#!/bin/sh
# Download and build OS X Mavericks XNU Source
if [ ! -d "dtrace-118" ]; then
curl -O http://opensource.apple.com/tarballs/dtrace/dtrace-118.tar.gz
tar zxf dtrace-118.tar.gz
rm dtrace-118.tar.gz
fi
if [ ! -d "AvailabilityVersions-6" ]; then
curl -O http://opensource.apple.com/tarballs/AvailabilityVersions/AvailabilityVersions-6.tar.gz
tar zxf AvailabilityVersions-6.tar.gz