Skip to content

Commit

Permalink
[Backport] 8269952: compiler/vectorapi/VectorCastShape*Test.java test…
Browse files Browse the repository at this point in the history
…s failed on avx2 machines

Summary: 8269952: compiler/vectorapi/VectorCastShape*Test.java tests failed on avx2 machines

Test Plan: ci jtreg

Reviewed-by: JoshuaZhuwj

Issue: #577
  • Loading branch information
JinZhonghui committed Nov 29, 2023
1 parent e9ad750 commit 87ca29e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
10 changes: 5 additions & 5 deletions src/hotspot/cpu/x86/x86.ad
Original file line number Diff line number Diff line change
Expand Up @@ -6664,7 +6664,7 @@ instruct vcastBtoX(vec dst, vec src) %{
%}

instruct castStoX(vec dst, vec src, rRegP scratch) %{
predicate(UseAVX <= 2 &&
predicate((UseAVX <= 2 || !VM_Version::supports_avx512vlbw()) &&
vector_length(n->in(1)) <= 8 && // src
vector_element_basic_type(n) == T_BYTE);
effect(TEMP scratch);
Expand All @@ -6680,7 +6680,7 @@ instruct castStoX(vec dst, vec src, rRegP scratch) %{
%}

instruct vcastStoX(vec dst, vec src, vec vtmp, rRegP scratch) %{
predicate(UseAVX <= 2 &&
predicate((UseAVX <= 2 || !VM_Version::supports_avx512vlbw()) &&
vector_length(n->in(1)) == 16 && // src
vector_element_basic_type(n) == T_BYTE);
effect(TEMP dst, TEMP vtmp, TEMP scratch);
Expand All @@ -6698,7 +6698,7 @@ instruct vcastStoX(vec dst, vec src, vec vtmp, rRegP scratch) %{
%}

instruct vcastStoX_evex(vec dst, vec src) %{
predicate(UseAVX > 2 ||
predicate((UseAVX > 2 && VM_Version::supports_avx512vlbw()) ||
(vector_length_in_bytes(n) >= vector_length_in_bytes(n->in(1)))); // dst >= src
match(Set dst (VectorCastS2X src));
format %{ "vector_cast_s2x $dst,$src\t!" %}
Expand Down Expand Up @@ -6813,13 +6813,13 @@ instruct vcastItoX_evex(vec dst, vec src) %{
__ evpmovdw($dst$$XMMRegister, $src$$XMMRegister, src_vlen_enc);
break;
case T_FLOAT:
__ vcvtdq2ps($dst$$XMMRegister, $dst$$XMMRegister, dst_vlen_enc);
__ vcvtdq2ps($dst$$XMMRegister, $src$$XMMRegister, dst_vlen_enc);
break;
case T_LONG:
__ vpmovsxdq($dst$$XMMRegister, $src$$XMMRegister, dst_vlen_enc);
break;
case T_DOUBLE:
__ vcvtdq2pd($dst$$XMMRegister, $dst$$XMMRegister, dst_vlen_enc);
__ vcvtdq2pd($dst$$XMMRegister, $src$$XMMRegister, dst_vlen_enc);
break;
default:
ShouldNotReachHere();
Expand Down
3 changes: 0 additions & 3 deletions test/hotspot/jtreg/ProblemList.txt
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,6 @@ compiler/rtm/print/TestPrintPreciseRTMLockingStatistics.java 8183263 generic-x64

compiler/c2/Test8004741.java 8235801 generic-all

compiler/vectorapi/VectorCastShape128Test.java 8269952 generic-x64
compiler/vectorapi/VectorCastShape64Test.java 8269952 generic-x64

#############################################################################

# :hotspot_gc
Expand Down

0 comments on commit 87ca29e

Please sign in to comment.