diff options
author | Andrew Haley <aph@redhat.com> | 2002-11-25 17:20:10 +0000 |
---|---|---|
committer | Andrew Haley <aph@gcc.gnu.org> | 2002-11-25 17:20:10 +0000 |
commit | 5dafd2823100abb3f8b3b43dd4e0af5c81951539 (patch) | |
tree | 82b082e6055815d9ac117b67bac10e9a91984907 /gcc/unwind-dw2.c | |
parent | b4bbc8b7d36cfb5eafb02814087504e074a00be5 (diff) | |
download | gcc-5dafd2823100abb3f8b3b43dd4e0af5c81951539.zip gcc-5dafd2823100abb3f8b3b43dd4e0af5c81951539.tar.gz gcc-5dafd2823100abb3f8b3b43dd4e0af5c81951539.tar.bz2 |
libgcc-std.ver (_Unwind_Find_Enclosing_Function): Add.
2002-11-25 Andrew Haley <aph@redhat.com>
* libgcc-std.ver (_Unwind_Find_Enclosing_Function): Add.
* config/ia64/unwind-ia64.c (_Unwind_Find_Enclosing_Function): New.
* unwind-sjlj.c (_Unwind_Find_Enclosing_Function): Likewise.
* unwind-dw2.c (_Unwind_Find_Enclosing_Function): Likewise.
From-SVN: r59460
Diffstat (limited to 'gcc/unwind-dw2.c')
-rw-r--r-- | gcc/unwind-dw2.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/unwind-dw2.c b/gcc/unwind-dw2.c index fd7db6a..41db092 100644 --- a/gcc/unwind-dw2.c +++ b/gcc/unwind-dw2.c @@ -202,6 +202,17 @@ _Unwind_GetRegionStart (struct _Unwind_Context *context) return (_Unwind_Ptr) context->bases.func; } +void * +_Unwind_Find_Enclosing_Function (void *pc) +{ + struct dwarf_eh_bases bases; + struct dwarf_fde *fde = _Unwind_Find_FDE (pc-1, &bases); + if (fde) + return bases.func; + else + return NULL; +} + #ifndef __ia64__ _Unwind_Ptr _Unwind_GetDataRelBase (struct _Unwind_Context *context) |