src/os_cpu/aix_ppc/vm/thread_aix_ppc.hpp

Fri, 12 Dec 2014 08:48:56 +0100

author
goetz
date
Fri, 12 Dec 2014 08:48:56 +0100
changeset 7424
c5e86c5cd22e
parent 0
f90c822e73f8
permissions
-rw-r--r--

8066964: ppc64: argument and return type profiling, fix problem with popframe
Reviewed-by: roland, kvn

aoqi@0 1 /*
aoqi@0 2 * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
aoqi@0 3 * Copyright 2012, 2013 SAP AG. All rights reserved.
aoqi@0 4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
aoqi@0 5 *
aoqi@0 6 * This code is free software; you can redistribute it and/or modify it
aoqi@0 7 * under the terms of the GNU General Public License version 2 only, as
aoqi@0 8 * published by the Free Software Foundation.
aoqi@0 9 *
aoqi@0 10 * This code is distributed in the hope that it will be useful, but WITHOUT
aoqi@0 11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
aoqi@0 12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
aoqi@0 13 * version 2 for more details (a copy is included in the LICENSE file that
aoqi@0 14 * accompanied this code).
aoqi@0 15 *
aoqi@0 16 * You should have received a copy of the GNU General Public License version
aoqi@0 17 * 2 along with this work; if not, write to the Free Software Foundation,
aoqi@0 18 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
aoqi@0 19 *
aoqi@0 20 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
aoqi@0 21 * or visit www.oracle.com if you need additional information or have any
aoqi@0 22 * questions.
aoqi@0 23 *
aoqi@0 24 */
aoqi@0 25
goetz@7424 26 #ifndef OS_CPU_AIX_PPC_VM_THREAD_AIX_PPC_HPP
goetz@7424 27 #define OS_CPU_AIX_PPC_VM_THREAD_AIX_PPC_HPP
aoqi@0 28
aoqi@0 29 private:
aoqi@0 30 void pd_initialize() {
aoqi@0 31 _anchor.clear();
aoqi@0 32 _last_interpreter_fp = NULL;
aoqi@0 33 }
aoqi@0 34
aoqi@0 35 // The `last' frame is the youngest Java frame on the thread's stack.
aoqi@0 36 frame pd_last_frame() {
aoqi@0 37 assert(has_last_Java_frame(), "must have last_Java_sp() when suspended");
aoqi@0 38
aoqi@0 39 intptr_t* sp = last_Java_sp();
aoqi@0 40 address pc = _anchor.last_Java_pc();
aoqi@0 41
aoqi@0 42 // Last_Java_pc ist not set, if we come here from compiled code.
aoqi@0 43 if (pc == NULL)
aoqi@0 44 pc = (address) *(sp + 2);
aoqi@0 45
aoqi@0 46 return frame(sp, pc);
aoqi@0 47 }
aoqi@0 48
aoqi@0 49 public:
aoqi@0 50 void set_base_of_stack_pointer(intptr_t* base_sp) {}
aoqi@0 51 intptr_t* base_of_stack_pointer() { return NULL; }
aoqi@0 52 void record_base_of_stack_pointer() {}
aoqi@0 53
aoqi@0 54 // These routines are only used on cpu architectures that
aoqi@0 55 // have separate register stacks (Itanium).
aoqi@0 56 static bool register_stack_overflow() { return false; }
aoqi@0 57 static void enable_register_stack_guard() {}
aoqi@0 58 static void disable_register_stack_guard() {}
aoqi@0 59
aoqi@0 60 bool pd_get_top_frame_for_signal_handler(frame* fr_addr, void* ucontext,
aoqi@0 61 bool isInJava);
aoqi@0 62
aoqi@0 63 // -Xprof support
aoqi@0 64 //
aoqi@0 65 // In order to find the last Java fp from an async profile
aoqi@0 66 // tick, we store the current interpreter fp in the thread.
aoqi@0 67 // This value is only valid while we are in the C++ interpreter
aoqi@0 68 // and profiling.
aoqi@0 69 protected:
aoqi@0 70 intptr_t *_last_interpreter_fp;
aoqi@0 71
aoqi@0 72 public:
aoqi@0 73 static ByteSize last_interpreter_fp_offset() {
aoqi@0 74 return byte_offset_of(JavaThread, _last_interpreter_fp);
aoqi@0 75 }
aoqi@0 76
aoqi@0 77 intptr_t* last_interpreter_fp() { return _last_interpreter_fp; }
aoqi@0 78
goetz@7424 79 #endif // OS_CPU_AIX_PPC_VM_THREAD_AIX_PPC_HPP

mercurial