▲ | CyberDildonics 3 days ago | ||||||||||||||||||||||
Have you actually tried? This is 287 KB of C. MSVC on computers from 15 years ago will compile C at about 60 MB/s. I'm skeptical this is actually a problem. SQLite is distributed as a single 6 MB .c file and compiles in ... 0.1 seconds. | |||||||||||||||||||||||
▲ | jstimpfle 3 days ago | parent [-] | ||||||||||||||||||||||
That may be true for extremely simple source code, but it's almost too good to be true. Your number sounded so impressive that I tried with gcc (12.2) on my Linux VM. With -O0, it takes around 27s, with -O2 it's 1m07s. With -E (only preprocess) we are at around 0.320s for the 260K lines of sqlite3.c. Which makes sense, 1M lines/s for the preprocessor and maybe also the AST should be doable (that may be where you got your 60MB/s number from). But compiling is something else. MSVC may be faster here or not, I haven't tested it. A more modern machine (mine is a i5-7600K from 2018) may be 2x or more faster, and running on multiple threads will speed up the build as well. | |||||||||||||||||||||||
|