mirror of
https://github.com/intel/isa-l.git
synced 2024-12-12 09:23:50 +01:00
erasure_code: check for size in gf_Xvect_mad_avx512_gfni
Length of data was not checked in implementation with AVX512+GFNI, at the start of the gf_Xvect_mad_avx512_gfni functions, resulting in buffer overflow if length was less than 64 bytes. Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
This commit is contained in:
parent
c06db0c60a
commit
abd80d3c5a
@ -158,6 +158,8 @@ func(gf_2vect_mad_avx512_gfni)
|
||||
mov dest2, [dest1 + 8] ; reuse mul_array
|
||||
mov dest1, [dest1]
|
||||
|
||||
cmp len, 64
|
||||
jl .len_lt_64
|
||||
.loop64:
|
||||
ENCODE_64B_2
|
||||
|
||||
|
@ -173,6 +173,8 @@ func(gf_3vect_mad_avx512_gfni)
|
||||
mov dest3, [dest1 + 2*8] ; reuse vec
|
||||
mov dest1, [dest1]
|
||||
|
||||
cmp len, 64
|
||||
jl .len_lt_64
|
||||
.loop64:
|
||||
ENCODE_64B_3
|
||||
|
||||
|
@ -192,6 +192,8 @@ func(gf_4vect_mad_avx512_gfni)
|
||||
mov dest4, [dest1 + 3*8] ; reuse vec_i
|
||||
mov dest1, [dest1]
|
||||
|
||||
cmp len, 64
|
||||
jl .len_lt_64
|
||||
.loop64:
|
||||
ENCODE_64B_4
|
||||
|
||||
|
@ -209,6 +209,8 @@ func(gf_5vect_mad_avx512_gfni)
|
||||
mov dest5, [dest1 + 4*8] ; reuse vec_i
|
||||
mov dest1, [dest1]
|
||||
|
||||
cmp len, 64
|
||||
jl .len_lt_64
|
||||
.loop64:
|
||||
ENCODE_64B_5
|
||||
|
||||
|
@ -228,6 +228,8 @@ func(gf_6vect_mad_avx512_gfni)
|
||||
mov dest6, [dest1 + 5*8] ; reuse vec_i
|
||||
mov dest1, [dest1]
|
||||
|
||||
cmp len, 64
|
||||
jl .len_lt_64
|
||||
.loop64:
|
||||
ENCODE_64B_6
|
||||
|
||||
|
@ -144,6 +144,8 @@ func(gf_vect_mad_avx512_gfni)
|
||||
|
||||
vbroadcastf32x2 xgft1, [vec_i + mul_array]
|
||||
|
||||
cmp len, 64
|
||||
jl .len_lt_64
|
||||
.loop64:
|
||||
ENCODE_64B
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user