New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Platform probing can be replaced with dmd -Xi=compilerInfo -Xf=-
for newer compilers
#1317
Comments
It took ~5ms last time I optimized it, hardly worth caching. Of course in the mean-time it was changed to import phobos again. |
But isn't this probing done on every DUB invocation? |
|
FWIW dmd now supports |
dmd -Xi=compilerInfo -Xf=-
for newer compilers
@FeepingCreature note that the officially released dub binary still isn't build with LDC. You might want to build it with LDC locally for a huge speedup for "free" |
Example: https://run.dlang.io/is/DiSyCl |
Good idea, thank you! |
Can the probe result be stored in a cache file? On linux calling another executable is cheap but on windows with a OnAccess virus scanner this makes the |
I don't see any reason why it couldn't. I guess even just the timestamp and size of the compiler binary should be good enough for most (all?) probe caching purposes. |
Flow:
dub/source/dub/commandline.d
Lines 1012 to 1032 in cea2f15
dub/source/dub/commandline.d
Lines 618 to 622 in cea2f15
dub/source/dub/compilers/dmd.d
Lines 56 to 68 in cea2f15
dub/source/dub/compilers/compiler.d
Lines 119 to 124 in cea2f15
dub/source/dub/compilers/utils.d
Lines 245 to 252 in cea2f15
Probably it could be something simple as the timestamp of the compiler binary.
How about
~/.dub/compilers/<dmd|ldc|gdc>_timestamp
?Related PRs:
-probe
directly in the compiler)The text was updated successfully, but these errors were encountered: