Re: BABL path vs. reference fish

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 00:51, Mon 14 Apr 08, Øyvind Kolås wrote:
> One issue in babl's current design is that other activity on the
> system at the same time as measuring is performed can skew results
> quite a lot for a given conversion, not sure if there is a good way to
> deal with this at runtime though.

Hi, 

  yes, the gettimeofday function is indeed not the best
  profiling method. I have put some though into this and came up
  with several alternatives how to tackle this problem.

  The first possibility is to replace gettimeofday by system
  function that accounts only for time of the given process,
  such as getrusage. Although the getrusage function provides
  way to measure process time in microseconds, the real
  resolution is far from 1 microsecond. Using getrusage
  would mean that the runtime profiling would have to take approx.
  100x longer than in the current state to get reasonable
  results for the fastest conversions. And that is far from
  ideal.

  The second possibility is to profile during the compilation, 
  which would allow for much longer and precise profiling.
  This would generate some profiling data in a form of a C
  file and would compile into babl in the second compile pass.
  This might work in a situation when the compiling
  machine is the target machine, however, the results can be
  of course skewed while this is not the case. Maybe the
  biggest drawback would be the fact that this contradicts the
  dynamic paradigm of the library.

  The third possibility is again to profile longer using
  getrusage or similar function, this time once per user.
  The profiling results would be output e.g. to
  ~/.babl/prof.data and would be reloaded next time. Once
  new .so with conversion would be found or new babl version
  installed, the profiling would be done again.

  So these are the alternatives I came up with. If you
  prefer one of these or have a better idea, I can
  investigate it further.

  Regards,
   Jan
_______________________________________________
Gegl-developer mailing list
Gegl-developer@xxxxxxxxxxxxxxxxxxxxxx
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gegl-developer


[Index of Archives]     [Yosemite News]     [Yosemite Photos]     [gtk]     [GIMP Users]     [KDE]     [Gimp's Home]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux