1 /* |
1 /* |
2 * Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
1944 // Old SP |
1944 // Old SP |
1945 tty->print_cr("# -- Old %s -- Framesize: %d --",fp, |
1945 tty->print_cr("# -- Old %s -- Framesize: %d --",fp, |
1946 reg2offset_unchecked(OptoReg::add(_matcher._old_SP,-1)) - reg2offset_unchecked(_matcher._new_SP)+jintSize); |
1946 reg2offset_unchecked(OptoReg::add(_matcher._old_SP,-1)) - reg2offset_unchecked(_matcher._new_SP)+jintSize); |
1947 |
1947 |
1948 // Preserve area dump |
1948 // Preserve area dump |
|
1949 int fixed_slots = C->fixed_slots(); |
|
1950 OptoReg::Name begin_in_preserve = OptoReg::add(_matcher._old_SP, -(int)C->in_preserve_stack_slots()); |
|
1951 OptoReg::Name return_addr = _matcher.return_addr(); |
|
1952 |
1949 reg = OptoReg::add(reg, -1); |
1953 reg = OptoReg::add(reg, -1); |
1950 while( OptoReg::is_stack(reg)) { |
1954 while (OptoReg::is_stack(reg)) { |
1951 tty->print("#r%3.3d %s+%2d: ",reg,fp,reg2offset_unchecked(reg)); |
1955 tty->print("#r%3.3d %s+%2d: ",reg,fp,reg2offset_unchecked(reg)); |
1952 if( _matcher.return_addr() == reg ) |
1956 if (return_addr == reg) { |
1953 tty->print_cr("return address"); |
1957 tty->print_cr("return address"); |
1954 else if( _matcher.return_addr() == OptoReg::add(reg,1) && |
1958 } else if (reg >= begin_in_preserve) { |
1955 VerifyStackAtCalls ) |
1959 // Preserved slots are present on x86 |
1956 tty->print_cr("0xBADB100D +VerifyStackAtCalls"); |
1960 if (return_addr == OptoReg::add(reg, VMRegImpl::slots_per_word)) |
1957 else if ((int)OptoReg::reg2stack(reg) < C->fixed_slots()) |
1961 tty->print_cr("saved fp register"); |
|
1962 else if (return_addr == OptoReg::add(reg, 2*VMRegImpl::slots_per_word) && |
|
1963 VerifyStackAtCalls) |
|
1964 tty->print_cr("0xBADB100D +VerifyStackAtCalls"); |
|
1965 else |
|
1966 tty->print_cr("in_preserve"); |
|
1967 } else if ((int)OptoReg::reg2stack(reg) < fixed_slots) { |
1958 tty->print_cr("Fixed slot %d", OptoReg::reg2stack(reg)); |
1968 tty->print_cr("Fixed slot %d", OptoReg::reg2stack(reg)); |
1959 else |
1969 } else { |
1960 tty->print_cr("pad2, in_preserve"); |
1970 tty->print_cr("pad2, stack alignment"); |
|
1971 } |
1961 reg = OptoReg::add(reg, -1); |
1972 reg = OptoReg::add(reg, -1); |
1962 } |
1973 } |
1963 |
1974 |
1964 // Spill area dump |
1975 // Spill area dump |
1965 reg = OptoReg::add(_matcher._new_SP, _framesize ); |
1976 reg = OptoReg::add(_matcher._new_SP, _framesize ); |