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

Disabled tests: System.IO.MemoryMappedFiles.MemoryMappedViewAccessor.ValidAccessLevelCombinations on MacCatalyst arm64 #53601

Closed
lambdageek opened this issue Jun 2, 2021 · 5 comments
Assignees
Labels
area-Codegen-Interpreter-mono disabled-test The test is disabled in source code against the issue os-maccatalyst MacCatalyst OS runtime-mono specific to the Mono runtime
Milestone

Comments

@lambdageek
Copy link
Member

lambdageek commented Jun 2, 2021

Disabled in #53197 (comment):

  • System.IO.MemoryMappedFiles.Tests.MemoryMappedViewAccessorTests.ValidAccessLevelCombinations
  • System.IO.MemoryMappedFiles.Tests.MemoryMappedViewStreamTests.ValidAccessLevelCombinations

Probably unrelated to #49104 (which has PlatformDetection.IsMacOsAppleSilicon applied - so maybe we need IsMacOsCatalystAppleSilicon, too), because most of the other tests are passing. Just the ones that are trying various permissions.

In particular the ReadWriteExecute permissions tests aren't likely to work (because of the W^X prohibition on silicon).

@lambdageek lambdageek added area-Codegen-Interpreter-mono runtime-mono specific to the Mono runtime os-maccatalyst MacCatalyst OS labels Jun 2, 2021
@ghost
Copy link

ghost commented Jun 2, 2021

Tagging subscribers to this area: @BrzVlad
See info in area-owners.md if you want to be subscribed.

Issue Details

Disabled:

  • System.IO.MemoryMappedFiles.Tests.MemoryMappedViewAccessorTests.ValidAccessLevelCombinations
  • System.IO.MemoryMappedFiles.Tests.MemoryMappedViewStreamTests.ValidAccessLevelCombinations

Probably related to #49104 (which has PlatformDetection.IsMacOsAppleSilicon applied - so maybe we need IsMacOsCatalystAppleSilicon, too).

In particular the ReadWriteExecute permissions tests aren't likely to work (because of the W^X prohibition on silicon).

Author: lambdageek
Assignees: -
Labels:

area-Codegen-Interpreter-mono, os-maccatalyst, runtime-mono

Milestone: -

@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label Jun 2, 2021
@lambdageek lambdageek added this to the 6.0.0 milestone Jun 2, 2021
@lambdageek lambdageek added the disabled-test The test is disabled in source code against the issue label Jun 2, 2021
@SamMonoRT
Copy link
Member

@BrzVlad - please take a look.

@lambdageek
Copy link
Member Author

IMO, the important thing here is to understand if just read-only or read-write permissions are working. The write-execute stuff is expected not to work on Apple M1

@steveisok steveisok removed the untriaged New issue has not been triaged by the area owner label Jun 29, 2021
@BrzVlad
Copy link
Member

BrzVlad commented Aug 2, 2021

I'm not sure yet what is the proper fix for this. Here are the conclusions though.

  • when trying to do mappings with write execute permissions, which are not supposed to work, mmap returns 0 and the mapping attempt throws. We already have a catch for such exceptions on MacOS where the test is skipped, I guess we could just add another check for MacOSCatalyst and not bother anymore with it ? Other mappings work fine.
  • I don't know what was originally reproduced, but locally I was getting a crash with test args [InlineData(MemoryMappedFileAccess.ReadExecute, MemoryMappedFileAccess.ReadExecute)]. The mapping was created successfully but when accessing the mapped memory the application simply crashed. After some investigation it turns out codesigning the application fixes this issue. I did this manually, are we already codesigning automatically on the CI ?

@BrzVlad
Copy link
Member

BrzVlad commented Aug 5, 2021

Disabled test on maccatalyst

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-Codegen-Interpreter-mono disabled-test The test is disabled in source code against the issue os-maccatalyst MacCatalyst OS runtime-mono specific to the Mono runtime
Projects
None yet
Development

No branches or pull requests

4 participants