Skip to content
  • Akarsh Simha's avatar
    Profiling Code: Determine time spent in EquatorialToHorizontal · 0860ef61
    Akarsh Simha authored
    While this may as well be done in callgrind, this is simple and works,
    and is less of a hassle in running KStars (doesn't slow KStars down as
    much as callgrind would).
    
    Under some conditions, KStars output the following:
    
    [24 0:15:36 D] KStars::~KStars (182) - Spent  7.86563  seconds in
    13906422  calls to SkyPoint::EquatorialToHorizontal, for an average of
     0.000565611  ms per call
    
    The results seem to be somewhat consistent across runs:
    
    Spent  2.19932  seconds in  3988240  calls to SkyPoint::EquatorialToHorizontal, for an average of  0.000551452  ms per call
    
    Spent  2.02403  seconds in  3464395  calls to SkyPoint::EquatorialToHorizontal, for an average of  0.000584239  ms per call
    
    Spent  0.261255  seconds in  332259  calls to SkyPoint::EquatorialToHorizontal, for an average of  0.000786299  ms per call
    
    Spent  0.464544  seconds in  530146  calls to SkyPoint::EquatorialToHorizontal, for an average of  0.000876257  ms per call
    
    The variations seem to be tied to the number of stars in the
    field. The first three results are from the USNO NOMAD artifact patch
    in the Sagittarius milky way region. The latter are centered around
    regions of lower star density. The variation might be probably related
    to cache performance?
    0860ef61