diff options
| author | 2017-02-14 17:20:51 +0000 | |
|---|---|---|
| committer | 2017-02-14 17:55:26 +0000 | |
| commit | 5afd1be86f1c6042f479cc475fbc53dd9c27425b (patch) | |
| tree | 95932a38b63a2613b7d674ced441bd11568f4c76 | |
| parent | aff5505d85612621bd112d9af1ba4cc31a4619d1 (diff) | |
ARM: Faster read barrier marking entrypoints.
Avoid MVN for forwarding address check and another one
undoing the first when we hit a forwarding address.
Test: m test-art-target
Bug: 29516974
Change-Id: I9c0ca70a6fe98f0200df27bf7ed776aee039e64d
| -rw-r--r-- | runtime/arch/arm/quick_entrypoints_arm.S | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/runtime/arch/arm/quick_entrypoints_arm.S b/runtime/arch/arm/quick_entrypoints_arm.S index cfe8406fbf..85310911be 100644 --- a/runtime/arch/arm/quick_entrypoints_arm.S +++ b/runtime/arch/arm/quick_entrypoints_arm.S @@ -2049,9 +2049,13 @@ ENTRY \name .Lnot_marked_rb_\name: // Test that both the forwarding state bits are 1. - mvn ip, ip - tst ip, #(LOCK_WORD_STATE_FORWARDING_ADDRESS << LOCK_WORD_STATE_SHIFT) - beq .Lret_forwarding_address\name +#if (LOCK_WORD_STATE_SHIFT != 30) || (LOCK_WORD_STATE_FORWARDING_ADDRESS != 3) + // To use "CMP ip, #modified-immediate; BHS", we need the lock word state in + // the highest bits and the "forwarding address" state to have all bits set. +#error "Unexpected lock word state shift or forwarding address state value." +#endif + cmp ip, #(LOCK_WORD_STATE_FORWARDING_ADDRESS << LOCK_WORD_STATE_SHIFT) + bhs .Lret_forwarding_address\name .Lslow_rb_\name: // Save IP: The kSaveEverything entrypoint art_quick_resolve_string used to @@ -2118,7 +2122,6 @@ ENTRY \name .Lret_forwarding_address\name: // Shift left by the forwarding address shift. This clears out the state bits since they are // in the top 2 bits of the lock word. - mvn ip, ip lsl \reg, ip, #LOCK_WORD_STATE_FORWARDING_ADDRESS_SHIFT bx lr END \name |