Strange behavior with constant memory

Hello,

I am getting some strange behavior with constant memory which I can’t see to figure out why. This is all run in emulation mode.

My program defines:

constant double constParameters[16];
double GPUParameters = { 14 doubles }

CUDA_SAFE_CALL( cudaMemcpyToSymbol( constParameters, GPUParameters, sizeof(GPUParameters), sizeof(constParameters) ) );

First question:
Why must I use sizeof(constParameters). Does this not make it write the GPUParameters on mem address: constParameters+sizeof(constParameters) and forward
(I get wrong behavior if I just use offset=0)

Second question:
If i choose constParameters to be of the same size as GPUParameters ie constParameters[14] then I get wrong behavior as well.
Anything below < 16 = wrong. Anything above >= 16 = correct.

Any ideas why this happens?

Thanks.