Rev 5217 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 5217 | Rev 6324 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | /* stabs.c -- Parse stabs debugging information |
1 | /* stabs.c -- Parse stabs debugging information |
2 | Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
- | |
3 | 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. |
2 | Copyright (C) 1995-2015 Free Software Foundation, Inc. |
4 | Written by Ian Lance Taylor |
3 | Written by Ian Lance Taylor |
Line 5... | Line 4... | ||
5 | 4 | ||
Line 6... | Line 5... | ||
6 | This file is part of GNU Binutils. |
5 | This file is part of GNU Binutils. |
Line 835... | Line 834... | ||
835 | 834 | ||
Line 836... | Line 835... | ||
836 | break; |
835 | break; |
837 | 836 | ||
838 | case 'G': |
- | |
839 | { |
- | |
840 | char leading; |
837 | case 'G': |
Line 841... | Line 838... | ||
841 | long c; |
838 | { |
842 | asymbol **ps; |
839 | asymbol **ps; |
843 | 840 | ||
844 | /* A global symbol. The value must be extracted from the |
841 | /* A global symbol. The value must be extracted from the |
845 | symbol table. */ |
842 | symbol table. */ |
846 | dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p, |
843 | dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p, |
- | 844 | (debug_type **) NULL); |
|
- | 845 | if (dtype == DEBUG_TYPE_NULL) |
|
- | 846 | return FALSE; |
|
- | 847 | if (name != NULL) |
|
- | 848 | { |
|
847 | (debug_type **) NULL); |
849 | char leading; |
848 | if (dtype == DEBUG_TYPE_NULL) |
850 | long c; |
849 | return FALSE; |
851 | |
850 | leading = bfd_get_symbol_leading_char (info->abfd); |
852 | leading = bfd_get_symbol_leading_char (info->abfd); |
Line 856... | Line 858... | ||
856 | if (leading != '\0' && *n == leading) |
858 | if (leading != '\0' && *n == leading) |
857 | ++n; |
859 | ++n; |
858 | if (*n == *name && strcmp (n, name) == 0) |
860 | if (*n == *name && strcmp (n, name) == 0) |
859 | break; |
861 | break; |
860 | } |
862 | } |
- | 863 | ||
861 | if (c > 0) |
864 | if (c > 0) |
862 | value = bfd_asymbol_value (*ps); |
865 | value = bfd_asymbol_value (*ps); |
- | 866 | } |
|
- | 867 | ||
863 | if (! stab_record_variable (dhandle, info, name, dtype, DEBUG_GLOBAL, |
868 | if (! stab_record_variable (dhandle, info, name, dtype, DEBUG_GLOBAL, |
864 | value)) |
869 | value)) |
865 | return FALSE; |
870 | return FALSE; |
866 | } |
871 | } |
867 | break; |
872 | break; |
Line 1767... | Line 1772... | ||
1767 | else if (n3 == 0xffff) |
1772 | else if (n3 == 0xffff) |
1768 | return debug_make_int_type (dhandle, 2, TRUE); |
1773 | return debug_make_int_type (dhandle, 2, TRUE); |
1769 | else if (n3 == (bfd_signed_vma) 0xffffffff) |
1774 | else if (n3 == (bfd_signed_vma) 0xffffffff) |
1770 | return debug_make_int_type (dhandle, 4, TRUE); |
1775 | return debug_make_int_type (dhandle, 4, TRUE); |
1771 | #ifdef BFD64 |
1776 | #ifdef BFD64 |
1772 | else if (n3 == ((((bfd_signed_vma) 0xffffffff) << 32) | 0xffffffff)) |
1777 | else if (n3 == (bfd_signed_vma) 0xffffffffffffffffLL) |
1773 | return debug_make_int_type (dhandle, 8, TRUE); |
1778 | return debug_make_int_type (dhandle, 8, TRUE); |
1774 | #endif |
1779 | #endif |
1775 | } |
1780 | } |
1776 | else if (n3 == 0 |
1781 | else if (n3 == 0 |
1777 | && n2 < 0 |
1782 | && n2 < 0 |