This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: sjlj exception and malloc



  In message <199810160336.UAA20601@monterey.sierravista.com>you write:
  > When using sjlj exceptions, malloc gets called very early in order to
  > allocate the static eh context.  This is a real problem for us because
  > we implement our own malloc in C++.  The result is infinite recursion.
  > 
  > Because there is only one of these static objects, it's straightforward
  > to statically allocate the object and then just do the initialization,
  > which breaks the loop.  I've observed no negative side effects other
  > than the 12 bytes of data space that aren't used when eh_context_static
  > isn't used.
I fixed this in a slightly different (cleaner & more efficient) manner.

Thanks for pointing out the problem.

jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]