forked from duckdb/duckdb
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request duckdb#9967 from taniabogatsch/block-size
[Block Size] CI test for 16KB block size and related code changes
- Loading branch information
Showing
96 changed files
with
1,306 additions
and
603 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,5 @@ | ||
import sys | ||
import subprocess | ||
import re | ||
import os | ||
import time | ||
|
||
import argparse | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
import os | ||
import re | ||
from python_helpers import open_utf8 | ||
|
||
|
||
def execute_system_command(cmd): | ||
print(cmd) | ||
retcode = os.system(cmd) | ||
print(retcode) | ||
if retcode != 0: | ||
raise Exception | ||
|
||
|
||
def replace_in_file(fname, regex, replace): | ||
with open_utf8(fname, 'r') as f: | ||
contents = f.read() | ||
contents = re.sub(regex, replace, contents) | ||
with open_utf8(fname, 'w+') as f: | ||
f.write(contents) | ||
|
||
|
||
current_dir = os.getcwd() | ||
build_dir = os.path.join(os.getcwd(), 'build', 'release') | ||
|
||
# run the fast tests and all storage-related tests | ||
# with a block size of 16KB and a standard vector size | ||
block_size = 16384 | ||
print("TESTING BLOCK_ALLOC_SIZE=%d" % (block_size,)) | ||
print("TESTING STANDARD_VECTOR_SIZE") | ||
|
||
replace_in_file( | ||
'src/include/duckdb/storage/storage_info.hpp', | ||
r'constexpr static idx_t BLOCK_ALLOC_SIZE = \w+', | ||
'constexpr static idx_t BLOCK_ALLOC_SIZE = %d' % (block_size,), | ||
) | ||
|
||
execute_system_command('rm -rf build') | ||
execute_system_command('make relassert') | ||
execute_system_command('build/relassert/test/unittest') | ||
execute_system_command('build/relassert/test/unittest "test/sql/storage/*"') | ||
|
||
# run the fast tests and all storage-related tests | ||
# with a block size of 16KB and a vector size of 512 | ||
vector_size = 512 | ||
print("TESTING BLOCK_ALLOC_SIZE=%d" % (block_size,)) | ||
print("TESTING STANDARD_VECTOR_SIZE=%d" % (vector_size,)) | ||
|
||
replace_in_file( | ||
'src/include/duckdb/common/vector_size.hpp', | ||
r'#define STANDARD_VECTOR_SIZE \w+', | ||
'#define STANDARD_VECTOR_SIZE %d' % (vector_size,), | ||
) | ||
|
||
execute_system_command('rm -rf build') | ||
execute_system_command('make relassert') | ||
execute_system_command('build/relassert/test/unittest') | ||
execute_system_command('build/relassert/test/unittest "test/sql/storage/*"') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.