hotspot/src/cpu/aarch64/vm/jniFastGetField_aarch64.cpp
changeset 44093 e22e0d071bf9
parent 44088 fb5421685295
child 44406 a46a6c4d1dd9
equal deleted inserted replaced
44092:bc842cc2356b 44093:e22e0d071bf9
     1 /*
     1 /*
     2  * Copyright (c) 2004, 2017, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.
     3  * Copyright (c) 2014, Red Hat Inc. All rights reserved.
     3  * Copyright (c) 2014, Red Hat Inc. All rights reserved.
     4  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     5  *
     5  *
     6  * This code is free software; you can redistribute it and/or modify it
     6  * This code is free software; you can redistribute it and/or modify it
     7  * under the terms of the GNU General Public License version 2 only, as
     7  * under the terms of the GNU General Public License version 2 only, as
    80   __ cbnzw(rscratch1, slow);
    80   __ cbnzw(rscratch1, slow);
    81   __ eor(robj, c_rarg1, rcounter);
    81   __ eor(robj, c_rarg1, rcounter);
    82   __ eor(robj, robj, rcounter);               // obj, since
    82   __ eor(robj, robj, rcounter);               // obj, since
    83                                               // robj ^ rcounter ^ rcounter == robj
    83                                               // robj ^ rcounter ^ rcounter == robj
    84                                               // robj is address dependent on rcounter.
    84                                               // robj is address dependent on rcounter.
    85 
       
    86   // If mask changes we need to ensure that the inverse is still encodable as an immediate
       
    87   STATIC_ASSERT(JNIHandles::weak_tag_mask == 1);
       
    88   __ andr(robj, robj, ~JNIHandles::weak_tag_mask);
       
    89 
       
    90   __ ldr(robj, Address(robj, 0));             // *obj
    85   __ ldr(robj, Address(robj, 0));             // *obj
    91   __ lsr(roffset, c_rarg2, 2);                // offset
    86   __ lsr(roffset, c_rarg2, 2);                // offset
    92 
    87 
    93   assert(count < LIST_CAPACITY, "LIST_CAPACITY too small");
    88   assert(count < LIST_CAPACITY, "LIST_CAPACITY too small");
    94   speculative_load_pclist[count] = __ pc();   // Used by the segfault handler
    89   speculative_load_pclist[count] = __ pc();   // Used by the segfault handler