1 /*
2 * Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved.
3 * Copyright (c) 2012, 2016 SAP SE. All rights reserved.
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 *
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
8 * published by the Free Software Foundation.
9 *
10 * This code is distributed in the hope that it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 * version 2 for more details (a copy is included in the LICENSE file that
14 * accompanied this code).
15 *
16 * You should have received a copy of the GNU General Public License version
17 * 2 along with this work; if not, write to the Free Software Foundation,
18 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
19 *
20 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
21 * or visit www.oracle.com if you need additional information or have any
22 * questions.
23 *
631 #endif
632
633 void compiler_fast_lock_object(ConditionRegister flag, Register oop, Register box,
634 Register tmp1, Register tmp2, Register tmp3,
635 bool try_bias = UseBiasedLocking,
636 RTMLockingCounters* rtm_counters = NULL,
637 RTMLockingCounters* stack_rtm_counters = NULL,
638 Metadata* method_data = NULL,
639 bool use_rtm = false, bool profile_rtm = false);
640
641 void compiler_fast_unlock_object(ConditionRegister flag, Register oop, Register box,
642 Register tmp1, Register tmp2, Register tmp3,
643 bool try_bias = UseBiasedLocking, bool use_rtm = false);
644
645 // Support for serializing memory accesses between threads
646 void serialize_memory(Register thread, Register tmp1, Register tmp2);
647
648 // GC barrier support.
649 void card_write_barrier_post(Register Rstore_addr, Register Rnew_val, Register Rtmp);
650 void card_table_write(jbyte* byte_map_base, Register Rtmp, Register Robj);
651
652 #if INCLUDE_ALL_GCS
653 // General G1 pre-barrier generator.
654 void g1_write_barrier_pre(Register Robj, RegisterOrConstant offset, Register Rpre_val,
655 Register Rtmp1, Register Rtmp2, bool needs_frame = false);
656 // General G1 post-barrier generator
657 void g1_write_barrier_post(Register Rstore_addr, Register Rnew_val, Register Rtmp1,
658 Register Rtmp2, Register Rtmp3, Label *filtered_ext = NULL);
659 #endif
660
661 // Support for managing the JavaThread pointer (i.e.; the reference to
662 // thread-local information).
663
664 // Support for last Java frame (but use call_VM instead where possible):
665 // access R16_thread->last_Java_sp.
666 void set_last_Java_frame(Register last_java_sp, Register last_Java_pc);
667 void reset_last_Java_frame(void);
668 void set_top_ijava_frame_at_SP_as_last_Java_frame(Register sp, Register tmp1);
669
670 // Read vm result from thread: oop_result = R16_thread->result;
|
1 /*
2 * Copyright (c) 2002, 2017, Oracle and/or its affiliates. All rights reserved.
3 * Copyright (c) 2012, 2017 SAP SE. All rights reserved.
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 *
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
8 * published by the Free Software Foundation.
9 *
10 * This code is distributed in the hope that it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 * version 2 for more details (a copy is included in the LICENSE file that
14 * accompanied this code).
15 *
16 * You should have received a copy of the GNU General Public License version
17 * 2 along with this work; if not, write to the Free Software Foundation,
18 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
19 *
20 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
21 * or visit www.oracle.com if you need additional information or have any
22 * questions.
23 *
631 #endif
632
633 void compiler_fast_lock_object(ConditionRegister flag, Register oop, Register box,
634 Register tmp1, Register tmp2, Register tmp3,
635 bool try_bias = UseBiasedLocking,
636 RTMLockingCounters* rtm_counters = NULL,
637 RTMLockingCounters* stack_rtm_counters = NULL,
638 Metadata* method_data = NULL,
639 bool use_rtm = false, bool profile_rtm = false);
640
641 void compiler_fast_unlock_object(ConditionRegister flag, Register oop, Register box,
642 Register tmp1, Register tmp2, Register tmp3,
643 bool try_bias = UseBiasedLocking, bool use_rtm = false);
644
645 // Support for serializing memory accesses between threads
646 void serialize_memory(Register thread, Register tmp1, Register tmp2);
647
648 // GC barrier support.
649 void card_write_barrier_post(Register Rstore_addr, Register Rnew_val, Register Rtmp);
650 void card_table_write(jbyte* byte_map_base, Register Rtmp, Register Robj);
651
652 void resolve_jobject(Register value, Register tmp1, Register tmp2, bool needs_frame);
653
654 #if INCLUDE_ALL_GCS
655 // General G1 pre-barrier generator.
656 void g1_write_barrier_pre(Register Robj, RegisterOrConstant offset, Register Rpre_val,
657 Register Rtmp1, Register Rtmp2, bool needs_frame = false);
658 // General G1 post-barrier generator
659 void g1_write_barrier_post(Register Rstore_addr, Register Rnew_val, Register Rtmp1,
660 Register Rtmp2, Register Rtmp3, Label *filtered_ext = NULL);
661 #endif
662
663 // Support for managing the JavaThread pointer (i.e.; the reference to
664 // thread-local information).
665
666 // Support for last Java frame (but use call_VM instead where possible):
667 // access R16_thread->last_Java_sp.
668 void set_last_Java_frame(Register last_java_sp, Register last_Java_pc);
669 void reset_last_Java_frame(void);
670 void set_top_ijava_frame_at_SP_as_last_Java_frame(Register sp, Register tmp1);
671
672 // Read vm result from thread: oop_result = R16_thread->result;
|