Skip to content

Allocate pinned memory only if accel is enabled

Sebastian Ohlmann requested to merge fix_allocation into develop

Description

This avoids a segfault that occurs currently if the code was compiled with CUDA enabled but then executed on the CPU, where pinned memory allocation might not work.

In the new version, pinned memory is only allocated if acceleration is enabled, otherwise aligned memory is used.

News snippet

Fix allocation of pinned memory

Checklist

Merge request reports