cuda - what does the last parameter mean for cudaHostGetDevicePointer -
most explanations of last parameter is"flags extensions (must 0 now)".link here:http://www.cs.cmu.edu/afs/cs/academic/class/15668-s11/www/cuda-doc/html/group__cudart__memory_ga475419a9b21a66036029d5001ea908c.html#ga475419a9b21a66036029d5001ea908c
so mean? me providing code explanations?
the current documentation cudahostgetdevicepointer here.
from documentation:
flagsprovides future releases. now, must set 0.
that means placeholder. in future cuda release (beyond cuda 7.0), there may use value. doesn't cause behavioral change, still required specify zero. specifying 0 should enable compatibility (no behavioral change) in future cuda release, if non-zero values result in difference in behavior.
regarding use of the cudahostgetdevicepointer function:
it used zero-copy mapped memory, accessible both host , device. access device, need device pointer, may different host pointer in non-uva environment. function provides device pointer associated allocated/pinned/mapped host pointer.
here usage example.
Comments
Post a Comment