⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dwarfout.c

📁 GUN开源阻止下的编译器GCC
💻 C
📖 第 1 页 / 共 5 页
字号:
    case TAG_local_variable:		return "TAG_local_variable";    case TAG_member:			return "TAG_member";    case TAG_pointer_type:		return "TAG_pointer_type";    case TAG_reference_type:		return "TAG_reference_type";    case TAG_compile_unit:		return "TAG_compile_unit";    case TAG_string_type:		return "TAG_string_type";    case TAG_structure_type:		return "TAG_structure_type";    case TAG_subroutine:		return "TAG_subroutine";    case TAG_subroutine_type:		return "TAG_subroutine_type";    case TAG_typedef:			return "TAG_typedef";    case TAG_union_type:		return "TAG_union_type";    case TAG_unspecified_parameters:	return "TAG_unspecified_parameters";    case TAG_variant:			return "TAG_variant";    case TAG_common_block:		return "TAG_common_block";    case TAG_common_inclusion:		return "TAG_common_inclusion";    case TAG_inheritance:		return "TAG_inheritance";    case TAG_inlined_subroutine:	return "TAG_inlined_subroutine";    case TAG_module:			return "TAG_module";    case TAG_ptr_to_member_type:	return "TAG_ptr_to_member_type";    case TAG_set_type:			return "TAG_set_type";    case TAG_subrange_type:		return "TAG_subrange_type";    case TAG_with_stmt:			return "TAG_with_stmt";    /* GNU extensions.  */    case TAG_format_label:		return "TAG_format_label";    case TAG_namelist:			return "TAG_namelist";    case TAG_function_template:		return "TAG_function_template";    case TAG_class_template:		return "TAG_class_template";    default:				return "TAG_<unknown>";    }}static char *dwarf_attr_name (attr)     register unsigned attr;{  switch (attr)    {    case AT_sibling:			return "AT_sibling";    case AT_location:			return "AT_location";    case AT_name:			return "AT_name";    case AT_fund_type:			return "AT_fund_type";    case AT_mod_fund_type:		return "AT_mod_fund_type";    case AT_user_def_type:		return "AT_user_def_type";    case AT_mod_u_d_type:		return "AT_mod_u_d_type";    case AT_ordering:			return "AT_ordering";    case AT_subscr_data:		return "AT_subscr_data";    case AT_byte_size:			return "AT_byte_size";    case AT_bit_offset:			return "AT_bit_offset";    case AT_bit_size:			return "AT_bit_size";    case AT_element_list:		return "AT_element_list";    case AT_stmt_list:			return "AT_stmt_list";    case AT_low_pc:			return "AT_low_pc";    case AT_high_pc:			return "AT_high_pc";    case AT_language:			return "AT_language";    case AT_member:			return "AT_member";    case AT_discr:			return "AT_discr";    case AT_discr_value:		return "AT_discr_value";    case AT_string_length:		return "AT_string_length";    case AT_common_reference:		return "AT_common_reference";    case AT_comp_dir:			return "AT_comp_dir";    case AT_const_value_string:		return "AT_const_value_string";    case AT_const_value_data2:		return "AT_const_value_data2";    case AT_const_value_data4:		return "AT_const_value_data4";    case AT_const_value_data8:		return "AT_const_value_data8";    case AT_const_value_block2:		return "AT_const_value_block2";    case AT_const_value_block4:		return "AT_const_value_block4";    case AT_containing_type:		return "AT_containing_type";    case AT_default_value_addr:		return "AT_default_value_addr";    case AT_default_value_data2:	return "AT_default_value_data2";    case AT_default_value_data4:	return "AT_default_value_data4";    case AT_default_value_data8:	return "AT_default_value_data8";    case AT_default_value_string:	return "AT_default_value_string";    case AT_friends:			return "AT_friends";    case AT_inline:			return "AT_inline";    case AT_is_optional:		return "AT_is_optional";    case AT_lower_bound_ref:		return "AT_lower_bound_ref";    case AT_lower_bound_data2:		return "AT_lower_bound_data2";    case AT_lower_bound_data4:		return "AT_lower_bound_data4";    case AT_lower_bound_data8:		return "AT_lower_bound_data8";    case AT_private:			return "AT_private";    case AT_producer:			return "AT_producer";    case AT_program:			return "AT_program";    case AT_protected:			return "AT_protected";    case AT_prototyped:			return "AT_prototyped";    case AT_public:			return "AT_public";    case AT_pure_virtual:		return "AT_pure_virtual";    case AT_return_addr:		return "AT_return_addr";    case AT_abstract_origin:		return "AT_abstract_origin";    case AT_start_scope:		return "AT_start_scope";    case AT_stride_size:		return "AT_stride_size";    case AT_upper_bound_ref:		return "AT_upper_bound_ref";    case AT_upper_bound_data2:		return "AT_upper_bound_data2";    case AT_upper_bound_data4:		return "AT_upper_bound_data4";    case AT_upper_bound_data8:		return "AT_upper_bound_data8";    case AT_virtual:			return "AT_virtual";    /* GNU extensions */    case AT_sf_names:			return "AT_sf_names";    case AT_src_info:			return "AT_src_info";    case AT_mac_info:			return "AT_mac_info";    case AT_src_coords:			return "AT_src_coords";    case AT_body_begin:			return "AT_body_begin";    case AT_body_end:			return "AT_body_end";    default:				return "AT_<unknown>";    }}static char *dwarf_stack_op_name (op)     register unsigned op;{  switch (op)    {    case OP_REG:		return "OP_REG";    case OP_BASEREG:		return "OP_BASEREG";    case OP_ADDR:		return "OP_ADDR";    case OP_CONST:		return "OP_CONST";    case OP_DEREF2:		return "OP_DEREF2";    case OP_DEREF4:		return "OP_DEREF4";    case OP_ADD:		return "OP_ADD";    default:			return "OP_<unknown>";    }}static char *dwarf_typemod_name (mod)     register unsigned mod;{  switch (mod)    {    case MOD_pointer_to:	return "MOD_pointer_to";    case MOD_reference_to:	return "MOD_reference_to";    case MOD_const:		return "MOD_const";    case MOD_volatile:		return "MOD_volatile";    default:			return "MOD_<unknown>";    }}static char *dwarf_fmt_byte_name (fmt)     register unsigned fmt;{  switch (fmt)    {    case FMT_FT_C_C:	return "FMT_FT_C_C";    case FMT_FT_C_X:	return "FMT_FT_C_X";    case FMT_FT_X_C:	return "FMT_FT_X_C";    case FMT_FT_X_X:	return "FMT_FT_X_X";    case FMT_UT_C_C:	return "FMT_UT_C_C";    case FMT_UT_C_X:	return "FMT_UT_C_X";    case FMT_UT_X_C:	return "FMT_UT_X_C";    case FMT_UT_X_X:	return "FMT_UT_X_X";    case FMT_ET:	return "FMT_ET";    default:		return "FMT_<unknown>";    }}static char *dwarf_fund_type_name (ft)     register unsigned ft;{  switch (ft)    {    case FT_char:		return "FT_char";    case FT_signed_char:	return "FT_signed_char";    case FT_unsigned_char:	return "FT_unsigned_char";    case FT_short:		return "FT_short";    case FT_signed_short:	return "FT_signed_short";    case FT_unsigned_short:	return "FT_unsigned_short";    case FT_integer:		return "FT_integer";    case FT_signed_integer:	return "FT_signed_integer";    case FT_unsigned_integer:	return "FT_unsigned_integer";    case FT_long:		return "FT_long";    case FT_signed_long:	return "FT_signed_long";    case FT_unsigned_long:	return "FT_unsigned_long";    case FT_pointer:		return "FT_pointer";    case FT_float:		return "FT_float";    case FT_dbl_prec_float:	return "FT_dbl_prec_float";    case FT_ext_prec_float:	return "FT_ext_prec_float";    case FT_complex:		return "FT_complex";    case FT_dbl_prec_complex:	return "FT_dbl_prec_complex";    case FT_void:		return "FT_void";    case FT_boolean:		return "FT_boolean";    case FT_ext_prec_complex:	return "FT_ext_prec_complex";    case FT_label:		return "FT_label";    /* GNU extensions.  */    case FT_long_long:		return "FT_long_long";    case FT_signed_long_long:	return "FT_signed_long_long";    case FT_unsigned_long_long: return "FT_unsigned_long_long";    case FT_int8:		return "FT_int8";    case FT_signed_int8:	return "FT_signed_int8";    case FT_unsigned_int8:	return "FT_unsigned_int8";    case FT_int16:		return "FT_int16";    case FT_signed_int16:	return "FT_signed_int16";    case FT_unsigned_int16:	return "FT_unsigned_int16";    case FT_int32:		return "FT_int32";    case FT_signed_int32:	return "FT_signed_int32";    case FT_unsigned_int32:	return "FT_unsigned_int32";    case FT_int64:		return "FT_int64";    case FT_signed_int64:	return "FT_signed_int64";    case FT_unsigned_int64:	return "FT_signed_int64";    case FT_real32:		return "FT_real32";    case FT_real64:		return "FT_real64";    case FT_real96:		return "FT_real96";    case FT_real128:		return "FT_real128";    default:			return "FT_<unknown>";    }}/* Determine the "ultimate origin" of a decl.  The decl may be an   inlined instance of an inlined instance of a decl which is local   to an inline function, so we have to trace all of the way back   through the origin chain to find out what sort of node actually   served as the original seed for the given block.  */static treedecl_ultimate_origin (decl)     register tree decl;{  register tree immediate_origin = DECL_ABSTRACT_ORIGIN (decl);  if (immediate_origin == NULL)    return NULL;  else    {      register tree ret_val;      register tree lookahead = immediate_origin;      do	{	  ret_val = lookahead;	  lookahead = DECL_ABSTRACT_ORIGIN (ret_val);	}      while (lookahead != NULL && lookahead != ret_val);      return ret_val;    }}/* Determine the "ultimate origin" of a block.  The block may be an   inlined instance of an inlined instance of a block which is local   to an inline function, so we have to trace all of the way back   through the origin chain to find out what sort of node actually   served as the original seed for the given block.  */static treeblock_ultimate_origin (block)     register tree block;{  register tree immediate_origin = BLOCK_ABSTRACT_ORIGIN (block);  if (immediate_origin == NULL)    return NULL;  else    {      register tree ret_val;      register tree lookahead = immediate_origin;      do	{	  ret_val = lookahead;	  lookahead = (TREE_CODE (ret_val) == BLOCK)		       ? BLOCK_ABSTRACT_ORIGIN (ret_val)		       : NULL;	}      while (lookahead != NULL && lookahead != ret_val);      return ret_val;    }}static voidoutput_unsigned_leb128 (value)     register unsigned long value;{  register unsigned long orig_value = value;  do    {      register unsigned byte = (value & 0x7f);      value >>= 7;      if (value != 0)	/* more bytes to follow */	byte |= 0x80;      fprintf (asm_out_file, "\t%s\t0x%x", ASM_BYTE_OP, (unsigned) byte);      if (flag_verbose_asm && value == 0)	fprintf (asm_out_file, "\t%s ULEB128 number - value = %u",		 ASM_COMMENT_START, orig_value);      fputc ('\n', asm_out_file);    }  while (value != 0);}static voidoutput_signed_leb128 (value)     register long value;{  register long orig_value = value;  register int negative = (value < 0);  register int more;  do    {      register unsigned byte = (value & 0x7f);      value >>= 7;      if (negative)	value |= 0xfe000000;  /* manually sign extend */      if (((value == 0) && ((byte & 0x40) == 0))          || ((value == -1) && ((byte & 0x40) == 1)))	more = 0;      else	{	  byte |= 0x80;	  more = 1;	}      fprintf (asm_out_file, "\t%s\t0x%x", ASM_BYTE_OP, (unsigned) byte);      if (flag_verbose_asm && more == 0)	fprintf (asm_out_file, "\t%s SLEB128 number - value = %d",		 ASM_COMMENT_START, orig_value);      fputc ('\n', asm_out_file);    }  while (more);}/**************** utility functions for attribute functions ******************//* Given a pointer to a BLOCK node return non-zero if (and only if) the   node in question represents the outermost pair of curly braces (i.e.   the "body block") of a function or method.   For any BLOCK node representing a "body block" of a function or method,   the BLOCK_SUPERCONTEXT of the node will point to another BLOCK node   which represents the outermost (function) scope for the function or   method (i.e. the one which includes the formal parameters).  The   BLOCK_SUPERCONTEXT of *that* node in turn will point to the relevant   FUNCTION_DECL node.*/inline intis_body_block (stmt)     register tree stmt;{  if (TREE_CODE (stmt) == BLOCK)    {      register tree parent = BLOCK_SUPERCONTEXT (stmt);      if (TREE_CODE (parent) == BLOCK)	{	  register tree grandparent = BLOCK_SUPERCONTEXT (parent);	  if (TREE_CODE (grandparent) == FUNCTION_DECL)	    return 1;	}    }  return 0;}/* Given a pointer to a tree node for some type, return a Dwarf fundamental   type code for the given type.   This routine must only be called for GCC type nodes that correspond to   Dwarf fundamental types.   The current Dwarf draft specification calls for Dwarf fundamental types   to accurately reflect the fact that a given type was either a "plain"   integral type or an explicitly "signed" integral type.  Unfortunately,   we can't always do this, because GCC may already have thrown away the   information about the precise way in which the type was originally   specified, as in:	typedef signed int my_type;	struct s { my_type f; };   Since we may be stuck here without enought information to do exactly   what is called for in the Dwarf draft specification, we do the best   that we can under the circumstances and always use the "plain" integral   fundamental type codes for int, short, and long types.  That's probably   good enough.  The additional accuracy called for in the current DWARF   draft specification is probably never even useful in practice.  */static intfundamental_type_code (type)     register tree type;{  if (TREE_CODE (type) == ERROR_MARK)    return 0;  switch (TREE_CODE (type))    {      case ERROR_MARK:	return FT_void;      case VOID_TYPE:

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -