Bug 42933 - Make AOT diagnostic messages less scary
Summary: Make AOT diagnostic messages less scary
Alias: None
Product: Android
Classification: Xamarin
Component: Mono runtime / AOT Compiler ()
Version: unspecified
Hardware: PC Mac OS
: --- normal
Target Milestone: ---
Assignee: Jonathan Pryor
Depends on:
Reported: 2016-07-29 19:52 UTC by Mikayla Hutchinson [MSFT]
Modified: 2016-09-05 19:41 UTC (History)
6 users (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and 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 Links.

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 for Bug 42933 on Developer Community or GitHub if you have new information to add and do not yet see a matching new report.

If the latest results still closely match this report, you can use the original description:

  • Export the original title and description: Developer Community HTML or GitHub Markdown
  • Copy the title and description into the new report. Adjust them to be up-to-date if needed.
  • Add your new information.

In special cases on GitHub you might also want the comments: GitHub Markdown with public comments

Related Links:

Description Mikayla Hutchinson [MSFT] 2016-07-29 19:52:02 UTC
The messaging about failing to load AOT images looks like an error, and as a result users are disabling fast deploy:


Th message is currently:

   AOT module 'mscorlib.dll.so' not found: dlopen failed: library "/data/app/<your app name>.Droid-1/lib/x86/libaot-mscorlib.dll.so" not found

It should be changed to something less scary like:

    Using JIT for 'mscorlib.dll' as AOT module '/data/app/<your app name>.Droid-1/lib/x86/libaot-mscorlib.dll.so' was not found.

Or, even better, suppress these messages entirely when building without AOT as they have no value in that case.
Comment 2 Rodrigo Kumpera 2016-08-01 17:37:08 UTC
We won't be fixing the error message, customers will keep panic'ng over more subtle messages.

How about we disable the probing when AOT was not requested? This even has the nice side effect of actually speeding up startup.

Jonp, to disable AOT probing, XA needs to pass -O=-aot as one of the runtime arguments.

Would that be something you guys can do for C9?
Comment 3 Jonathan Pryor 2016-08-01 19:18:05 UTC
> Would that be something you guys can do for C9?

Yes, if I can figure out how to do that. :-)

Can `mono_jit_parse_options()` be invoked multiple times, and would that be the appropriate API for passing `-O=-aot`?
Comment 4 Alex Rønne Petersen 2016-08-29 08:26:00 UTC
@Jonathan: XA already does invoke it in several places. It should be fine. It supports the `-O` flag as well.