[omniORB] optimization and POA

Stefan Seefeld seefelds@MAGELLAN.UMontreal.CA
Fri, 12 May 2000 10:50:56 -0400


I'm thinking about possible optimizations we should apply
when using the POA in the context of the berlin project.
While we are still using the BOA, we plan to do the transition
this summer and I have a couple of concerns/ideas about
what could be done to keep things eficient.

First of all I was (and still am) quite puzzled to learn
about the _is_equivalent function. What is it's use ? I
can't think of a context where it is useful given that
I can't rely on a returned false value.
We'd like to use a lot of caching, so I'd like to have
a reliable method to identify objects to look up the
local cached value. How can this be done ? We could try to come
up with a 'unique ID' but I think there are better alternatives.
The context is this:

We have a scene graph of 'Graphic' nodes. This scene graph
is traversed with a DrawTraversal (and an attached DrawingKit
implementing a rendering strategy) everytime an intersecting
region has been damaged and needs to be repaired. The traversed
Graphic can then issue all the necessary drawing commands on the
DrawingKit. This involves a lot of paths, but also some rasters.
If the same DrawingKit is used frequently, it makes sense to
let it cache the objects so it doesn't need to recompute the
paths and rasters each time. This compares somewhat to openGL
display lists.
Following a discussion in comp.object.corba, I get the impression
that it would be possible to construct the IOR in a clever way,
i.e. to integrate some tags into it, which then make it possible to
optimize such a caching strategy. Is this possible ?

The second idea is about the POA's behavior wrt. method invocation.
Take the {Draw, Pick}Traversal objects I was speaking about. They are 
- from the point of view of the scene graph it traverses - persistent, 
i.e. if the Graphic objects are not allowed to keep references to it 
outside a traversal of the scene graph, their life time extends over 
the time an actual traversal takes, there is no danger that in the middle
of a traversal the DrawTraversal object suddenly disappears. This means 
it is not necessary to test for the Traversal's validity on each call. 

As Doug Schmidt proposes in a paper dediciated on POA optimization, 
it's sometimes possible to use an object adapter which bypasses half 
of the tests. If I know what I'm doing, i.e. I know the precise semantics 
of the object interactions, this might be a way to speed a traversal up
significantly.
Would it be possible to have special POAs supporting such 'direct'
calls for a specific range of objects which are 'well behaved' in
this respect ?

Thanks,	Stefan

PS: we use traversals not only for redrawing but also for picking,
    which is used on *every* positional event to find the target
    graphic the event should be routed to. Thus, such traversals
    are happening a lot and are quite time critical, at least very
    resource consuming.
_______________________________________________________              
              
Stefan Seefeld
Departement de Physique
Universite de Montreal
email: seefelds@magellan.umontreal.ca

_______________________________________________________

      ...ich hab' noch einen Koffer in Berlin...