Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Created attachment 21718 [details]
I am using the WrapLayout from here: https://github.com/conceptdev/xamarin-forms-samples/blob/master/Evolve13/Evolve13/Controls/WrapLayout.cs
The problem is that the memory consumption is huge (as seen in Xamarin Profiler) when the items are containing an image.
I attached a test project to reproduce this issue.
OS: iOS 10.3
Thank you for filing this report!
I ran the project you attached and I could see the high memory usage you mentioned. However I noticed that the resolution of some of the image resources in the project are very large. For example, the PowerPoint icon shows as being 2000 x 2000. This is not recommenced because the image will be decoded at the full resolution and use more memory even though it will be scaled down when rendered.
To test this, I changed the items IconSource to the star.png also included in the project and I saw a significant reduction in memory usage. I would suggest optimizing your images for multiple resolutions in order to avoid potential memory issues. You can see more info here. I would also recommend checking out the newer WrapLayout sample here as the original was based on an older version of Xamarin.Forms.
If you continue seeing significant memory usage after doing the above, please re-open this report and include an updated project. Thanks!