6313046: Remove unused frame::native_param_addr code

Removed dead code in frame

Reviewed-by: dholmes, cjplummer, dsamersoff
This commit is contained in:
Mikael Vidstedt 2015-03-11 12:00:26 -07:00
parent fc9ab8f530
commit 2b6f0b511f
9 changed files with 12 additions and 65 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -63,10 +63,6 @@ public class PPC64Frame extends Frame {
// Entry frames
private static int ENTRY_FRAME_CALL_WRAPPER_OFFSET;
// Native frames
private static int NATIVE_FRAME_INITIAL_PARAM_OFFSET;
static {
VM.registerVMInitializedObserver(new Observer() {
public void update(Observable o, Object data) {
@ -76,10 +72,8 @@ public class PPC64Frame extends Frame {
}
private static synchronized void initialize(TypeDataBase db) {
int abi_minframe_size = db.lookupIntConstant("frame::abi_minframe_size").intValue();
int entry_frame_locals_size = db.lookupIntConstant("frame::entry_frame_locals_size").intValue();
int wordLength = (int) VM.getVM().getAddressSize();
NATIVE_FRAME_INITIAL_PARAM_OFFSET = -abi_minframe_size/wordLength;
ENTRY_FRAME_CALL_WRAPPER_OFFSET = -entry_frame_locals_size/wordLength;
}
@ -389,13 +383,6 @@ public class PPC64Frame extends Frame {
// Return address:
public Address getSenderPC() { return getSenderSP().getAddressAt(2 * VM.getVM().getAddressSize()); }
// return address of param, zero origin index.
// MPJ note: Appears to be unused.
public Address getNativeParamAddr(int idx) {
return null;
// return addressOfStackSlot(NATIVE_FRAME_INITIAL_PARAM_OFFSET + idx);
}
public Address getSenderSP() { return getFP(); }
public Address addressOfInterpreterFrameLocals() {
return addressOfStackSlot(INTERPRETER_FRAME_LOCALS_OFFSET);

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -63,9 +63,6 @@ public class X86Frame extends Frame {
// Entry frames
private static int ENTRY_FRAME_CALL_WRAPPER_OFFSET;
// Native frames
private static final int NATIVE_FRAME_INITIAL_PARAM_OFFSET = 2;
private static VMReg rbp;
static {
@ -423,20 +420,12 @@ public class X86Frame extends Frame {
return addressOfStackSlot(LINK_OFFSET).getAddressAt(0);
}
// FIXME: not implementable yet
//inline void frame::set_link(intptr_t* addr) { *(intptr_t **)addr_at(link_offset) = addr; }
public Address getUnextendedSP() { return raw_unextendedSP; }
// Return address:
public Address getSenderPCAddr() { return addressOfStackSlot(RETURN_ADDR_OFFSET); }
public Address getSenderPC() { return getSenderPCAddr().getAddressAt(0); }
// return address of param, zero origin index.
public Address getNativeParamAddr(int idx) {
return addressOfStackSlot(NATIVE_FRAME_INITIAL_PARAM_OFFSET + idx);
}
public Address getSenderSP() { return addressOfStackSlot(SENDER_SP_OFFSET); }
public Address addressOfInterpreterFrameLocals() {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, Red Hat Inc. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@ -136,12 +136,7 @@
entry_frame_call_wrapper_offset = -8,
// we don't need a save area
arg_reg_save_area_bytes = 0,
// TODO - check that this is still correct
// Native frames
native_frame_initial_param_offset = 2
arg_reg_save_area_bytes = 0
};
@ -195,9 +190,6 @@
inline address* sender_pc_addr() const;
// return address of param, zero origin index.
inline address* native_param_addr(int idx) const;
// expression stack tos if we are nested in a java call
intptr_t* interpreter_frame_last_sp() const;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, Red Hat Inc. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@ -166,7 +166,6 @@ inline bool frame::is_older(intptr_t* id) const { assert(this->id() != NULL &&
inline intptr_t* frame::link() const { return (intptr_t*) *(intptr_t **)addr_at(link_offset); }
inline void frame::set_link(intptr_t* addr) { *(intptr_t **)addr_at(link_offset) = addr; }
inline intptr_t* frame::unextended_sp() const { return _unextended_sp; }
@ -176,9 +175,6 @@ inline intptr_t* frame::unextended_sp() const { return _unextended_sp; }
inline address* frame::sender_pc_addr() const { return (address*) addr_at( return_addr_offset); }
inline address frame::sender_pc() const { return *sender_pc_addr(); }
// return address of param, zero origin index.
inline address* frame::native_param_addr(int idx) const { return (address*) addr_at( native_frame_initial_param_offset+idx); }
#ifdef CC_INTERP
inline interpreterState frame::get_interpreterState() const {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -69,8 +69,6 @@ inline int frame::frame_size(RegisterMap* map) const { return sender_sp() - sp()
inline intptr_t* frame::link() const { return (intptr_t *)(fp()[FP->sp_offset_in_saved_window()] + STACK_BIAS); }
inline void frame::set_link(intptr_t* addr) { assert(link()==addr, "frame nesting is controlled by hardware"); }
inline intptr_t* frame::unextended_sp() const { return sp() + _sp_adjustment_by_callee; }
// return address:

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -128,21 +128,16 @@
entry_frame_after_call_words = 28,
entry_frame_call_wrapper_offset = 2,
arg_reg_save_area_bytes = 32, // Register argument save area
arg_reg_save_area_bytes = 32 // Register argument save area
#else
entry_frame_after_call_words = 13,
entry_frame_call_wrapper_offset = -6,
arg_reg_save_area_bytes = 0,
arg_reg_save_area_bytes = 0
#endif // _WIN64
#else
entry_frame_call_wrapper_offset = 2,
entry_frame_call_wrapper_offset = 2
#endif // AMD64
// Native frames
native_frame_initial_param_offset = 2
};
intptr_t ptr_at(int offset) const {
@ -195,9 +190,6 @@
inline address* sender_pc_addr() const;
// return address of param, zero origin index.
inline address* native_param_addr(int idx) const;
// expression stack tos if we are nested in a java call
intptr_t* interpreter_frame_last_sp() const;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -139,8 +139,6 @@ inline bool frame::is_older(intptr_t* id) const { assert(this->id() != NULL &&
inline intptr_t* frame::link() const { return (intptr_t*) *(intptr_t **)addr_at(link_offset); }
inline void frame::set_link(intptr_t* addr) { *(intptr_t **)addr_at(link_offset) = addr; }
inline intptr_t* frame::unextended_sp() const { return _unextended_sp; }
@ -149,9 +147,6 @@ inline intptr_t* frame::unextended_sp() const { return _unextended_sp; }
inline address* frame::sender_pc_addr() const { return (address*) addr_at( return_addr_offset); }
inline address frame::sender_pc() const { return *sender_pc_addr(); }
// return address of param, zero origin index.
inline address* frame::native_param_addr(int idx) const { return (address*) addr_at( native_frame_initial_param_offset+idx); }
#ifdef CC_INTERP
inline interpreterState frame::get_interpreterState() const {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -194,7 +194,6 @@ class frame VALUE_OBJ_CLASS_SPEC {
public:
// Link (i.e., the pointer to the previous frame)
intptr_t* link() const;
void set_link(intptr_t* addr);
// Return address
address sender_pc() const;

View File

@ -2584,7 +2584,6 @@ typedef CompactHashtable<Symbol*, char> SymbolCompactHashTable;
/**********************/ \
/* frame */ \
/**********************/ \
NOT_ZERO(PPC64_ONLY(declare_constant(frame::abi_minframe_size))) \
NOT_ZERO(PPC64_ONLY(declare_constant(frame::entry_frame_locals_size))) \
\
NOT_ZERO(X86_ONLY(declare_constant(frame::entry_frame_call_wrapper_offset))) \