8160969: aarch64: CDS is broken after 8079507
Reviewed-by: roland
Contributed-by: ningsheng.jian@linaro.org
--- a/hotspot/src/cpu/aarch64/vm/templateTable_aarch64.cpp Thu Jul 07 15:39:12 2016 +0100
+++ b/hotspot/src/cpu/aarch64/vm/templateTable_aarch64.cpp Fri Jul 08 17:02:10 2016 +0100
@@ -2434,7 +2434,7 @@
__ ldrsb(r0, field);
__ push(ztos);
// Rewrite bytecode to be faster
- if (!is_static) {
+ if (rc == may_rewrite) {
// use btos rewriting, no truncating to t/f bit is needed for getfield.
patch_bytecode(Bytecodes::_fast_bgetfield, bc, r1);
}
@@ -2670,7 +2670,7 @@
if (!is_static) pop_and_check_object(obj);
__ andw(r0, r0, 0x1);
__ strb(r0, field);
- if (!is_static) {
+ if (rc == may_rewrite) {
patch_bytecode(Bytecodes::_fast_zputfield, bc, r1, true, byte_no);
}
__ b(Done);