[Opensim-dev] Lockless Lists?

Frisby, Adam adam at deepthink.com.au
Mon Nov 24 18:02:16 UTC 2008


The login/logout issue occurs under Win32 as well, so I think threadpriority is out.

We're pretty sure there's some kind of blocking occurring - but not entirely sure why or how.

Btw, with these patches in - I haven't noticed any issues myself (did test before committing), however Nebadon has informed me there may be some issues on the plazas - but we're unable to isolate them being caused by this or not.

If anyone notices anything odd that's attributable to r7450, 7451, 7452 please let me know so we can get them sorted out.

Adam

> -----Original Message-----
> From: opensim-dev-bounces at lists.berlios.de [mailto:opensim-dev-
> bounces at lists.berlios.de] On Behalf Of Justin Clark-Casey
> Sent: Monday, 24 November 2008 8:02 AM
> To: opensim-dev at lists.berlios.de
> Subject: Re: [Opensim-dev] Lockless Lists?
>
> Frisby, Adam wrote:
> > I've managed to get the majority of my goals solved here without
> > removing the locks - but by making a new EntityManager to deal with
> > those locks.
> >
> >
> >
> > Code has been checked in tonight as it doesn't look like it should
> cause
> > any new issues. May improve performance during login/logout - but
> > ScenePresences (which I haven't touched yet) is probably the real
> > culprit there.
>
> To be honest, I suspect the real issue on login/logout performance is
> the fact that mono does not yet implement thread
> prioritization - you can see it but properties such as Thread.Priority
> are merely stubs.
>
> So when a login/logout comes along it's not currently possible to give
> existing clients or threads such as the scene
> update execution priority.  So I'm thinking that the significant cpu
> spike on login/logout slows the whole system down.
>
> I looked at login recently and I don't believe that the periods of lock
> holding are significant enough to be causing the
> delay.
>
> No actual proper performance analysis was carried out so I could be
> wrong.
>
> >
> >
> >
> > Adam
> >
> >
> >
> > *From:* opensim-dev-bounces at lists.berlios.de
> > [mailto:opensim-dev-bounces at lists.berlios.de] *On Behalf Of *Lc
> > *Sent:* Monday, 24 November 2008 2:39 AM
> > *To:* opensim-dev at lists.berlios.de
> > *Subject:* Re: [Opensim-dev] Lockless Lists?
> >
> >
> >
> > fine but could we tag a "stable" release before ?
> > SM
> >
> > On Mon, Nov 24, 2008 at 11:23 AM, Frisby, Adam <adam at deepthink.com.au
> > <mailto:adam at deepthink.com.au>> wrote:
> >
> > I've recently discovered (and perhaps I should have known this
> earlier)
> > it's possible to create a reasonably high performance lock-free
> > list/dictionary/stack/queue structure under C#.
> >
> >
> >
> > Julian Bucknall has posted the sourcecode to a bunch of these here:
> > http://www.boyet.com/articles/lockfreestack.html
> >
> >
> >
> > One of the big performance issues with OpenSim is our overreliance on
> > locking data structures, which can cause issues when those locks
> don't
> > release in a timely manner. If we switched to lockless structures -
> we
> > could effectively eliminate those issues. (and probably create new
> ones.)
> >
> >
> >
> > Does anyone have any opposition if we try to replace some of the core
> > structures with lock-free versions, and then removing the locks on
> them?
> > I'm thinking Scene.Entities, Scene.Presences would be two good
> targets
> > for the first lot, then maybe we can attack some deeper bits later.
> >
> >
> >
> > Adam
> >
> >
> > _______________________________________________
> > Opensim-dev mailing list
> > Opensim-dev at lists.berlios.de <mailto:Opensim-dev at lists.berlios.de>
> > https://lists.berlios.de/mailman/listinfo/opensim-dev
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> ---
> >
> > _______________________________________________
> > Opensim-dev mailing list
> > Opensim-dev at lists.berlios.de
> > https://lists.berlios.de/mailman/listinfo/opensim-dev
>
>
> --
> justincc
> Justin Clark-Casey
> http://justincc.wordpress.com
> _______________________________________________
> Opensim-dev mailing list
> Opensim-dev at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/opensim-dev



More information about the Opensim-dev mailing list