Ashwani Raina has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/24412 )

Change subject: KUDU-3429 Add extensive test for delta generation (3/n)
......................................................................


Patch Set 4:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/24412/4/src/kudu/tablet/compaction-highmem-test.cc
File src/kudu/tablet/compaction-highmem-test.cc:

http://gerrit.cloudera.org:8080/#/c/24412/4/src/kudu/tablet/compaction-highmem-test.cc@326
PS4, Line 326:     kLargePayload[i] = static_cast<char>((i * 193U + 37U) % 
251U);
> +1 for using STL-based random generators if it works here as expected
The reason for using periodic variant is to have periodic repetition of 
251-byte blocks in a 64K buffer. However, std::mt19937 yields totally 
non-periodic output that is not compressible. The goal here is to achieve 
'compressible-on-disk & expands-in-memory' kind of deal as well as little 
randomness to have default compaction memory budget able to accommodate the 
undo deltas.

If std::mt199337 is used, on-disk undo size has to be very high if we want to 
hit a 'good' peak_memory_usage because compression would be ineffective for it 
and the undo data size on-disk is going to be near close to the peak memory use 
by rowset compaction. Also, to make on-disk size high, default compaction 
budget configuration also needs to be changed in the test.

If a constant pattern (all-same byte) is used, although it has smaller on-disk 
footprint there would be increased CPU time which means increased test run time.

Partial pseudo-random with periodic repetition is a middle ground with best of 
both the worlds.

I noticed how a certain level of inaccuracy in the comments above could cause 
confusion. Made changes there to keep it simple and clear.



--
To view, visit http://gerrit.cloudera.org:8080/24412
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I8c337dba87a9d1cf549f9b53813da8d50e86b6b4
Gerrit-Change-Number: 24412
Gerrit-PatchSet: 4
Gerrit-Owner: Ashwani Raina <[email protected]>
Gerrit-Reviewer: Abhishek Chennaka <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Ashwani Raina <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Marton Greber <[email protected]>
Gerrit-Reviewer: Zoltan Martonka <[email protected]>
Gerrit-Comment-Date: Tue, 04 Aug 2026 13:51:45 +0000
Gerrit-HasComments: Yes

Reply via email to