On Sat, 2002-03-23 at 06:26, David Megginson wrote: > Tony Peden writes: > > > Also, I was able to better quantify the performance change due to > > incorporating the properties code. Prior to this, I had done speed > > comparisons with the profiling code compiled in, but now I'm not so sure > > that's fair. So: > > pre-props: 1.3 seconds average > > post-props: 1.4 seconds average > > or about an 8% loss in speed. > > I'm not surprised that you'd see a small slowdown with heavy property > use, but I'm surprised that you're seeing this in standalone JSBSim. > > I looked at the current JSBSim code, and there are scarcely any > property accesses at all: as far as I can tell, only > FGCoefficient::Value and FGCoefficient::TotalValue methods touch the > property tree at all in the main loop, though I can imagine that these > are relatively heavily used.
Very heavily used. I don't know the exact number, but the aero model of the c172 accesses the tree at least 60 times per frame. Jon and I have discussed ways to reduce this demand (its a design "feature" that pre-dates the property tree) and I think we could achieve 1/3 to 1/2 of that. > What property-related methods show up > near the top in the profiling? SGPropertyNode::getDoubleValue() This makes perfect sense, because it's called in place of FGState::GetParameter which used to be the big hitter. > > The other possibility is that the new multi-FDM stubs are slowing > things down, but that seems unlikely. > > > All the best, > > > David > > -- > David Megginson > [EMAIL PROTECTED] > > > _______________________________________________ > Flightgear-devel mailing list > [EMAIL PROTECTED] > http://mail.flightgear.org/mailman/listinfo/flightgear-devel > -- Tony Peden [EMAIL PROTECTED] We all know Linux is great ... it does infinite loops in 5 seconds. -- attributed to Linus Torvalds _______________________________________________ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
