[Trilinos-Users] [EXTERNAL] Trilinos-Users Digest, Vol 137, Issue 4

Hoemmen, Mark mhoemme at sandia.gov
Mon Jan 23 10:53:04 EST 2017


On 1/23/17, 4:00 AM, "Trilinos-Users on behalf of trilinos-users-request at trilinos.org" <trilinos-users-bounces at trilinos.org on behalf of trilinos-users-request at trilinos.org> wrote:
>Date: Sat, 21 Jan 2017 02:33:55 -0700
>From: Ashesh Chattopadhyay <ashesh6810 at gmail.com>
>To: Trilinos-Users at trilinos.org
>Subject: [Trilinos-Users] Trilinos-Kokkos with CUDA 7.0 ,	issues with C++ lambdas
>
>Dear All,
>
>I know that after and including CUDA 7.5 an experimental feature to pass
>lambdas from host to device was provided through the options
>--expt-extended-lambda
>
>and I can use it with -DKOKKOS_CUDA_USE_LAMBDA to compile Kokkos code with
>execution space as CUDA, however, I am being forced to use CUDA 7.0
>currently and I see that Kokkos can be used with CUDA 7.0 but the nvcc
>compiler does not recognize the --expt-extended-lambda option and without
>that I get a compiler error at the lambda. Can you please advise me as to
>how I can use CUDA 7.0 to compile and run Kokkos code.

If you don’t have CUDA >= 7.5, you cannot use lambdas in Kokkos::parallel_*.  Instead, you must write functors.  These are classes with state and an operator() that implements what the lambda would implement.  Please refer to the Kokkos tutorial for examples.

mfh



More information about the Trilinos-Users mailing list