This repository was archived by the owner on May 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
This repository was archived by the owner on May 1, 2024. It is now read-only.
[Bug] Memory Leak when Using Image in Certain Containers #12733
Copy link
Copy link
Open
Labels
4.6.0regression on 4.6.0regression on 4.6.0a/imagea/performancee/3 🕒33i/regressionp/UWPs/unverifiedNew report that has yet to be verifiedNew report that has yet to be verifiedt/bug 🐛
Milestone
Description
Description
When using the Xamarin.Forms Image control to display font glyphs inside a Syncfusion tab view, the entire pages are kept in memory, causing memory leaks.
- Without the Image control, the leaks are gone;
- Without the container tab view, the leaks are gone as well in the attached example. However, there are still leaks in our real application. So I'm assuming it also leaks in certain other containers;
- There are no leaks when downgrading the Xamarin.Forms version to 4.6.
Steps to Reproduce
- Launch the attached example app in Visual Studio using the "Memory Usage" performance profiling ;
- Click the "Leak Page" button;
- Navigate back to the main page;
- Gather a snapshot after some GC;
- Repeat step 2 & 3 several times (5 in the example screenshots);
- Repeat step 4 and make a diff between the two snapshots.
Expected Behavior
No delta in the diff of live instances or at least no additional instances of the LeakPage and its associated instances.
Actual Behavior
Many new instances are kept in memory and cannot be GC'ed. See screenshots below.
Basic Information
- Version with issue: Xamarin.Forms 4.8.0.1534, 4.8.0.1560, 4.7.0.1351, probably more adjacent minor versions.
- Last known good version: Xamarin.Forms 4.6.0.1180
- IDE: Visual Studio 16.7.6
- Platform Target Frameworks:
- iOS: haven't tried
- Android: 10.0 (tried in our real app, not in the attached example)
- UWP: 19041.508
- Android Support Library Version: Xamarin.AndroidX.Core 1.3.0.1
- Nuget Packages: Syncfusion.Xamarin.SfTabView 18.3.0.44
- Affected Devices: Windows PC, Samsung Galaxy S10
Screenshots
Reproduction Link
Workaround
Downgrading Xamarin.Forms. However, our product release would be heavily affected by this.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
4.6.0regression on 4.6.0regression on 4.6.0a/imagea/performancee/3 🕒33i/regressionp/UWPs/unverifiedNew report that has yet to be verifiedNew report that has yet to be verifiedt/bug 🐛

