Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[release/7.0] [mono][llvm] Disable simd intrinsics when we might be interoping between jit and llvmaot #75261

Closed
wants to merge 3 commits into from

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented Sep 8, 2022

Backport of #74797 to release/7.0

/cc @SamMonoRT @BrzVlad

Customer Impact

Testing

Risk

IMPORTANT: Is this backport for a servicing release? If so and this change touches code that ships in a NuGet package, please make certain that you have added any necessary package authoring and gotten it explicitly reviewed.

…en jit and llvmaot

Revert previous partial disabling of simd intrinsics.

If we have a method that checkes if some hardware functionality `IsSupported` and then calls another method making use of this functionality if so, we have a problem if the method using the actual intrinsic is not also aot compiled and the intrisic is not supported by the jit. This issue is exposed inside bcl code, where this pattern is very common, by use of profiled aot on android. This change goes for the most conservative approach, by disabling all simd if we are not fullaot-ing and we use llvm.
@BrzVlad
Copy link
Member

BrzVlad commented Sep 8, 2022

There is a failing lane that I don't see it running on my main PR. This is fishy.

@carlossanlop
Copy link
Member

carlossanlop commented Sep 8, 2022

There is a failing lane that I don't see it running on my main PR. This is fishy.

I"ll temporarily add the "no merge" label while you investigate it. Please ping me when ready to get this merged (and also please remove the label).

@marek-safar we need an approval, please.

@carlossanlop carlossanlop added the NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons) label Sep 8, 2022
@carlossanlop
Copy link
Member

carlossanlop commented Sep 8, 2022

@vargaz or @lambdageek or @SamMonoRT can you please give a code review sign off?

Some of these methods are recursively calling themselves so we need to intrinsify them.
Mixing llvm jit with intrinsics enabled with aot code that has intrinsics disabled also is buggy. Seems like it can lead to simd opcodes being applied to non aligned addresses.

At this point we would only have simd instrinsics enabled with fullaotllvm.
@carlossanlop
Copy link
Member

@BrzVlad I see you added new commits. Were they also added to main? Are they addressing the fishy concern you mentioned above?

@BrzVlad
Copy link
Member

BrzVlad commented Sep 12, 2022

Seems like just disabling SIMD wasn't really tested and it keeps triggering failures here and there even with fix attempts. This PR is not really suitable for backport.

@BrzVlad BrzVlad closed this Sep 12, 2022
@jkotas jkotas deleted the backport/pr-74797-to-release/7.0 branch September 13, 2022 02:03
@ghost ghost locked as resolved and limited conversation to collaborators Oct 13, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-Codegen-JIT-mono NO-MERGE The PR is not ready for merge yet (see discussion for detailed reasons)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants