MT5 and speed in action - page 41

 
A100:

And the fact that I'm slow is confirmed by the fact that even this doesn't play for anyone else:

Now I've tried it - it's not playing for me either. Perhaps the principle of calculations on the weekly and monthly chart with deep history has changed and the delays have disappeared by themselves

 
fxsaber:

Yes, that's why I use this condition in mqh.

on the first check false kills the other 4 checks. it is better to use || then, the subsequent ones will be ignored in case of lags.

 
Andrei Trukhanovich:

on the first check false kills the other 4 checks. it is better to use || then, the subsequent ones will be ignored in case of slowness.

This is the way it's meant to be. If GetMicrosecondsCount is slow, it is always slow.

 
fxsaber:

Please share the results of running this EA from your VPS (not your home machine).

Not really a VPS, but a virtual machine on rented hardware:

2020.09.29 00:11:11.350 Terminal        MetaTrader 5 x64 build 2615 started for MetaQuotes Software Corp.
2020.09.29 00:11:11.352 Terminal        Windows 7 Service Pack 1 build 7601 on Virtual Box, Intel Core i7-4770  @ 3.40 GHz, 14 / 15 Gb memory, 4 / 31 Gb disk, IE 11, Admin, GMT+2
2020.10.05 11:11:25.340 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:11:31.308 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:12:34.699 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 3 mсs.
2020.10.05 11:13:04.388 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:13:58.116 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:14:08.388 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:14:14.975 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:14:19.095 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:15:28.814 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:15:55.814 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:15:56.814 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:16:27.818 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 9 mсs.
2020.10.05 11:16:35.275 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:16:45.775 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 27 mсs.
2020.10.05 11:16:51.715 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
2020.10.05 11:17:30.477 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 5 mсs.
2020.10.05 11:18:25.081 test (GBPUSD,M15)       Alert: Time[test.mq5 7 in OnTimer: GetMicrosecondCount()] = 2 mсs.
 
Andrey Khatimlianskii:

Not really a UPU, but a virtual machine on rented hardware:

Thank you. On your machine, the braking seems to be weak. You would need to change the FreezeVPS condition to a suitable one so that such a configuration is not considered slow.

 
fxsaber:

Please share the results of running this EA from your VPS (not your home machine).

2020.10.05 12:58:15.715 Terminal        MetaTrader 5 x64 build 2629 started for MetaQuotes Software Corp.
2020.10.05 12:58:15.717 Terminal        Windows Server 2019 build 17763 on Hyper-V, Intel Xeon  E5-2676 v3 @ 2.40 GHz, 0 / 0 Gb memory, 15 / 29 Gb disk, IE 11, RDP, UAC, Admin, GMT+0
2020.10.05 13:03:46.523 Test (EURUSD,M1)        Alert: Time[Test.mq5 15 in OnTimer: GetMicrosecondCount()] = 3 mcs.
2020.10.05 13:04:34.594 Test (EURUSD,M1)        Alert: Time[Test.mq5 15 in OnTimer: GetMicrosecondCount()] = 4 mcs.

It just quit twice and then it's gone, it won't run again.
I don't know how to interpret it.


And on a local virtual machine, this

2020.10.05 16:52:50.149 Terminal        Windows 10 build 14393 on VirtualBox, Intel Core i7-3770 K  @ 3.50 GHz, 4 / 5 Gb memory, 244 / 299 Gb disk, IE 11, Admin, GMT+3
2020.10.05 16:58:12.631 Test (MNQZ20,M1)        Alert: Benchmark.mqh: FreezeVPS - https://www.mql5.com/ru/forum/342090/page40#comment_18579094
 
fxsaber:

Please share the results of running this EA from your VPS (not your home machine).

2020.10.05 16:13:31.939 Test VPS (EURUSD,H1)    Alert: Benchmark.mqh: FreezeVPS - https://www.mql5.com/ru/forum/342090/page40#comment_18579094
2020.10.05 16:13:05.359 Terminal        RoboForex - MetaTrader 5 x64 build 2615 started for RoboMarkets Ltd
2020.10.05 16:13:05.360 Terminal        Windows Server 2012 R2 build 9600, QEMU Virtual  version (cpu64-rhel6), 0 / 0 Gb memory, 3 / 19 Gb disk, IE 11, RDP, UAC, Admin, GMT+3

1 core, 1GB RAM.

No timings shown. I didn't look into the code, I compiled it as is.

 
Roman:
Edgar Akhmadeev:

No timings were shown. I didn't look into the code, I compiled as is.

Thanks for the information. In Benchmark.mqh the top line should be uncommented and the bottom line the other way around. So that it would be like this.

static const bool BENCHMARK::IsNotFreezeVPS = true; // Насильно заставляем замерять, даже если есть тормоза.
// static const bool BENCHMARK::IsNotFreezeVPS = !BENCHMARK::IsFreezeVPS();

Then the metering will work. Now we have a protection, that if "brakes" are detected, then do not measure.

 
fxsaber:

Thanks for the information. In Benchmark.mqh you need to uncomment the top line and reverse the bottom line. So that it is like this.

Then the metering will work. Now there is a protection, that if you find "brakes", then do not measure.

Thanks for the batch. Yes, the LAN alerts very often.
Now I understand how to interpret it.

 
fxsaber:

The FreezeVPS condition will have to be changed to a suitable one so that it is not considered a bottleneck.

Based on the measurements you posted, I have made the appropriate adjustments.