Golang Now Enables Speedier getrandom() On Linux

Written by Michael Larabel in Programming on 2 October 2024 at 06:34 AM EDT. 5 Comments
PROGRAMMING
The Linux 6.11 kernel introduced getrandom() in the vDSO for faster yet secure user-space random number generation needs. In addition to patches pending for Glibc to make use of getrandom() vDSO support, Golang is now another early user of this functionality.

Golang has merged support for using the vDSO for getrandom() on Linux when running on a supported kernel version and architecture. Open-source developer Jason Donenfeld who pursued the getrandom() vDSO support also worked on the Golang runtime support and the follow-up patch for using vDSO for getrandom() on Linux.

Indeed the noted performance gains are there for using vDSO for getrandom():

golang getrandom() vDSO commit text

Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week