These won't work as expected now, so error on them to avoid
wasting time debugging this in the future.
Not sure what the best terminology to use in the error message is
Should this also give an error for any non-global address space? I think the same issue exists if global private or region address space happens. In that case therror message would be "global variables in non global address space not supported in non-kernel functions".