GCC Middle and Back End API Reference
function-abi.cc File Reference
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "backend.h"
#include "target.h"
#include "rtl.h"
#include "tree.h"
#include "regs.h"
#include "function-abi.h"
#include "varasm.h"
#include "cgraph.h"
Include dependency graph for function-abi.cc:

Functions

HARD_REG_SET call_clobbers_in_region (unsigned int abis, const_hard_reg_set mask, machine_mode mode)
 
const predefined_function_abifntype_abi (const_tree type)
 
function_abi fndecl_abi (const_tree fndecl)
 
function_abi insn_callee_abi (const rtx_insn *insn)
 
function_abi expr_callee_abi (const_tree exp)
 

Variables

target_function_abi_info default_target_function_abi_info
 

Function Documentation

◆ call_clobbers_in_region()

HARD_REG_SET call_clobbers_in_region ( unsigned int abis,
const_hard_reg_set mask,
machine_mode mode )
Return the set of registers that cannot be used to hold a value of mode MODE across the calls in a region described by ABIS and MASK, where: * Bit ID of ABIS is set if the region contains a call with function_abi identifier ID. * MASK contains all the registers that are fully or partially clobbered by calls in the region. This is not quite as accurate as testing each individual call, but it's a close and conservatively-correct approximation. It's much better for some targets than just using MASK.

References CLEAR_HARD_REG_SET, and function_abis.

Referenced by call_clobbered_in_region_p(), and ira_need_caller_save_regs().

◆ expr_callee_abi()

function_abi expr_callee_abi ( const_tree exp)
Return the ABI of the function called by CALL_EXPR EXP. Return the default ABI for erroneous calls.

References CALL_EXPR_FN, default_function_abi, error_mark_node, exp(), fndecl_abi(), fntype_abi(), gcc_assert, get_callee_fndecl(), POINTER_TYPE_P, TREE_CODE, and TREE_TYPE.

◆ fndecl_abi()

◆ fntype_abi()

const predefined_function_abi & fntype_abi ( const_tree type)
Return the predefined ABI used by functions with type TYPE.

References default_function_abi, FUNC_OR_METHOD_TYPE_P, gcc_assert, and targetm.

Referenced by aggregate_value_p(), expr_callee_abi(), and fndecl_abi().

◆ insn_callee_abi()

Variable Documentation

◆ default_target_function_abi_info

target_function_abi_info default_target_function_abi_info
Information about fuunction binary interfaces. Copyright (C) 2019-2025 Free Software Foundation, Inc. This file is part of GCC GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version. GCC is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with GCC; see the file COPYING3. If not see <http://www.gnu.org/licenses/>.