Beobachten
0
0
Fork
Du hast bereits einen Fork von MQL5-Google-Onedrive erstellt
1
Spiegel von https://github.com/A6-9V/MQL5-Google-Onedrive.git synchronisiert 2026-10-08 22:01:36 +00:00
MQL5-Google-Onedrive/mt5/MQL5/Experts
Repository-Dateien (neuester Commit zuerst)
Dateiname Letzte Commit-Nachricht Letztes Commit-Datum
google-labs-jules[bot] 8cdd10efa4 ⚡ Bolt: Cache MTF trend direction to reduce redundant calculations
💡 What:
Implemented a caching mechanism for the multi-timeframe (MTF) trend direction in the `GetMTFDir()` function. The trend is now recalculated only when a new bar forms on the lower timeframe.

🎯 Why:
The `GetMTFDir()` function was being called on every new bar of the main signal timeframe, leading to expensive and unnecessary `CopyBuffer` calls. Caching the result prevents these redundant calculations, improving the Expert Advisor's overall performance.

📊 Impact:
This change significantly reduces the number of expensive `CopyBuffer` calls, especially when the signal timeframe is much shorter than the confirmation timeframe (e.g., M5 signal, H1 confirmation). This leads to a more efficient EA that consumes fewer CPU cycles.

🔬 Measurement:
The improvement can be verified by adding logging to the `GetMTFDir()` function and observing that the recalculation logic is only triggered once per bar on the lower timeframe, rather than on every signal timeframe bar.
2026-01-01 10:32:55 +00:00
..
SMC_TrendBreakout_MTF_EA.mq5 ⚡ Bolt: Cache MTF trend direction to reduce redundant calculations 2026-01-01 10:32:55 +00:00