1*38fd1498Szrj/* This file contains the definitions of the cgraph_inline_failed_t 2*38fd1498Szrj enums used in GCC. 3*38fd1498Szrj 4*38fd1498Szrj Copyright (C) 2008-2018 Free Software Foundation, Inc. 5*38fd1498Szrj Contributed by Doug Kwan <dougkwan@google.com> 6*38fd1498Szrj 7*38fd1498SzrjThis file is part of GCC. 8*38fd1498Szrj 9*38fd1498SzrjGCC is free software you can redistribute it and/or modify it under 10*38fd1498Szrjthe terms of the GNU General Public License as published by the Free 11*38fd1498SzrjSoftware Foundation either version 3, or (at your option) any later 12*38fd1498Szrjversion. 13*38fd1498Szrj 14*38fd1498SzrjGCC is distributed in the hope that it will be useful, but WITHOUT ANY 15*38fd1498SzrjWARRANTY without even the implied warranty of MERCHANTABILITY or 16*38fd1498SzrjFITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 17*38fd1498Szrjfor more details. 18*38fd1498Szrj 19*38fd1498SzrjYou should have received a copy of the GNU General Public License 20*38fd1498Szrjalong with GCC see the file COPYING3. If not see 21*38fd1498Szrj<http://www.gnu.org/licenses/>. */ 22*38fd1498Szrj 23*38fd1498Szrj/* The format of this file is 24*38fd1498Szrj DEFCIFCODE(code, string). 25*38fd1498Szrj 26*38fd1498Szrj Where symbol is the enumeration name without the ``''. 27*38fd1498Szrj The argument STRING is a explain the failure. Except for OK, 28*38fd1498Szrj which is a NULL pointer. */ 29*38fd1498Szrj 30*38fd1498Szrj/* Inlining successful. This must be the first code. */ 31*38fd1498SzrjDEFCIFCODE(OK, CIF_FINAL_NORMAL, NULL) 32*38fd1498Szrj 33*38fd1498Szrj/* Inlining failed for an unspecified reason. */ 34*38fd1498SzrjDEFCIFCODE(UNSPECIFIED, CIF_FINAL_ERROR, "") 35*38fd1498Szrj 36*38fd1498Szrj/* Function has not be considered for inlining. This is the code for 37*38fd1498Szrj functions that have not been rejected for inlining yet. */ 38*38fd1498SzrjDEFCIFCODE(FUNCTION_NOT_CONSIDERED, CIF_FINAL_NORMAL, 39*38fd1498Szrj N_("function not considered for inlining")) 40*38fd1498Szrj 41*38fd1498Szrj/* Caller is compiled with optimizations disabled. */ 42*38fd1498SzrjDEFCIFCODE(FUNCTION_NOT_OPTIMIZED, CIF_FINAL_ERROR, 43*38fd1498Szrj N_("caller is not optimized")) 44*38fd1498Szrj 45*38fd1498Szrj/* Inlining failed owing to unavailable function body. */ 46*38fd1498SzrjDEFCIFCODE(BODY_NOT_AVAILABLE, CIF_FINAL_ERROR, 47*38fd1498Szrj N_("function body not available")) 48*38fd1498Szrj 49*38fd1498Szrj/* Extern inline function that has been redefined. */ 50*38fd1498SzrjDEFCIFCODE(REDEFINED_EXTERN_INLINE, CIF_FINAL_ERROR, 51*38fd1498Szrj N_("redefined extern inline functions are not considered for " 52*38fd1498Szrj "inlining")) 53*38fd1498Szrj 54*38fd1498Szrj/* Function is not inlinable. */ 55*38fd1498SzrjDEFCIFCODE(FUNCTION_NOT_INLINABLE, CIF_FINAL_ERROR, 56*38fd1498Szrj N_("function not inlinable")) 57*38fd1498Szrj 58*38fd1498Szrj/* Function is overwritable. */ 59*38fd1498SzrjDEFCIFCODE(OVERWRITABLE, CIF_FINAL_ERROR, 60*38fd1498Szrj N_("function body can be overwritten at link time")) 61*38fd1498Szrj 62*38fd1498Szrj/* Function is not an inlining candidate. */ 63*38fd1498SzrjDEFCIFCODE(FUNCTION_NOT_INLINE_CANDIDATE, CIF_FINAL_NORMAL, 64*38fd1498Szrj N_("function not inline candidate")) 65*38fd1498Szrj 66*38fd1498Szrj/* Inlining failed because of various limit parameters. */ 67*38fd1498SzrjDEFCIFCODE(LARGE_FUNCTION_GROWTH_LIMIT, CIF_FINAL_NORMAL, 68*38fd1498Szrj N_("--param large-function-growth limit reached")) 69*38fd1498SzrjDEFCIFCODE(LARGE_STACK_FRAME_GROWTH_LIMIT, CIF_FINAL_NORMAL, 70*38fd1498Szrj N_("--param large-stack-frame-growth limit reached")) 71*38fd1498SzrjDEFCIFCODE(MAX_INLINE_INSNS_SINGLE_LIMIT, CIF_FINAL_NORMAL, 72*38fd1498Szrj N_("--param max-inline-insns-single limit reached")) 73*38fd1498SzrjDEFCIFCODE(MAX_INLINE_INSNS_AUTO_LIMIT, CIF_FINAL_NORMAL, 74*38fd1498Szrj N_("--param max-inline-insns-auto limit reached")) 75*38fd1498SzrjDEFCIFCODE(INLINE_UNIT_GROWTH_LIMIT, CIF_FINAL_NORMAL, 76*38fd1498Szrj N_("--param inline-unit-growth limit reached")) 77*38fd1498Szrj 78*38fd1498Szrj/* Recursive inlining. */ 79*38fd1498SzrjDEFCIFCODE(RECURSIVE_INLINING, CIF_FINAL_NORMAL, 80*38fd1498Szrj N_("recursive inlining")) 81*38fd1498Szrj 82*38fd1498Szrj/* Call is unlikely. */ 83*38fd1498SzrjDEFCIFCODE(UNLIKELY_CALL, CIF_FINAL_NORMAL, 84*38fd1498Szrj N_("call is unlikely and code size would grow")) 85*38fd1498Szrj 86*38fd1498Szrj/* Function is not declared as inline. */ 87*38fd1498SzrjDEFCIFCODE(NOT_DECLARED_INLINED, CIF_FINAL_NORMAL, 88*38fd1498Szrj N_("function not declared inline and code size would grow")) 89*38fd1498Szrj 90*38fd1498Szrj/* Caller and callee disagree on the arguments. */ 91*38fd1498SzrjDEFCIFCODE(MISMATCHED_ARGUMENTS, CIF_FINAL_ERROR, 92*38fd1498Szrj N_("mismatched arguments")) 93*38fd1498Szrj 94*38fd1498Szrj/* Caller and callee disagree on the arguments. */ 95*38fd1498SzrjDEFCIFCODE(LTO_MISMATCHED_DECLARATIONS, CIF_FINAL_ERROR, 96*38fd1498Szrj N_("mismatched declarations during linktime optimization")) 97*38fd1498Szrj 98*38fd1498Szrj/* Caller is variadic thunk. */ 99*38fd1498SzrjDEFCIFCODE(VARIADIC_THUNK, CIF_FINAL_ERROR, 100*38fd1498Szrj N_("variadic thunk call")) 101*38fd1498Szrj 102*38fd1498Szrj/* Call was originally indirect. */ 103*38fd1498SzrjDEFCIFCODE(ORIGINALLY_INDIRECT_CALL, CIF_FINAL_NORMAL, 104*38fd1498Szrj N_("originally indirect function call not considered for inlining")) 105*38fd1498Szrj 106*38fd1498Szrj/* Ths edge represents an indirect edge with a yet-undetermined callee . */ 107*38fd1498SzrjDEFCIFCODE(INDIRECT_UNKNOWN_CALL, CIF_FINAL_NORMAL, 108*38fd1498Szrj N_("indirect function call with a yet undetermined callee")) 109*38fd1498Szrj 110*38fd1498Szrj/* We can't inline different EH personalities together. */ 111*38fd1498SzrjDEFCIFCODE(EH_PERSONALITY, CIF_FINAL_ERROR, 112*38fd1498Szrj N_("exception handling personality mismatch")) 113*38fd1498Szrj 114*38fd1498Szrj/* We can't inline if the callee can throw non-call exceptions but the 115*38fd1498Szrj caller cannot. */ 116*38fd1498SzrjDEFCIFCODE(NON_CALL_EXCEPTIONS, CIF_FINAL_ERROR, 117*38fd1498Szrj N_("non-call exception handling mismatch")) 118*38fd1498Szrj 119*38fd1498Szrj/* We can't inline because of mismatched target specific options. */ 120*38fd1498SzrjDEFCIFCODE(TARGET_OPTION_MISMATCH, CIF_FINAL_ERROR, 121*38fd1498Szrj N_("target specific option mismatch")) 122*38fd1498Szrj 123*38fd1498Szrj/* We can't inline because of mismatched optimization levels. */ 124*38fd1498SzrjDEFCIFCODE(OPTIMIZATION_MISMATCH, CIF_FINAL_ERROR, 125*38fd1498Szrj N_("optimization level attribute mismatch")) 126*38fd1498Szrj 127*38fd1498Szrj/* We can't inline because the callee refers to comdat-local symbols. */ 128*38fd1498SzrjDEFCIFCODE(USES_COMDAT_LOCAL, CIF_FINAL_ERROR, 129*38fd1498Szrj N_("callee refers to comdat-local symbols")) 130*38fd1498Szrj 131*38fd1498Szrj/* We can't inline because of mismatched caller/callee attributes. */ 132*38fd1498SzrjDEFCIFCODE(ATTRIBUTE_MISMATCH, CIF_FINAL_ERROR, 133*38fd1498Szrj N_("function attribute mismatch")) 134*38fd1498Szrj 135*38fd1498Szrj/* We proved that the call is unreachable. */ 136*38fd1498SzrjDEFCIFCODE(UNREACHABLE, CIF_FINAL_ERROR, 137*38fd1498Szrj N_("unreachable")) 138*38fd1498Szrj 139*38fd1498Szrj/* We can't inline because of instrumentation thunk. */ 140*38fd1498SzrjDEFCIFCODE(CHKP, CIF_FINAL_ERROR, 141*38fd1498Szrj N_("caller is instrumentation thunk")) 142