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
fix: default to as-sha256 if no chip support for AVX (#7887)
**Motivation**
A crash was reported by several parties running Lodestar on a VPS. The
problem was tracked down to no AVX support on the host which causes
OffchainLabs/hashtree to crash. The go binding do a similar check, at
the bindings level, and revert to a non-assembly SHA256 lib. This PR
does the same. Checks the hardware for the supported AVX types and
returns `as-sha256` hasher from the `hashtree` hasher so there is no
crash.
https://github.com/OffchainLabs/hashtree/blob/67979dccfc99b02b488ed8f5fddee9f09aea411e/src/hashtree.c#L53-L67
"Hashtree hasher is preferred but the CPU architecture does not support AVX, AVX2 or the correct AVX512 instruction sets. Falling back to as-sha256 hasher instead."
// biome-ignore lint/suspicious/noConsole: let consumer know that the default hasher is not supported
14
+
console.log(
15
+
"Hashtree hasher is preferred but the CPU architecture does not support AVX, AVX2 or the correct AVX512 instruction sets. Falling back to as-sha256 hasher instead."
0 commit comments