Skip to content
Snippets Groups Projects
Commit 75d59956 authored by Niels Möller's avatar Niels Möller
Browse files

(_aes_crypt): Allocate only 32 bytes local storage on the stack.

Calculate wtxt and tmp using offsets from %sp, not %fp.

Rev: src/nettle/sparc/aes.asm:1.71
parent 915e1645
No related branches found
No related tags found
No related merge requests found
...@@ -66,15 +66,19 @@ define(t1, %o1) ...@@ -66,15 +66,19 @@ define(t1, %o1)
define(t2, %o2) define(t2, %o2)
define(t3, %o3) define(t3, %o3)
define(<FRAME_SIZE>, 32)
define(<FRAME_WTXT>, 0)
define(<FRAME_TMP>, 16)
_aes_crypt: _aes_crypt:
! Why -136? ! Why -136?
save %sp, -136, %sp save %sp, -FRAME_SIZE, %sp
cmp length, 0 cmp length, 0
be .Lend be .Lend
! wtxt
add %fp, -24, wtxt add %sp, FRAME_WTXT, wtxt
add %sp, FRAME_TMP, tmp
add %fp, -40, tmp
ld [ctx + AES_NROUNDS], nrounds ld [ctx + AES_NROUNDS], nrounds
! Compute xor, so that we can swap efficiently. ! Compute xor, so that we can swap efficiently.
xor wtxt, tmp, diff xor wtxt, tmp, diff
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment