diff options
author | Nikita Malyavin <nikitamalyavin@gmail.com> | 2022-06-24 01:45:44 +0300 |
---|---|---|
committer | Nikita Malyavin <nikitamalyavin@gmail.com> | 2022-06-24 01:45:44 +0300 |
commit | 074c211faf9cd5ce8d0e6104ef5685e8f4c9d8f3 (patch) | |
tree | f1342843be757793c9e8a99a5dc9e340c433ba8e /mysql-test/main | |
parent | 69af61a4ee04fa22efb5a35b2e91fb1a809170de (diff) | |
download | mariadb-git-kakurin_sampling.tar.gz |
sampling analysiskakurin_sampling
file=open(...)
for l in file:
if l.startswith('SAMPLE') and not l.startswith('SAMPLE root'):
print(l)
n = dict((p.split('=')
for p in l.replace('SAMPLE ', '').replace(' REJECT', '').split()
))
if 'REJECT' in l:
n['rej']=True
nodes.append(n)
max(int(n['size']) for n in nodes)
max((float(n['p']), serialize(n)) for n in nodes)
max((float(n['size']), serialize(n)) for n in nodes if n['height'] == '0')
Diffstat (limited to 'mysql-test/main')
-rw-r--r-- | mysql-test/main/profile.opt | 2 | ||||
-rw-r--r-- | mysql-test/main/profile.test | 34 |
2 files changed, 2 insertions, 34 deletions
diff --git a/mysql-test/main/profile.opt b/mysql-test/main/profile.opt index da84f76d539..8fbae672382 100644 --- a/mysql-test/main/profile.opt +++ b/mysql-test/main/profile.opt @@ -1,2 +1,2 @@ ---innodb_buffer_pool_size=8M +--innodb_buffer_pool_size=1G diff --git a/mysql-test/main/profile.test b/mysql-test/main/profile.test index dcff6e480ae..b1c7bc21d9a 100644 --- a/mysql-test/main/profile.test +++ b/mysql-test/main/profile.test @@ -50,7 +50,7 @@ create or replace temporary table counters ( ) engine=myisam; ---let $i= 500 +--let $i= 5 --echo i=$i --let $method=bernoulli --let percent=1 @@ -67,36 +67,4 @@ create or replace temporary table counters ( --enable_result_log select pk_value div 10000, sum(counter) from counters group by pk_value div 10000; -create or replace temporary table counters ( - pk_value int, - counter int, - primary key (pk_value) -) engine=myisam; - - ---echo ================================================================== ---echo ================================================================== ---echo ================================================================== ---echo ================================================================== ---echo ================================================================== ---echo ================================================================== ---echo ================================================================== ---echo ================================================================== - ---let $i= 500 ---echo i=$i ---let $method=system ---let percent=1 ---echo method=$method $percent% ---while($i) - eval -INSERT INTO counters - SELECT _id, 0 FROM vehicle_reg tablesample $method($percent) -ON DUPLICATE KEY UPDATE counter = counter + 1 -; ---dec $i ---} ---enable_query_log ---enable_result_log -select pk_value div 10000, sum(counter) from counters group by pk_value div 10000; --} |