Merge pull request #15 from ddemidov/master

Fixes compilation errors and warnings for VS2010
Improve reduce() performance

This makes a few tweaks to the reduce() algorithm in order to
improve performance. An unnecessary barrier() has been removed
and now multiple values are reduced on the initial read.
Add command_queue::enqueue_migrate_memory_objects() method

This adds an enqueue_migrate_memory_objects() method to the
command_queue class which allows memory objects to be migrated
between compute devices and to the host.
Add event::get_command_type() method

This adds a get_command_type() method to the event class
which returns the OpenCL type for an event object.
Change enqueue_*_buffer() methods to return events

This changes the enqueue_copy_buffer() and enqueue_fill_buffer()
methods in the command_queue class to return event objects.
Change meta_kernel::exec*() methods to return events

This changes the exec() and exec_1d() methods in the meta_kernel
class to return event objects.
Add support for on-device copy_async()

This adds support for copy_async() when copying between
memory objects on a compute device.
Add test for copy() command type

This adds a test to ensure that the copy() algorithm uses
the proper command type when copying memory buffers.
Add fill_async() algorithm

This adds a fill_async() which fills a range with a
given value asynchronously.
Add test for fill() command type

This adds a test to ensure the fill() algorithm uses the
clEnqueueFillBuffer() function if supported.
Add Doxygen documentation

This replaces the BoostBook/XML based reference documentation
with Doxygen auto-generated documentation.
Rearrange type headers

This rearranges the type headers to live under the
<boost/compute/types/...> directory instead of the
top-level <boost/compute/...> directory.
Add uniform_real_distribution

This adds a random number distribution which generates random
numbers in a uniform distribution.

Also adds a convenience algorithm which fills a range with
uniformly distributed random numbers between two values.
Fix issue with comparison operators in lambda expressions

This fixes an issue in which comparison operators (e.g. <, ==)
in lambda expressions would return the wrong result type causing
compilation errors.

Also adds a few test cases to ensure the correct result type
and that lambda expressions can be properly used with count_if().
Add documentation for supported platforms

This adds documentation listing the supported platforms,
compilers, and OpenCL implementations.
Use bitwise-and to check device::type()

This changes the checks for the device type to use the bitwise-and
operator instead of the equaility operator. The returned type is a
bitset and this would cause errors when multiple bits were set.

This fixes a bug on POCL which returns the device type as a
combination of CL_DEVICE_TYPE_DEFAULT and CL_DEVICE_TYPE_CPU. Now
the correct device type (device::cpu) is detected for POCL.
Add scan_on_cpu() algorithm

This adds a new scan_on_cpu() algorithm which implements the scan()
algorithm for CPU devices. Also renames the existing scan() algorithm
to scan_on_gpu().

This fixes some tests failures on POCL which were caused by the prior
GPU scan() algorithm not functioning properly with POCL.
Add quirks for image tests on POCL

This adds code to skip certain image tests on POCL devices which
do not fully support images and image samplers.
Add copy() specialization for host-to-host transfers

This adds a copy() specialization for host-to-host transfers
which simply forwards the call to std::copy().

This is useful in templated algorithms which may in certain
circumstances copy() between data ranges on the host.
Add result argument to reduce() algorithm

This adds an output iterator result argument to the reduce()
algorithm. Now, instead of returning the reduced result, the
result is written to an output iterator. This allows the value
to stay on the device and avoids a device-to-host copy in cases
where the result is not needed on the host (e.g. it is part of
a larger computation).

This is an API breaking change to users of reduce(). Affected code
should now declare a result variable and then pass a pointer to it
as the new result argument.