flybywiresim / aircraft

The A32NX & A380X Project are community driven open source projects to create free Airbus aircraft in Microsoft Flight Simulator that are as close to reality as possible.
https://flybywiresim.com
GNU General Public License v3.0
4.97k stars 1.03k forks source link

[BUG] RMP causing CTD (possible memory leak) #3408

Closed Darlack6 closed 3 years ago

Darlack6 commented 3 years ago

{ "built": "2021-02-07T18:49:42+00:00", "ref": "fbw", "sha": "84192108aa63445a1930ae3fca5cd7d5392a6476", "actor": "aguther", "event_name": "manual" }

Describe the bug The third time the simulator CTD, it happened between 1H and 30 minutes to 2H of the flight. When looking to the left (where the EFB is located) I received extremely low frames (1-3) After, I rested my camera and the frames came back. I did this a few times and it repeated. 2 minutes after in default cockpit camera, the simulator crashed.

To Reproduce

  1. Load a flight (my flights were from KSFO-KLAX, KPHX-KLAX, KBOS-CYYZ)
  2. Near the 1 hour and 45-minute mark look towards the EFB, and identify any frame drops
  3. Reset camera position and wait a few minutes to see if the simulator crashes

Expected behavior Normal flight without a CTD, able to look at the direction and use the EFB.

Actual behavior While looking/interacting with the EFB the simulator CTD a few minutes after

References

None, as I did not expect the simulator to crash

Additional context I'm assuming that the EFB is causing a memory leak

Was this working before/when did the issue start occurring? The simulator did not crash for a long time since the EFB was introduced

Is this a problem in the vanilla unmodded game? No

Discord username (if different from GitHub): Darlack#3281

Benjozork commented 3 years ago

Does this happen with the EFB off ?

How many times have you reproduced it ?

Darlack6 commented 3 years ago

This happens with the EFB on, and I reproduced it three times.

Benjozork commented 3 years ago

And if I understand correctly, this happens after 1.5h-2hrs of flight, and isn't an issue before ?

Darlack6 commented 3 years ago

Correct.

Darlack6 commented 3 years ago

Here is a Video of CptCanada using the EFB he started experiencing the lag at 1:46:10 and crashed at 1:48:00 https://www.youtube.com/watch?v=8q-zQ-OWrNw&t=12531s

Benjozork commented 3 years ago

Confirmed by many people on Discord

Benjozork commented 3 years ago

Recent EFB commits that could have caused this

359af5bc1c4422ca2eaf2e360a953b10fdd8962e aff960bf74a0a806cb56ae8a14d5990a6181dff9 1dc3115e0251f810a4de39160688d8ccbd0b1248 b9245c886074dc9a8a8e6cdfd7724a5a3f8077c5 58226331dc863b799bffeb77bceaefc7655982cb

Needs a quicker repo

Benjozork commented 3 years ago

TO ANYONE EXPERIENCING THE SAME: Please state which functions of the EFB you used the most. Did you shut down / power on the EFB many times ?

Benjozork commented 3 years ago

Here is a Video of CptCanada using the EFB he started experiencing the lag at 1:46:10 and crashed at 1:48:00 https://www.youtube.com/watch?v=8q-zQ-OWrNw&t=12531s

This was probably caused by https://github.com/flybywiresim/installer/issues/106

daernsinstantfortress commented 3 years ago

I did a 3 hour test flight today (EGCC to LXGB) after experiencing a CTD on the same flight on Sunday when running SLC/FSUIPC. I had no external apps running (including Navigraph and SLC), but had a few mods installed including A32nx (obvs) and Maccos EGCC as well as the Working Title CJ4 + G1000/G3000.

A32nx build was the latest experimental (FBW) build at the time of testing:

{
  "built": "2021-02-07T18:49:42+00:00",
  "ref": "fbw",
  "sha": "84192108aa63445a1930ae3fca5cd7d5392a6476",
  "actor": "aguther",
  "event_name": "manual"
}

The EFB was open throughout and I periodically opened and closed it. The flight was loaded into it from SimBrief, but it never tracked my position at any point in the flight, despite repeated closures and reopens.

I specifically monitored the memory usage of MSFS during the flight to see if there was any apparent memory leak and these were the results:

Take off (12:50): 17GB on climb 10 mins in: 9.5GB in cruise 20 mins in: 7.3GB 30 mins in: 7.0GB 50 mins in: 6.6GB 60 mins in: 6.6GB 70 mins in: 6.5MB 90 mins in: 7.4GB 105 mins in: 4.4GB 110 mins in: 4.8GB 120 mins in: 4.7GB 130 mins in: 4.9GB (TOD) 170 mins: 6.6GB (4000ft) 180 mins: 6.7GB 190 mins landed: 8.6GB

The flight was stable throughout and, despite messing with the EFB, I couldn't force any obvious memory leak, nor destabilise the sim. Apart from the normal fight with the flight planner on approach, the landing was completely normal and no excessive drop of frame rate was experienced - landed at around 40fps on ultra settings, which is normal for my hardware (Ryzen 5600X, RTX3070, 32GB).

Sorry, appreciate that a negative report isn't that useful, but it's what my testing produced, so worth sharing anyway.

Benjozork commented 3 years ago

update: this is not caused by the EFB but by the RMP