What changed, and why it matters
This is a one-line build fix for ARM64 processors. It changes a memory prefetch helper to accept read-only (const) pointers, which is required by newer or stricter ARM64 compilers. There is no security bug being fixed here—just a compilation error being resolved.
No security action needed. Treat as a normal build-compatibility fix.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The commit modifies rx_prefetch_nta() in src/crypto/randomx/intrin_portable.h, changing its parameter type from void* to const void*. The function emits an ARM64 prfm (prefetch) instruction. Prefetching does not modify memory, so the pointer should logically be const-qualified. The change resolves a type-safety mismatch that can cause ARM64 build failures under stricter compiler settings. No functional or security behavior changes.
Changed components
src/crypto/randomx/intrin_portable.hInspect captured patch +1 / −1
### src/crypto/randomx/intrin_portable.h
@@ -420,7 +420,7 @@ inline void* rx_aligned_alloc(size_t size, size_t align) {
# define rx_aligned_free(a) free(a)
#endif
-inline void rx_prefetch_nta(void* ptr) {
+inline void rx_prefetch_nta(const void* ptr) {
asm volatile ("prfm pldl1strm, [%0]\n" : : "r" (ptr));
}
Why this scored 19/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.