diff --git a/src/hotspot/cpu/ppc/ppc.ad b/src/hotspot/cpu/ppc/ppc.ad index 6e0a7667be081..b03e386fa942d 100644 --- a/src/hotspot/cpu/ppc/ppc.ad +++ b/src/hotspot/cpu/ppc/ppc.ad @@ -1,6 +1,6 @@ // // Copyright (c) 2011, 2023, Oracle and/or its affiliates. All rights reserved. -// Copyright (c) 2012, 2022 SAP SE. All rights reserved. +// Copyright (c) 2012, 2023 SAP SE. 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 @@ -3412,6 +3412,7 @@ encode %{ if (!_method) { // A call to a runtime wrapper, e.g. new, new_typeArray_Java, uncommon_trap. emit_call_with_trampoline_stub(_masm, entry_point, relocInfo::runtime_call_type); + if (ciEnv::current()->failing()) { return; } // Code cache may be full. } else { // Remember the offset not the address. const int start_offset = __ offset(); @@ -3582,6 +3583,7 @@ encode %{ // to determine who we intended to call. __ relocate(virtual_call_Relocation::spec(virtual_call_meta_addr)); emit_call_with_trampoline_stub(_masm, (address)$meth$$method, relocInfo::none); + if (ciEnv::current()->failing()) { return; } // Code cache may be full. assert(((MachCallDynamicJavaNode*)this)->ret_addr_offset() == __ offset() - start_offset, "Fix constant in ret_addr_offset(), expected %d", __ offset() - start_offset); } else {