Skip to content

[mono] Add an 'allow-loader-errors' AOT option. - #64640

Merged
vargaz merged 1 commit into
dotnet:mainfrom
vargaz:allow-loader-errors
Feb 6, 2022
Merged

[mono] Add an 'allow-loader-errors' AOT option.#64640
vargaz merged 1 commit into
dotnet:mainfrom
vargaz:allow-loader-errors

Conversation

@vargaz

Copy link
Copy Markdown
Contributor

This can be used to avoid aborting the AOT process if a loader
error occurs. The methods which fail to load will not be AOTed and
the failures will happen at runtime.

Related:
#63654

@lambdageeklambdageek left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's not just loader errors.

There could be marshaler errors, too, for example:

wrapper=mono_marshal_get_managed_wrapper (method, klass, 0, error);
mono_error_assert_ok (error);

And there are other calls to mono_error_assert_ok in aot-compiler.c that could be masking loader errors.

This can be used to avoid aborting the AOT process if a loader
error occurs. The methods which fail to load will not be AOTed and
the failures will happen at runtime.
Related:
dotnet#63654
@vargaz
vargazforce-pushed the allow-loader-errors branch from b1a2945 to bb823aaCompareFebruary 1, 2022 23:00
@vargaz

vargaz commented Feb 1, 2022

Copy link
Copy Markdown
ContributorAuthor

Renamed the option to 'allow-errors'. If the tests hit one of those assertions, we can convert them to errors as well.

@vargaz
vargaz merged commit ef817df into dotnet:mainFeb 6, 2022
@vargaz
vargaz deleted the allow-loader-errors branch February 6, 2022 11:59
@ghostghost locked as resolved and limited conversation to collaborators Mar 8, 2022
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@vargaz@lambdageek