Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
target/ppc: Use aesdec_ISB_ISR_AK
This implements the VNCIPHERLAST instruction.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
  • Loading branch information
rth7680 committed Jul 8, 2023
1 parent 7df34e4 commit 2cf44f3
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions target/ppc/int_helper.c
Expand Up @@ -2973,13 +2973,7 @@ void helper_vncipher(ppc_avr_t *r, ppc_avr_t *a, ppc_avr_t *b)

void helper_vncipherlast(ppc_avr_t *r, ppc_avr_t *a, ppc_avr_t *b)
{
ppc_avr_t result;
int i;

VECTOR_FOR_INORDER_I(i, u8) {
result.VsrB(i) = b->VsrB(i) ^ (AES_isbox[a->VsrB(AES_ishifts[i])]);
}
*r = result;
aesdec_ISB_ISR_AK((AESState *)r, (AESState *)a, (AESState *)b, true);
}

void helper_vshasigmaw(ppc_avr_t *r, ppc_avr_t *a, uint32_t st_six)
Expand Down

0 comments on commit 2cf44f3

Please sign in to comment.