Rollup merge of #43480 - dhduvall:sparc-blake2b, r=eddyb

Constrain the layout of Blake2bCtx for proper SPARC compilation

On SPARC, optimization fuel ends up emitting incorrect load and store
instructions for the transmute() call in blake2b_compress().  If we
force Blake2bCtx to be repr(C), the problem disappears.

Fixes #43346
This commit is contained in:
Mark Simulacrum 2017-07-26 06:15:09 -06:00 committed by GitHub
commit 959ebd6785

View File

@ -23,6 +23,7 @@
use std::mem;
use std::slice;
#[repr(C)]
pub struct Blake2bCtx {
b: [u8; 128],
h: [u64; 8],