Slow start up time of runtime

2018-03-20 Thread Dennis via Digitalmars-d-learn
Simply running a "hello world.exe" takes, on my pc: 1.12s When compiled with dmd 0.62s When compiled with ldc 0.05s When compiled with dmc (C program) or dmd/ldc as a -betterC program I suppose initializing the runtime takes a lot of time. When making a simple command line utility, half a sec

Re: Slow start up time of runtime

2018-03-20 Thread bauss via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 09:44:41 UTC, Dennis wrote: Simply running a "hello world.exe" takes, on my pc: 1.12s When compiled with dmd 0.62s When compiled with ldc 0.05s When compiled with dmc (C program) or dmd/ldc as a -betterC program I suppose initializing the runtime takes a lot of ti

Re: Slow start up time of runtime

2018-03-20 Thread Dennis via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 09:51:09 UTC, bauss wrote: Besides if it was and it took 1 second to startup, then it wouldn't matter in practice with an actual application. This is not concerning for large applications indeed. But say, I want to implement my own `dir` (= `ls` on Unix) in D. Woul

Re: Slow start up time of runtime

2018-03-20 Thread Dennis via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 10:20:55 UTC, Dennis wrote: On Tuesday, 20 March 2018 at 09:51:09 UTC, bauss wrote: Besides if it was and it took 1 second to startup, then it wouldn't matter in practice with an actual application. This is not concerning for large applications indeed. But say, I

Re: Slow start up time of runtime

2018-03-20 Thread David Nadlinger via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 09:44:41 UTC, Dennis wrote: Are there ways to reduce this to below 0.1s, or should I just leave idiomatic D and make a betterC program? The best solution would be to profile the startup process and file a bug accordingly. ;) — David

Re: Slow start up time of runtime

2018-03-20 Thread bauss via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 12:07:12 UTC, bauss wrote: On Tuesday, 20 March 2018 at 10:46:11 UTC, Dennis wrote: On Tuesday, 20 March 2018 at 10:20:55 UTC, Dennis wrote: On Tuesday, 20 March 2018 at 09:51:09 UTC, bauss wrote: Besides if it was and it took 1 second to startup, then it wouldn't

Re: Slow start up time of runtime

2018-03-20 Thread bauss via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 10:46:11 UTC, Dennis wrote: On Tuesday, 20 March 2018 at 10:20:55 UTC, Dennis wrote: On Tuesday, 20 March 2018 at 09:51:09 UTC, bauss wrote: Besides if it was and it took 1 second to startup, then it wouldn't matter in practice with an actual application. This is

Re: Slow start up time of runtime

2018-03-20 Thread Adam D. Ruppe via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 09:44:41 UTC, Dennis wrote: I suppose initializing the runtime takes a lot of time. I suspect you are seeing the Windows antivirus hitting you. D runtime starts up in a tiny fraction of a second, you shouldn't be noticing it. Go into the Windows security center

Re: Slow start up time of runtime

2018-03-20 Thread HeiHon via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 12:18:16 UTC, Adam D. Ruppe wrote: Go into the Windows security center and uncheck the real time virus check protection. I betcha you'll see this delay (and a similar one on dmd itself, your compiles could be running at half-speed with this too) disappear and everyt

Re: Slow start up time of runtime (correction: Windows real-time protection)

2018-03-20 Thread Dennis via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 12:18:16 UTC, Adam D. Ruppe wrote: On Tuesday, 20 March 2018 at 09:44:41 UTC, Dennis wrote: I suspect you are seeing the Windows antivirus hitting you. D runtime starts up in a tiny fraction of a second, you shouldn't be noticing it. You're totally right, disablin

Re: Slow start up time of runtime (correction: Windows real-time protection)

2018-03-20 Thread rumbu via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 16:56:59 UTC, Dennis wrote: On Tuesday, 20 March 2018 at 12:18:16 UTC, Adam D. Ruppe wrote: On Tuesday, 20 March 2018 at 09:44:41 UTC, Dennis wrote: I suspect you are seeing the Windows antivirus hitting you. D runtime starts up in a tiny fraction of a second, you

Re: Slow start up time of runtime (correction: Windows real-time protection)

2018-03-21 Thread HeiHon via Digitalmars-d-learn
On Tuesday, 20 March 2018 at 16:56:59 UTC, Dennis wrote: On Tuesday, 20 March 2018 at 12:18:16 UTC, Adam D. Ruppe wrote: On Tuesday, 20 March 2018 at 09:44:41 UTC, Dennis wrote: This now leaves the question what's the best way to mitigate this, because I would gladly get rid of the second of de

Re: Slow start up time of runtime (correction: Windows real-time protection)

2018-03-21 Thread Dennis via Digitalmars-d-learn
On Wednesday, 21 March 2018 at 13:26:48 UTC, HeiHon wrote: I added exclusions for the folder, where I installed dmd and ldc and I added an exclusion for the folder, where I compile my D programs. Now startup of dmd and freshly compiled programs is fast again. I've done this too now, thanks fo

Re: Slow start up time of runtime (correction: Windows real-time protection)

2018-03-21 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 21 March 2018 at 13:26:48 UTC, HeiHon wrote: In Windows Security Center Settings (where you can disable realtime scan) there is also an entry "Exclusions" (in german windows "Ausschlüsse"). I added exclusions for the folder, where I installed dmd and ldc and I added an exclusion f