static inline int local_symbolic_operand_1 (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED) #line 442 "../.././gcc/config/i386/predicates.md" { if (GET_CODE (op) == CONST && GET_CODE (XEXP (op, 0)) == PLUS && CONST_INT_P (XEXP (XEXP (op, 0), 1))) op = XEXP (XEXP (op, 0), 0); if (GET_CODE (op) == LABEL_REF) return 1; if (GET_CODE (op) != SYMBOL_REF) return 0; if (SYMBOL_REF_TLS_MODEL (op) != 0) return 0; if (SYMBOL_REF_LOCAL_P (op)) return 1; /* There is, however, a not insubstantial body of code in the rest of the compiler that assumes it can just stick the results of ASM_GENERATE_INTERNAL_LABEL in a symbol_ref and have done. */ /* ??? This is a hack. Should update the body of the compiler to always create a DECL an invoke targetm.encode_section_info. */ if (strncmp (XSTR (op, 0), internal_label_prefix, internal_label_prefix_len) == 0) return 1; return 0; }
static int indirectable_constant_address_p (rtx x) { if (!CONSTANT_ADDRESS_P (x)) return 0; if (GET_CODE (x) == CONST && GET_CODE (XEXP ((x), 0)) == PLUS) x = XEXP (XEXP (x, 0), 0); if (GET_CODE (x) == SYMBOL_REF && !SYMBOL_REF_LOCAL_P (x)) return 0; return 1; }
/* Return true if SYM_REF can be used without an indirection. */ static int machopic_symbol_defined_p (rtx sym_ref) { if (SYMBOL_REF_FLAGS (sym_ref) & MACHO_SYMBOL_FLAG_DEFINED) return true; /* If a symbol references local and is not an extern to this file, then the symbol might be able to declared as defined. */ if (SYMBOL_REF_LOCAL_P (sym_ref) && ! SYMBOL_REF_EXTERNAL_P (sym_ref)) { /* If the symbol references a variable and the variable is a common symbol, then this symbol is not defined. */ if (SYMBOL_REF_FLAGS (sym_ref) & MACHO_SYMBOL_FLAG_VARIABLE) { tree decl = SYMBOL_REF_DECL (sym_ref); if (!decl) return true; if (DECL_COMMON (decl)) return false; } return true; } return false; }