Skip to content

OpenACC/openacc-interoperability-examples

 
 

Repository files navigation

Stupid OpenACC (Interoperability) Tricks

Author: Jeff Larkin jlarkin@nvidia.com

This repository demonstrates interoperability between OpenACC and various other GPU programming models. An OpenACC-enabled compiler is required. The default makefile has been written for PGI and tested with PGI 14.7, although most if not all examples will work with earlier versions.

If building with the Cray Compiler Environment the makefile will detect this and adjust compiler flags and targets accordingly. Some targets rely on PGI CUDA Fortran features, these targets will be disabled when building with CCE.

Build Instructions:

$ make

Examples

  • cuda_main - calling OpenACC from CUDA C
  • openacc_c_main - Calling CUDA from OpenACC in C
  • openacc_c_cublas - Calling CUBLAS from OpenACC in C
  • thrust - Mixing OpenACC and Thrust in C++
  • cuda_map - Using OpenACC acc_map_data with CUDA in C
  • cuf_main - Calling OpenACC from CUDA Fortran
  • cuf_openacc_main - Calling CUDA Fortran from OpenACC
  • openacc_cublas - Calling CUBLAS from OpenACC in CUDA Fortran
  • acc_malloc - Same as cuda_main, but using the OpenACC API

Releases

No releases published

Packages

No packages published

Languages

  • C 36.1%
  • Cuda 31.1%
  • Makefile 21.3%
  • Fortran 11.5%