You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Consider a documented example: the simd_avx512ifma::func() function is marked as safe, but will invoke undefined behavior if called when the corresponding target feature is missing.
This could be mitigated through an assert for the presence of the target feature before invoking the inner function (which should optimize out when called from a typical dispatch function), or by marking the function unsafe and documenting the requirements imposed upon callers.
This is not directly a hazard to consumers of curve25519-dalek itself, to whom specialized functions are presumably not directly exposed, but complicates auditing and may present a maintenance hazard.
The text was updated successfully, but these errors were encountered:
Consider a documented example: the
simd_avx512ifma::func()
function is marked as safe, but will invoke undefined behavior if called when the corresponding target feature is missing.This could be mitigated through an assert for the presence of the target feature before invoking the inner function (which should optimize out when called from a typical dispatch function), or by marking the function
unsafe
and documenting the requirements imposed upon callers.This is not directly a hazard to consumers of curve25519-dalek itself, to whom specialized functions are presumably not directly exposed, but complicates auditing and may present a maintenance hazard.
The text was updated successfully, but these errors were encountered: