| 831 | |
| 832 | template<typename T> |
| 833 | __global__ void uniformPhilox(T *out, uint hi, uint lo, uint hic, uint loc, |
| 834 | uint elementsPerBlock, uint elements) { |
| 835 | uint index = blockIdx.x * elementsPerBlock + threadIdx.x; |
| 836 | uint key[2] = {lo, hi}; |
| 837 | uint ctr[4] = {loc, hic, 0, 0}; |
| 838 | ctr[0] += index; |
| 839 | ctr[1] += (ctr[0] < loc); |
| 840 | ctr[2] += (ctr[1] < hic); |
| 841 | if (blockIdx.x != (gridDim.x - 1)) { |
| 842 | philox(key, ctr); |
| 843 | writeOut128Bytes(out, index, ctr[0], ctr[1], ctr[2], ctr[3]); |
| 844 | } else { |
| 845 | philox(key, ctr); |
| 846 | partialWriteOut128Bytes(out, index, ctr[0], ctr[1], ctr[2], ctr[3], |
| 847 | elements); |
| 848 | } |
| 849 | } |
| 850 | |
| 851 | template<typename T> |
| 852 | __global__ void uniformThreefry(T *out, uint hi, uint lo, uint hic, uint loc, |
nothing calls this directly
no test coverage detected