--- old/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp 2018-07-09 18:34:56.384631431 +0300 +++ new/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp 2018-07-09 18:34:56.208620200 +0300 @@ -4357,7 +4357,7 @@ cmp(cnt1, 8); // Use Linear Scan if cnt1 < 8 || cnt1 >= 256 br(LT, LINEARSEARCH); dup(v0, T16B, cnt1); // done in separate FPU pipeline. Almost no penalty - cmp(cnt1, 256); + subs(zr, cnt1, 256); lsr(tmp1, cnt2, 2); ccmp(cnt1, tmp1, 0b0000, LT); // Source must be 4 * pattern for BM br(GE, LINEARSTUB); @@ -4463,7 +4463,7 @@ BIND(BCLOOP); (this->*str1_load_1chr)(ch1, Address(post(tmp3, str1_chr_size))); if (!str1_isL) { - cmp(ch1, ASIZE); + subs(zr, ch1, ASIZE); br(HS, BCSKIP); } strb(ch2, Address(sp, ch1)); @@ -4527,7 +4527,7 @@ } else { mov(result_tmp, 1); } - cmp(skipch, ASIZE); + subs(zr, skipch, ASIZE); br(HS, BMADV); } ldrb(result_tmp, Address(sp, skipch)); // load skip distance