summaryrefslogtreecommitdiffstats
path: root/qt-ui/tagwidget.cpp
diff options
context:
space:
mode:
authorGravatar Linus Torvalds <torvalds@linux-foundation.org>2013-09-25 20:42:19 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-01-19 13:36:55 -0800
commit1891cf1881df2e96f1b0d4ccfe9328b890ae5946 (patch)
treec093bc86b8ffbde7e342640327474accbfa3b931 /qt-ui/tagwidget.cpp
parent3bbc4ecd0bce0995d0d616b068a9e3adc21b3da3 (diff)
downloadsubsurface-1891cf1881df2e96f1b0d4ccfe9328b890ae5946.tar.gz
Stop doing the (very expensive) pow() calculation pointlessly
This re-organizes the saturation calculations to be in my opinion clearer: we used to have the "one second" case completely separate from the "generic interval" case, and this undoes that. It *does* keep the special static cache for the one-second buehlmann factors, and expands that with a *dynamic* cache for each tissue index that contains the previous value of the buehlmann factor for a particular duration. The point is, usually we end up using some fixed duration, so the cache hit ratio is quite high. And doing a memory load from a cache is *much* faster than calculating exponentials. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/tagwidget.cpp')
0 files changed, 0 insertions, 0 deletions