Skip to content

Commit a46e3f1

Browse files
tipabutkanteck
authored andcommitted
igzip: Fix aarch64 registry width for bfinal
We only ever load 32 bits into it, and we only ever want to compare against 32 bits. There was no need to declare it as 64 bits. Furthermore, there were cases where a 64 bit comparison around isal_out_overflow_1 led us to erroneously set the block state to ISAL_BLOCK_INPUT_DONE when it should have been left at ISAL_BLOCK_NEW_HDR. Fixes #316 Signed-off-by: Tim Burke <[email protected]>
1 parent 73c5044 commit a46e3f1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

igzip/aarch64/igzip_decode_huffman_code_block_aarch64.S

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ declare Macros
292292
declare_generic_reg block_state, 8,w
293293
declare_generic_reg block_state_adr,9,x
294294
declare_generic_reg look_back_dist, 10,w
295-
declare_generic_reg bfinal, 22,x
295+
declare_generic_reg bfinal, 22,w
296296

297297
declare_generic_reg next_out, 12,x
298298
declare_generic_reg avail_out, 13,w
@@ -607,8 +607,8 @@ next_lit_eq_256:
607607
ISAL_BLOCK_INPUT_DONE : ISAL_BLOCK_NEW_HDR;
608608
*/
609609
mov block_state, ISAL_BLOCK_INPUT_DONE
610-
cmp w_bfinal,0
611-
csel block_state, block_state, w_bfinal, ne
610+
cmp bfinal,0
611+
csel block_state, block_state, bfinal, ne
612612
str block_state, [block_state_adr]
613613

614614
b block_state_loop

0 commit comments

Comments
 (0)