|
@@ -19,6 +19,10 @@ static inline void mid_oswap(unsigned char *buf, uint32_t *dest,
|
|
|
uint32_t destb = dest[b];
|
|
|
uint8_t swap_flag = ((mid <= desta) & (desta < hi))
|
|
|
| ((lo <= destb) & (destb < mid));
|
|
|
+ // The next line could be optimized with some inline assembly, since
|
|
|
+ // we've already loaded desta and destb, so we could obliviously
|
|
|
+ // swap those registers, and then non-obliviously write them back
|
|
|
+ // out to dest[a] and dest[b].
|
|
|
oswap_buffer<OSWAP_4>((unsigned char *)(dest+a),
|
|
|
(unsigned char *)(dest+b), 4, swap_flag);
|
|
|
oswap_buffer<oswap_style>(buf+a*block_size, buf+b*block_size,
|