When trying to offload an array that exceeds a specific size, the program fails with "offload error: process on the device 0 was terminated by signal 11 (SIGSEGV)"
Here is some test code. The first part works, the last not:
#include <stdio.h> #include <stdlib.h> int main (int argc, char *argv[]) { { int ar[3144000]; printf("Size %lld\n",3144000); #pragma omp target data map(to:ar) printf("OK\n"); printf("Back\n"); } { int ar[3145000]; printf("Size %lld\n",3145000); #pragma omp target data map(to:ar) printf("OK\n"); printf("Back\n"); } return EXIT_SUCCESS; }