Update only Reference implementation and tests (#8126)
There were discovered a lot of issues in 'CompareWithRefs' tests when generated float inputs are not rounded to 'int'
This commit is contained in:
1 parent
789c2377ca
commit
7ef4ff6385
2 files changed
+10
-10
No files matched your search
@@ -60,7 +60,7 @@ void jit_convert_vec<float, int8_t>(jit::Generator& gen, const Xbyak::RegExp& sr
|
||||
auto p32vec_lo = gen.xmm2;
|
||||
auto p32vec_hi = gen.xmm3;
|
||||
|
||||
gen.vcvtps2dq(p32vec, gen.yword[src]); // convert 8 floats to 8 ints
|
||||
gen.vcvttps2dq(p32vec, gen.yword[src]); // convert 8 floats to 8 ints
|
||||
gen.vpshufb(p32vec, p32vec, order); // Shuffle the bytes according to the order
|
||||
gen.vextracti128(p32vec_hi, p32vec, 1); // extract upper part of p32vec
|
||||
gen.vpor(p32vec_lo, p32vec_lo, p32vec_hi); // p32vec_lo = p32vec_lo | p32vec_hi
|
||||
@@ -80,7 +80,7 @@ void jit_convert_vec<float16, int8_t>(jit::Generator& gen, const Xbyak::RegExp&
|
||||
auto p32vec_hi = gen.xmm3;
|
||||
|
||||
gen.vcvtph2ps(p32vec, gen.xword[src]); // convert 8 fp16's to 8 floats
|
||||
gen.vcvtps2dq(p32vec, p32vec); // convert 8 floats to 8 ints
|
||||
gen.vcvttps2dq(p32vec, p32vec); // convert 8 floats to 8 ints
|
||||
gen.vpshufb(p32vec, p32vec, order); // Shuffle the bytes according to the order
|
||||
gen.vextracti128(p32vec_hi, p32vec, 1); // extract upper part of p32vec
|
||||
gen.vpor(p32vec_lo, p32vec_lo, p32vec_hi); // p32vec_lo = p32vec_lo | p32vec_hi
|
||||
|
||||
Reference in new issue
Block a user