1 /*
2 * Copyright (c) 2000, 2025, Oracle and/or its affiliates. All rights reserved.
3 * Copyright (c) 2012, 2025 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.
390 return (entry_frame_locals*) (((address) fp()) - entry_frame_locals_size);
391 }
392
393 enum {
394 // normal return address is 1 bundle past PC
395 pc_return_offset = 0,
396 // size, in words, of frame metadata (e.g. pc and link)
397 metadata_words = sizeof(java_abi) >> LogBytesPerWord,
398 // size, in words, of metadata at frame bottom, i.e. it is not part of the
399 // caller/callee overlap
400 metadata_words_at_bottom = 0,
401 // size, in words, of frame metadata at the frame top, i.e. it is located
402 // between a callee frame and its stack arguments, where it is part
403 // of the caller/callee overlap
404 metadata_words_at_top = sizeof(java_abi) >> LogBytesPerWord,
405 // size, in words, of frame metadata at the frame top that needs
406 // to be reserved for callee functions in the runtime
407 frame_alignment = 16,
408 frame_alignment_in_words = frame_alignment >> LogBytesPerWord,
409 // size, in words, of maximum shift in frame position due to alignment
410 align_wiggle = 1
411 };
412
413 static jint interpreter_frame_expression_stack_direction() { return -1; }
414
415 // returns the sending frame, without applying any barriers
416 inline frame sender_raw(RegisterMap* map) const;
417
418 #endif // CPU_PPC_FRAME_PPC_HPP
|
1 /*
2 * Copyright (c) 2000, 2026, Oracle and/or its affiliates. All rights reserved.
3 * Copyright (c) 2012, 2025 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.
390 return (entry_frame_locals*) (((address) fp()) - entry_frame_locals_size);
391 }
392
393 enum {
394 // normal return address is 1 bundle past PC
395 pc_return_offset = 0,
396 // size, in words, of frame metadata (e.g. pc and link)
397 metadata_words = sizeof(java_abi) >> LogBytesPerWord,
398 // size, in words, of metadata at frame bottom, i.e. it is not part of the
399 // caller/callee overlap
400 metadata_words_at_bottom = 0,
401 // size, in words, of frame metadata at the frame top, i.e. it is located
402 // between a callee frame and its stack arguments, where it is part
403 // of the caller/callee overlap
404 metadata_words_at_top = sizeof(java_abi) >> LogBytesPerWord,
405 // size, in words, of frame metadata at the frame top that needs
406 // to be reserved for callee functions in the runtime
407 frame_alignment = 16,
408 frame_alignment_in_words = frame_alignment >> LogBytesPerWord,
409 // size, in words, of maximum shift in frame position due to alignment
410 align_wiggle = 1,
411 // This is wrong and unimplemented
412 sender_sp_offset = 0
413 };
414
415 static jint interpreter_frame_expression_stack_direction() { return -1; }
416
417 // returns the sending frame, without applying any barriers
418 inline frame sender_raw(RegisterMap* map) const;
419
420 intptr_t* repair_sender_sp(intptr_t* sender_sp, intptr_t** saved_fp_addr) const;
421 static intptr_t* repair_sender_sp(nmethod* nm, intptr_t* sp, intptr_t** saved_fp_addr);
422 bool was_augmented_on_entry(int& real_size) const;
423
424 #endif // CPU_PPC_FRAME_PPC_HPP
|