Visible to Intel only — GUID: GUID-C42D0E68-BD14-4D67-A5F9-8E59780FC892
Visible to Intel only — GUID: GUID-C42D0E68-BD14-4D67-A5F9-8E59780FC892
_rdseed16_step/ _rdseed32_step/ _rdseed64_step
Generates random numbers of 16/32/64 bit wide random integers. The corresponding 4th Generation Intel® Core™ instruction is RDSEED.
Syntax
extern int _rdseed16_step(unsigned short *random_val); |
extern int _rdseed32_step(unsigned int *random_val); |
extern int _rdseed64_step(unsigned __int64 *random_val); |
Parameters
*random_val |
Random value written to the given memory location |
Description
These intrinsics generate random numbers of 16/32/64 bit wide random integers. These intrinsics are mapped to a code-sequence based on the RDSEED instruction. The result code depends on the context in which the intrinsics were used and on the target operating system.
The _rdrand64_step() intrinsic can be used only on systems with the 64-bit registers support.
The generated random value is written to the given memory location and the success status is returned: '1' if the hardware returned a valid random value, and '0' otherwise.
Returns
The generated random value is written to the given memory location and the success status is returned. Returns '1' if the hardware returns a random 16/32/64 bit value (success). Returns '0' otherwise (failure).