public inbox for libffi-discuss@sourceware.org
 help / color / mirror / Atom feed
* OS X 10.6.6 ld: could not create compact unwind for _ffi_call_unix64: does not use RBP or RSP based frame
@ 2011-03-24  5:51 William Knop
  2011-03-30 17:48 ` Anthony Green
  0 siblings, 1 reply; 2+ messages in thread
From: William Knop @ 2011-03-24  5:51 UTC (permalink / raw)
  To: libffi-discuss

Hello all,

I'm working on squashing some bugs in ghc, the glasgow haskell
compiler, and I've run into a linker warning that is apparently new to
OS X 10.6's ld. Specifically, the new linker defaults to creating
compact unwinds, which is briefly described in `man unwinddump`:

"When a C++ (or x86_64 Objective-C) exception is thrown, the runtime
must unwind the stack looking for some function to catch the
exception.  Traditionally, the unwind information is stored in the
__TEXT/__eh_frame section of each executable as Dwarf CFI (call frame
information).  Beginning in Mac OS X 10.6, the unwind information is
also encoded in the __TEXT/__unwind_info section using a two-level
lookup table of compact unwind encodings."

Unfortunately, _ffi_call_unix64's cannot re represented in the compact
unwind format, resulting in the ld warning:

"could not create compact unwind for _ffi_call_unix64: does not use
RBP or RSP based frame"

Do you guys know if _ffi_call_unix64 (in darwin64.S) can be modified
to work with compact unwinds, and if so is it something that's planned
for a future release?

I have found a few relevant discussions:
http://groups.google.com/group/llvm-dev/browse_thread/thread/8baba4531a9feb07/139c9eba3525ebe
http://groups.google.com/group/darwin-dev/browse_thread/thread/962f74bde0efaae4/cfb63dfb3ac34ce1

Thanks much,
William Knop

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: OS X 10.6.6 ld: could not create compact unwind for _ffi_call_unix64: does not use RBP or RSP based frame
  2011-03-24  5:51 OS X 10.6.6 ld: could not create compact unwind for _ffi_call_unix64: does not use RBP or RSP based frame William Knop
@ 2011-03-30 17:48 ` Anthony Green
  0 siblings, 0 replies; 2+ messages in thread
From: Anthony Green @ 2011-03-30 17:48 UTC (permalink / raw)
  To: William Knop; +Cc: libffi-discuss

William Knop <william.knop.nospam@gmail.com> writes:

> Hello all,
>
> I'm working on squashing some bugs in ghc, the glasgow haskell
> compiler, and I've run into a linker warning that is apparently new to
> OS X 10.6's ld. Specifically, the new linker defaults to creating
> compact unwinds, which is briefly described in `man unwinddump`:
>
> "When a C++ (or x86_64 Objective-C) exception is thrown, the runtime
> must unwind the stack looking for some function to catch the
> exception.  Traditionally, the unwind information is stored in the
> __TEXT/__eh_frame section of each executable as Dwarf CFI (call frame
> information).  Beginning in Mac OS X 10.6, the unwind information is
> also encoded in the __TEXT/__unwind_info section using a two-level
> lookup table of compact unwind encodings."
>
> Unfortunately, _ffi_call_unix64's cannot re represented in the compact
> unwind format, resulting in the ld warning:
>
> "could not create compact unwind for _ffi_call_unix64: does not use
> RBP or RSP based frame"

Doesn't it say "also encoded in"..?  I guess it's required.


> Do you guys know if _ffi_call_unix64 (in darwin64.S) can be modified
> to work with compact unwinds, and if so is it something that's planned
> for a future release?
>
> I have found a few relevant discussions:
> http://groups.google.com/group/llvm-dev/browse_thread/thread/8baba4531a9feb07/139c9eba3525ebe
> http://groups.google.com/group/darwin-dev/browse_thread/thread/962f74bde0efaae4/cfb63dfb3ac34ce1

Thanks for these pointers.  I read the first thread and my summary is
that the EH unwind info format has changed in OS X 10.6 and GCC hasn't
caught up yet.

I'm not aware of any volunteers planning to update libffi to match this
change, but it sounds like it is required in order to support EH.
Volunteers welcome!

AG

>
> Thanks much,
> William Knop

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-03-30 17:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-03-24  5:51 OS X 10.6.6 ld: could not create compact unwind for _ffi_call_unix64: does not use RBP or RSP based frame William Knop
2011-03-30 17:48 ` Anthony Green

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).