[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)
committerJochen Sprickerhof <jspricke@debian.org>
Tue, 5 Apr 2022 11:39:26 +0000 (12:39 +0100)
commite6e4fc7e6d68d79e9df8eb1b7ae79bf620a6d46a
treefe71276ec62c283617b1512345d2d645f61949b0
parentc92cc29609ed7705b6cf366758c6cf187e4f4756
[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