[PATCH] Fix mterp assembly to use uxtw instead of lsl where needed.
authorDavid Srbecky <dsrbecky@google.com>
Thu, 4 Apr 2019 15:16:17 +0000 (16:16 +0100)
committerHans-Christoph Steiner <hans@eds.org>
Thu, 7 Jan 2021 12:08:42 +0000 (12:08 +0000)
commit6d756321f100101f6410f44f6b22801a3a923791
tree1fd67531a8ed403a447cb1253295777b61d786fb
parentae0b62bb6ba75d3d22acd79aa9c7f16284638b6c
[PATCH] Fix mterp assembly to use uxtw instead of lsl where needed.

Bug: https://bugs.llvm.org/show_bug.cgi?id=41504
Origin: https://android-review.googlesource.com/c/platform/art/+/940018

The old instructions are invalid according to the ARM spec.

Event though UXTW and LSL are aliases this is binary change:
"add x0, x1, w2, lsl #1" was invalid and would be treated as
"add x0, x1, x2, uxtx #1" which would keep the high bits.

With uxtw, we ignore the high bits, as expected in code.

Test: test.py -r --target --interpreter
Change-Id: I66f67ccc5a401d0cf6ac5b42d41d8df26a190046

Gbp-Pq: Name fix-mterp-assembly-to-use-uxtw-instead-of-lsl-where-needed.patch
runtime/interpreter/mterp/arm64/array.S
runtime/interpreter/mterp/arm64/main.S
runtime/interpreter/mterp/arm64/other.S