AArch64: Fix and enable reverseBytes intrinsic.
There is no revsh on arm64, use rev16 and sxth instead.
Change-Id: I5f9879352f0ad76b386c82cbf476894af888a64c
diff --git a/compiler/dex/quick/arm64/utility_arm64.cc b/compiler/dex/quick/arm64/utility_arm64.cc
index 22a4ec4..b2f5142 100644
--- a/compiler/dex/quick/arm64/utility_arm64.cc
+++ b/compiler/dex/quick/arm64/utility_arm64.cc
@@ -488,7 +488,9 @@
break;
case kOpRevsh:
// Binary, but rm is encoded twice.
- return NewLIR2(kA64Rev162rr | wide, r_dest_src1.GetReg(), r_src2.GetReg());
+ NewLIR2(kA64Rev162rr | wide, r_dest_src1.GetReg(), r_src2.GetReg());
+ // "sxth r1, r2" is "sbfm r1, r2, #0, #15"
+ return NewLIR4(kA64Sbfm4rrdd | wide, r_dest_src1.GetReg(), r_dest_src1.GetReg(), 0, 15);
break;
case kOp2Byte:
DCHECK_EQ(shift, ENCODE_NO_SHIFT);