API for calx
by 
Zachary Tellman
Usage:
(ns your-namespace
  (:require calx))
Overview
An idiomatic wrapper for OpenCL.
Public Variables and Functions
  
  
  acquire!
  function
  Usage: (acquire! d)
  Acquires the buffer.
  
 
  
  
  available-cpu-devices
  function
  Usage: (available-cpu-devices)
       (available-cpu-devices platform)
  Returns all available CPU devices.
  
 
  
  
  available-devices
  function
  Usage: (available-devices)
       (available-devices platform)
  Returns all available devices.
  
 
  
  
  available-gpu-devices
  function
  Usage: (available-gpu-devices)
       (available-gpu-devices platform)
  Returns all available GPU devices.
  
 
  
  
  
  function
  Usage: (available-platforms)
  Returns a list of all available platforms.
  
 
  
  
  best-device
  function
  Usage: (best-device)
       (best-device platform)
  Returns the best available device.
  
 
  
  
  compile-program
  function
  Usage: (compile-program source)
       (compile-program devices source)
  Compiles a OpenCL program, which contains 1 or more kernels.
  
 
  
  
  context
  function
  Usage: (context)
  Returns the current context, or throws an exception if it's not defined.
  
 
  
  
  create-buffer
  function
  Usage: (create-buffer elements sig)
       (create-buffer elements sig usage)
  Creates an OpenCL buffer.
'usage' may be one of [:in :out :in-out].  The default value is :in-out.
  
 
  
  
  create-context
  function
  Usage: (create-context & devices)
  Creates a context which uses the specified devices.  Using more than one device is not recommended.
  
 
  
  
  create-queue
  function
  Usage: (create-queue)
       (create-queue device & properties)
  Creates a queue.
  
 
  
  
  enqueue-barrier
  function
  Usage: (enqueue-barrier)
  Ensures that all previously enqueued commands will complete before new commands will begin.
  
 
  
  
  enqueue-copy
  function
  Usage: (enqueue-copy destination destination-offset source source-range)
  Enqueues a copy from a subset of the source onto the destination.
  
 
  
  
  enqueue-marker
  function
  Usage: (enqueue-marker q)
  Returns an event which represents the progress of all previously enqueued commands.
  
 
  
  
  enqueue-overwrite
  function
  Usage: (enqueue-overwrite destination destination-range source)
  Asynchronously copies a buffer from local memory onto the given subset of the buffer.
  
 
  
  
  enqueue-read
  function
  Usage: (enqueue-read d)
       (enqueue-read d range)
  Asynchronously copies a subset of the buffer into local memory. 'range' defaults to the full buffer.
Returns an object that, when dereferenced, halts execution until the copy is complete, then returns a seq.
  
 
  
  
  enqueue-wait-for
  function
  Usage: (enqueue-wait-for & events)
  Enqueues a barrier which will halt execution until all events given as parameters have completed.
  
 
  
  
  finish
  function
  Usage: (finish)
  Halt execution until all enqueued operations are complete.
  
 
  
  
  from-buffer
  function
  Usage: (from-buffer buf sig)
  Pulls out mixed datatypes from a ByteBuffer, per 'sig'.
  
 
  
  
  mimic
  function
  Usage: (mimic d)
       (mimic d elements)
       (mimic d elements usage)
  Create a different buffer of the same type. 'elements' and 'usage' default to those of the original buffer.
  
 
  
  
  
  function
  Usage: (platform)
  Returns the current platform, or throws an exception if it's not defined.
  
 
  
  
  program
  function
  Usage: (program)
  Returns the current program, or throws an exception if it's not defined.
  
 
  
  
  queue
  function
  Usage: (queue)
  Returns the current queue, or throws an exception if it's not defined.
  
 
  
  
  release!
  function
  Usage: (release! d)
  Releases the buffer.
  
 
  
  
  status
  function
  Usage: (status event)
  Returns the status of the event.
  
 
  
  
  to-buffer
  function
  Usage: (to-buffer s sig)
  Fills a ByteBuffer with a contiguous mixed datatype defined by 'sig'.
  
 
  
  
  version
  function
  Usage: (version)
       (version platform)
  Returns the version of the OpenCL implementation.
  
 
  
  
  wait-for
  function
  Usage: (wait-for & events)
  Halt execution until all events are complete.
  
 
  
  
  with-cl
  macro
  Usage: (with-cl & body)
  Executes the inner scope inside a context using the best available device.
  
 
  
  
  with-context
  macro
  Usage: (with-context context & body)
  Defines the context within the inner scope.
  
 
  
  
  with-cpu
  macro
  Usage: (with-cpu & body)
  Executes the inner scope inside a context using the CPU.
  
 
  
  
  with-devices
  macro
  Usage: (with-devices devices & body)
  Defines the devices within the inner scope.  Creates a context using these devices, and releases the context once the scope is exited.
  
 
  
  
  with-gpu
  macro
  Usage: (with-gpu & body)
  Executes the inner scope inside a context using the GPU.
  
 
  
  
  
  macro
  Usage: (with-platform platform & body)
  Defines the platform within the inner scope.
  
 
  
  
  with-queue
  macro
  Usage: (with-queue q & body)
  Executes inner scope within the queue.
  
 
  
  
  with-queue-and-wait
  macro
  Usage: (with-queue-and-wait q & body)
  Executes inner scope within the queue, and waits for all commands to complete.
  
 
  
  
  wrap
  function
  Usage: (wrap s)
       (wrap s sig)
       (wrap s sig usage)
  Copies a sequence into an OpenCL buffer.  Type is assumed to be uniform across the sequence.
'usage' may be one of [:in :out :in-out].  The default value is :in-out.