[DTrace-devel] [oracle/dtrace-utils] 6b0385: Reduce memory consumption of tst.llquantstep.d

euloh noreply at github.com
Thu Jan 28 18:12:18 PST 2021


  Branch: refs/heads/dev
  Home:   https://github.com/oracle/dtrace-utils
  Commit: 6b0385570c79b1c2bcb41f6f0d8a6ee310f85688
      https://github.com/oracle/dtrace-utils/commit/6b0385570c79b1c2bcb41f6f0d8a6ee310f85688
  Author: Eugene Loh <eugene.loh at oracle.com>
  Date:   2021-01-28 (Thu, 28 Jan 2021)

  Changed paths:
    M test/unittest/aggs/tst.llquantstep.d
    M test/unittest/aggs/tst.llquantstep.r

  Log Message:
  -----------
  Reduce memory consumption of tst.llquantstep.d

For log-linear aggregation, the parameters are factor, lmag, hmag,
and steps.  For each log range -- from pow(factor,mag) to
pow(factor,mag+1) -- values are quantized into steps bins.
Thus, it is sufficient for steps to divide pow(factor,lmag) even
if it does not divide pow(factor,2).  Checking this is the aim of
this test.

The test clearly checks the case where lmag>2.  At a minimum, lmag=3.
The test uses steps=pow(factor,3).

The size of the aggregation is
    ((hmag - lmag + 1) * (steps - steps / factor) * 2 + 3) * sizeof(u64)
For the test's parameters, that comes out to about 57 Kbytes, which is
relatively large.  Since the test's footprint scales as pow(factor,3),
a reduction in factor can reduce the footprint considerably.

Adjust the test's parameters to reduce the map footprint while still
testing the same objectives.  A beneficial byproduct is that a
successful run will generate (~900 lines) less output in runtest.log.

Signed-off-by: Eugene Loh <eugene.loh at oracle.com>
Reviewed-by: Kris Van Hees <kris.van.hees at oracle.com>





More information about the DTrace-devel mailing list