opencl_version_check.hpp 754 B

1234567891011121314151617181920
  1. //---------------------------------------------------------------------------//
  2. // Copyright (c) 2014 Denis Demidov
  3. //
  4. // Distributed under the Boost Software License, Version 1.0
  5. // See accompanying file LICENSE_1_0.txt or copy at
  6. // http://www.boost.org/LICENSE_1_0.txt
  7. //
  8. // See http://boostorg.github.com/compute for more information.
  9. //---------------------------------------------------------------------------//
  10. #ifndef BOOST_COMPUTE_TEST_OPENCL_VERSION_CHECK_HPP
  11. #define BOOST_COMPUTE_TEST_OPENCL_VERSION_CHECK_HPP
  12. #define REQUIRES_OPENCL_VERSION(major, minor) \
  13. if (!device.check_version(major, minor)) return
  14. #define REQUIRES_OPENCL_PLATFORM_VERSION(major, minor) \
  15. if (!device.platform().check_version(major, minor)) return
  16. #endif