Skip to content

ctxcode/linker-speed-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

c link speed: Many small o files vs. Few big o files

Simple test to see which is faster. I dont know if this test can be compared to real code

Results

Linker used: gcc

Linux:

1000 files, 10 functions -> 0.290s
100 files, 100 functions -> 0.077s
10 files, 1000 functions -> 0.063s
1 files, 10000 functions -> 0.058s

WSL:

1000 files, 10 functions -> 1.7s
100 files, 100 functions -> 0.2s
10 files, 1000 functions -> 0.1s
1 files, 10000 functions -> 0.1s

Usage

php gen.php {object count} {func count per file}
# php gen.php 10 100

Conclusion

many small files is slower than few large files

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages