Ethereal-cvs: [Ethereal-cvs] cvs commit: ethereal/epan to_str.c

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Ronnie Sahlberg <sahlberg@xxxxxxxxxxxxxxxxx>
Date: Mon, 17 Nov 2003 16:56:46 -0600 (CST)
sahlberg    2003/11/17 16:56:46 CST

  Modified files:
    epan                 to_str.c 
  Log:
  updates to ip_to_str[_buf]() to make them faster.
  
  This functin was in a recent profiling run the fifth most expensive function.
  It consumed ~3.5% of the total cpu in that run.
  
  Using a static table this function is now just over twice as fast as previously.
  
  My testrun calling it 10.000.000 times in a loop changed the execution time from ~17.3s ro ~8.2s
  
  If this test was representative for the speedup and if ~3.5 in the profile run
  was representative for normal cases this should make ethereal ~1.8% faster.
  Woohoo.
  (low hanging fruit)
  
  Revision  Changes    Path
  1.39      +80 -40    ethereal/epan/to_str.c