@@ -107,29 +107,29 @@ macro_rules! blake2_impl {
107
107
fn compress( & mut self , block: & Block <Self >, f0: $word, f1: $word) {
108
108
use $crate:: consts:: SIGMA ;
109
109
110
- #[ inline( always) ]
110
+ #[ cfg_attr ( not ( feature = "size_opt" ) , inline( always) ) ]
111
111
fn quarter_round( v: & mut [ $vec; 4 ] , rd: u32 , rb: u32 , m: $vec) {
112
112
v[ 0 ] = v[ 0 ] . wrapping_add( v[ 1 ] ) . wrapping_add( m. from_le( ) ) ;
113
113
v[ 3 ] = ( v[ 3 ] ^ v[ 0 ] ) . rotate_right_const( rd) ;
114
114
v[ 2 ] = v[ 2 ] . wrapping_add( v[ 3 ] ) ;
115
115
v[ 1 ] = ( v[ 1 ] ^ v[ 2 ] ) . rotate_right_const( rb) ;
116
116
}
117
117
118
- #[ inline( always) ]
118
+ #[ cfg_attr ( not ( feature = "size_opt" ) , inline( always) ) ]
119
119
fn shuffle( v: & mut [ $vec; 4 ] ) {
120
120
v[ 1 ] = v[ 1 ] . shuffle_left_1( ) ;
121
121
v[ 2 ] = v[ 2 ] . shuffle_left_2( ) ;
122
122
v[ 3 ] = v[ 3 ] . shuffle_left_3( ) ;
123
123
}
124
124
125
- #[ inline( always) ]
125
+ #[ cfg_attr ( not ( feature = "size_opt" ) , inline( always) ) ]
126
126
fn unshuffle( v: & mut [ $vec; 4 ] ) {
127
127
v[ 1 ] = v[ 1 ] . shuffle_right_1( ) ;
128
128
v[ 2 ] = v[ 2 ] . shuffle_right_2( ) ;
129
129
v[ 3 ] = v[ 3 ] . shuffle_right_3( ) ;
130
130
}
131
131
132
- #[ inline( always) ]
132
+ #[ cfg_attr ( not ( feature = "size_opt" ) , inline( always) ) ]
133
133
fn round( v: & mut [ $vec; 4 ] , m: & [ $word; 16 ] , s: & [ usize ; 16 ] ) {
134
134
quarter_round( v, $R1, $R2, $vec:: gather( m, s[ 0 ] , s[ 2 ] , s[ 4 ] , s[ 6 ] ) ) ;
135
135
quarter_round( v, $R3, $R4, $vec:: gather( m, s[ 1 ] , s[ 3 ] , s[ 5 ] , s[ 7 ] ) ) ;
0 commit comments