diff options
author | Stelios Ioannou <stelios.ioannou@arm.com> | 2021-03-09 14:56:49 +0000 |
---|---|---|
committer | Stelios Ioannou <stelios.ioannou@arm.com> | 2021-03-15 17:51:48 +0000 |
commit | ab86edbc88fa41e9cb9c6b43d99b69278c9c5040 (patch) | |
tree | 28a52ebc267039f1a6450fc9da1548b4339779f7 /llvm/lib/CodeGen/BasicBlockSections.cpp | |
parent | b868a3edad9d453eae1c18ec8d9e1feee0cb8c9a (diff) | |
download | llvm-ab86edbc88fa41e9cb9c6b43d99b69278c9c5040.zip llvm-ab86edbc88fa41e9cb9c6b43d99b69278c9c5040.tar.gz llvm-ab86edbc88fa41e9cb9c6b43d99b69278c9c5040.tar.bz2 |
[AArch64] Implement __rndr, __rndrrs intrinsics
This patch implements the __rndr and __rndrrs intrinsics to provide access to the random
number instructions introduced in Armv8.5-A. They are only defined for the AArch64
execution state and are available when __ARM_FEATURE_RNG is defined.
These intrinsics store the random number in their pointer argument and return a status
code if the generation succeeded. The difference between __rndr __rndrrs, is that the latter
intrinsic reseeds the random number generator.
The instructions write the NZCV flags indicating the success of the operation that we can
then read with a CSET.
[1] https://developer.arm.com/docs/101028/latest/data-processing-intrinsics
[2] https://bugs.llvm.org/show_bug.cgi?id=47838
Differential Revision: https://reviews.llvm.org/D98264
Change-Id: I8f92e7bf5b450e5da3e59943b53482edf0df6efc
Diffstat (limited to 'llvm/lib/CodeGen/BasicBlockSections.cpp')
0 files changed, 0 insertions, 0 deletions