@@ -959,7 +959,7 @@ def output_parser(output):
959
959
960
960
def lua (self , benchmark , expected , output_parser = None , args_processor = None ):
961
961
self .emcc_args .remove ('-Werror' )
962
- shutil .copyfile (test_file ('third_party' , ' lua' , benchmark + ' .lua' ), benchmark + '.lua' )
962
+ shutil .copyfile (test_file (f 'third_party/ lua/ { benchmark } .lua' ), benchmark + '.lua' )
963
963
964
964
def lib_builder (name , native , env_init ):
965
965
ret = self .get_library (os .path .join ('third_party' , 'lua_native' if native else 'lua' ), [os .path .join ('src' , 'lua.o' ), os .path .join ('src' , 'liblua.a' )], make = ['make' , 'generic' ], configure = None , native = native , cache_name_extra = name , env_init = env_init )
@@ -987,16 +987,16 @@ def test_zzz_lua_binarytrees(self):
987
987
988
988
def test_zzz_zlib (self ):
989
989
self .emcc_args .remove ('-Werror' )
990
- src = read_file (test_file ('benchmark' , ' test_zlib_benchmark.c' ))
990
+ src = read_file (test_file ('benchmark/ test_zlib_benchmark.c' ))
991
991
992
992
def lib_builder (name , native , env_init ):
993
993
return self .get_library (os .path .join ('third_party' , 'zlib' ), os .path .join ('libz.a' ), make_args = ['libz.a' ], native = native , cache_name_extra = name , env_init = env_init )
994
994
995
995
self .do_benchmark ('zlib' , src , 'ok.' ,
996
- force_c = True , shared_args = ['-I' + test_file ('third_party' , ' zlib' )], lib_builder = lib_builder )
996
+ force_c = True , shared_args = ['-I' + test_file ('third_party/ zlib' )], lib_builder = lib_builder )
997
997
998
998
def test_zzz_coremark (self ):
999
- src = read_file (test_file ('third_party' , ' coremark' , ' core_main.c' ))
999
+ src = read_file (test_file ('third_party/ coremark/ core_main.c' ))
1000
1000
1001
1001
def lib_builder (name , native , env_init ):
1002
1002
return self .get_library ('third_party/coremark' , [os .path .join ('coremark.a' )], configure = None , native = native , cache_name_extra = name , env_init = env_init )
@@ -1005,15 +1005,15 @@ def output_parser(output):
1005
1005
iters_sec = re .search (r'Iterations/Sec : ([\d\.]+)' , output ).group (1 )
1006
1006
return 100000.0 / float (iters_sec )
1007
1007
1008
- self .do_benchmark ('coremark' , src , 'Correct operation validated.' , shared_args = ['-I' + test_file ('third_party' , ' coremark' )], lib_builder = lib_builder , output_parser = output_parser , force_c = True )
1008
+ self .do_benchmark ('coremark' , src , 'Correct operation validated.' , shared_args = ['-I' + test_file ('third_party/ coremark' )], lib_builder = lib_builder , output_parser = output_parser , force_c = True )
1009
1009
1010
1010
def test_zzz_box2d (self ):
1011
- src = read_file (test_file ('benchmark' , ' test_box2d_benchmark.cpp' ))
1011
+ src = read_file (test_file ('benchmark/ test_box2d_benchmark.cpp' ))
1012
1012
1013
1013
def lib_builder (name , native , env_init ):
1014
1014
return self .get_library (os .path .join ('third_party' , 'box2d' ), ['box2d.a' ], configure = None , native = native , cache_name_extra = name , env_init = env_init )
1015
1015
1016
- self .do_benchmark ('box2d' , src , 'frame averages' , shared_args = ['-I' + test_file ('third_party' , ' box2d' )], lib_builder = lib_builder )
1016
+ self .do_benchmark ('box2d' , src , 'frame averages' , shared_args = ['-I' + test_file ('third_party/ box2d' )], lib_builder = lib_builder )
1017
1017
1018
1018
def test_zzz_bullet (self ):
1019
1019
self .emcc_args .remove ('-Werror' )
@@ -1038,16 +1038,16 @@ def lib_builder(name, native, env_init):
1038
1038
lib_builder = lib_builder )
1039
1039
1040
1040
def test_zzz_lzma (self ):
1041
- src = read_file (test_file ('benchmark' , ' test_lzma_benchmark.c' ))
1041
+ src = read_file (test_file ('benchmark/ test_lzma_benchmark.c' ))
1042
1042
1043
1043
def lib_builder (name , native , env_init ):
1044
1044
return self .get_library (os .path .join ('third_party' , 'lzma' ), [os .path .join ('lzma.a' )], configure = None , native = native , cache_name_extra = name , env_init = env_init )
1045
1045
1046
- self .do_benchmark ('lzma' , src , 'ok.' , shared_args = ['-I' + test_file ('third_party' , ' lzma' )], lib_builder = lib_builder )
1046
+ self .do_benchmark ('lzma' , src , 'ok.' , shared_args = ['-I' + test_file ('third_party/ lzma' )], lib_builder = lib_builder )
1047
1047
1048
1048
def test_zzz_sqlite (self ):
1049
1049
src = read_file (test_file ('third_party/sqlite/sqlite3.c' )) + read_file (test_file ('sqlite/speedtest1.c' ))
1050
- self .do_benchmark ('sqlite' , src , 'TOTAL...' , native_args = ['-ldl' , '-pthread' ], shared_args = ['-I' + test_file ('third_party' , ' sqlite' )],
1050
+ self .do_benchmark ('sqlite' , src , 'TOTAL...' , native_args = ['-ldl' , '-pthread' ], shared_args = ['-I' + test_file ('third_part/ sqlite' )],
1051
1051
emcc_args = ['-sFILESYSTEM' , '-sMINIMAL_RUNTIME=0' ], # not minimal because of files
1052
1052
force_c = True )
1053
1053
@@ -1096,8 +1096,8 @@ def lib_builder(name, native, env_init):
1096
1096
1097
1097
# TODO: Fix poppler native build and remove skip_native=True
1098
1098
self .do_benchmark ('poppler' , '' , 'hashed printout' ,
1099
- shared_args = ['-I' + test_file ('poppler' , ' include' ), '-I' + test_file ('freetype' , ' include' )],
1099
+ shared_args = ['-I' + test_file ('poppler/ include' ), '-I' + test_file ('freetype/ include' )],
1100
1100
emcc_args = ['-sFILESYSTEM' , '--pre-js' , 'pre.js' , '--embed-file' ,
1101
- test_file ('poppler' , ' emscripten_html5.pdf' ) + '@input.pdf' , '-sERROR_ON_UNDEFINED_SYMBOLS=0' ,
1101
+ test_file ('poppler/ emscripten_html5.pdf' ) + '@input.pdf' , '-sERROR_ON_UNDEFINED_SYMBOLS=0' ,
1102
1102
'-sMINIMAL_RUNTIME=0' ], # not minimal because of files
1103
1103
lib_builder = lib_builder , skip_native = True )
0 commit comments