This is the mail archive of the mailing list for the Java project.

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

Re: ObjC configured --with-objc-gc needs external Boehm gc

Helge Hess wrote:
> "Boehm, Hans" wrote:
> > > > Does Objective C normally use the collector with thread support?
> > >
> > > I think that this is 50/50. The problem is that threading currently
> > > slows down the runtime to some degree and therefore is often
> > > turned off
> > > if threading is not required.
> > Aside from a tuning problem in current collector versions, it should
> > currently cost basically one test-and-set (probably 5-30 cycles depending on
> > the processor) on entry, and a store on exit of each malloc call.  The
> > uniprocessor cost with thread-local allocation (as in GC6.0) is probably
> > about the same, though it scales much better on multiprocessors.
> I think I wasn't clear. I was referring to the performance of libobjc,
> not of the gc. Libobjc gets slower if threading is enabled which is
> often the reason why people turn it off.

Can you say much slowdown is due to the use of thread primitives in libobjc vs.
how much is due to memory allocation?  Using boehm-gc might even be beneficial
to the threaded runtime... I've observed poor performance from the standard
(thread-safe) allocator on some systems, including glibc.

Jeff Sturm

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