Panadestein / cuda_demo

Fortran and CUDA interfacing with ISO_C_BINDING

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CUDA Fortran Minimal Working Example

This repository contains a minimal working example (MWE) demonstrating how to use CUDA with Fortran using the ISO_C_BINDING module. The project uses CMake as the build system.

Prerequisites

  • CMake 3.8 or higher
  • GNU compilers (gfortran, g++)
  • CUDA
  • BLAS/LAPACK

Building the project

  1. Clone the repository:
git clone https://github.com/Panadestein/cuda_demo.git
cd cuda_demo
  1. Create a build directory and navigate to it:
mkdir build
cd build
  1. Configure the project using CMake and compile:
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j

Note: the default build type is Debug.

Contributing

Feel free to open an issue or submit a pull request if you have any suggestions, improvements, or bug fixes.

About

Fortran and CUDA interfacing with ISO_C_BINDING

License:MIT License


Languages

Language:Fortran 64.6%Language:Cuda 25.6%Language:CMake 9.8%