< prev index next >
src/cpu/aarch64/vm/aarch64.ad
Print this page
rev 9428 : 8143219: AArch64 broken by 8141132: JEP 254: Compact Strings
Reviewed-by: kvn
*** 4304,4314 ****
int index = $mem$$index;
int scale = $mem$$scale;
int disp = $mem$$disp;
if (index == -1) {
__ prfm(Address(base, disp), PSTL1KEEP);
- __ nop();
} else {
Register index_reg = as_Register(index);
if (disp == 0) {
__ prfm(Address(base, index_reg, Address::lsl(scale)), PSTL1KEEP);
} else {
--- 4304,4313 ----
*** 14165,14174 ****
--- 14164,14176 ----
match(Set result (StrComp (Binary str1 cnt1) (Binary str2 cnt2)));
effect(KILL tmp1, USE_KILL str1, USE_KILL str2, USE_KILL cnt1, USE_KILL cnt2, KILL cr);
format %{ "String Compare $str1,$cnt1,$str2,$cnt2 -> $result # KILL $tmp1" %}
ins_encode %{
+ // Count is in 8-bit bytes; non-Compact chars are 16 bits.
+ __ asrw($cnt1$$Register, $cnt1$$Register, 1);
+ __ asrw($cnt2$$Register, $cnt2$$Register, 1);
__ string_compare($str1$$Register, $str2$$Register,
$cnt1$$Register, $cnt2$$Register, $result$$Register,
$tmp1$$Register);
%}
ins_pipe(pipe_class_memory);
*** 14221,14230 ****
--- 14223,14234 ----
match(Set result (StrEquals (Binary str1 str2) cnt));
effect(KILL tmp, USE_KILL str1, USE_KILL str2, USE_KILL cnt, KILL cr);
format %{ "String Equals $str1,$str2,$cnt -> $result // KILL $tmp" %}
ins_encode %{
+ // Count is in 8-bit bytes; non-Compact chars are 16 bits.
+ __ asrw($cnt$$Register, $cnt$$Register, 1);
__ string_equals($str1$$Register, $str2$$Register,
$cnt$$Register, $result$$Register,
$tmp$$Register);
%}
ins_pipe(pipe_class_memory);
< prev index next >