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

More lib testing with native AOT #69132

Merged
merged 9 commits into from
Jun 2, 2022
Merged

Conversation

LakshanF
Copy link
Member

Experimental PR to get test coverage for native aot with some libraries

@dotnet-issue-labeler
Copy link

I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label.

@MichalStrehovsky
Copy link
Member

Note this didn't trigger any of the NativeAOT test legs. We definitely want to run them before merging this.

@MichalStrehovsky
Copy link
Member

The FileSystem test was failing with an OOM on Linux.

I've added a commit that disables pre-enumaration of theories. It's what the "official" runner also does:

https://github.com/dotnet/arcade/blob/7ffde50ec98dbe3584bef2375165ec9a6b39cb35/src/Microsoft.DotNet.XUnitConsoleRunner/src/ConsoleRunner.cs#L338-L341

The FileSystem tests have several tests that allocate big byte arrays as TheoryData that we then have to keep in memory. My theory is that disabling the pre-enumeration relieves the memory pressure:

public static IEnumerable<object[]> CopyFileWithData_MemberData()
{
var rand = new Random();
foreach (bool readOnly in new[] { true, false })
{
foreach (int length in new[] { 0, 1, 3, 4096, 1024 * 80, 1024 * 1024 * 10 })
{
char[] data = new char[length];
for (int i = 0; i < data.Length; i++)
{
data[i] = (char)rand.Next(0, 256);
}
yield return new object[] { data, readOnly};
}
}
}

@MichalStrehovsky
Copy link
Member

Looks good.

@LakshanF the Linux ARM64 Helix workitem actually failed a test. Could you look into why the CI lane still succeeded?

https://helixre107v0xdeko0k025g8.blob.core.windows.net/dotnet-runtime-refs-pull-69132-merge-1662767c930a41fbb3/System.Threading.Tests/1/console.b615871b.log?helixlogtype=result

I got to this log by clicking through the "Send to Helix" step on https://dev.azure.com/dnceng/public/_build/results?buildId=1801875&view=logs&jobId=b2c675c1-1c32-50e9-7c40-e762459300db&j=b2c675c1-1c32-50e9-7c40-e762459300db&t=4f51db95-f7de-5a4e-cd10-f078782dd75b

Following the JSON at "Sent Helix Job; see work items at https://helix.dot.net/api/jobs/1662767c-930a-41fb-b34d-b2c8e1f71572/workitems?api-version=2019-06-17" and following more JSON from there to get to the console output (not sure if there's a more convenient way to get to that).

Making sure CI lanes with failing tests don't succeed is a Pri-0.

Cc @dotnet/ilc-contrib FYI.

@MichalStrehovsky
Copy link
Member

The libraries test run failure is #70128, merging.

@MichalStrehovsky MichalStrehovsky merged commit f5d308d into dotnet:main Jun 2, 2022
@LakshanF LakshanF deleted the AotLibTest2 branch June 2, 2022 12:07
@LakshanF
Copy link
Member Author

LakshanF commented Jun 2, 2022

I got to this log by clicking through the "Send to Helix" step on https://dev.azure.com/dnceng/public/_build/results?buildId=1801875&view=logs&jobId=b2c675c1-1c32-50e9-7c40-e762459300db&j=b2c675c1-1c32-50e9-7c40-e762459300db&t=4f51db95-f7de-5a4e-cd10-f078782dd75b

Strange, I no longer can access the above link to see the failing job but can see the log results with the 1 failure.

I can follow the now successful job in Linux-arm64 since you disabled the test via "https://helix.dot.net/api/jobs/1662767c-930a-41fb-b34d-b2c8e1f71572/workitems/System.Threading.Tests?api-version=2019-06-17"

Thanks a lot for all the investigation and the work to merge this PR!

@MichalStrehovsky
Copy link
Member

Strange, I no longer can access the above link to see the failing job but can see the log results with the 1 failure.

that's odd. It was this run: https://github.com/dotnet/runtime/runs/6701362762. I now get an error when trying to follow the link to pipelines.

Either way, we now have the same problem in the System.Reflection test mentioned on Teams. That test is failing in a lot of the open PRs, but the CI lane is green.

@ghost ghost locked as resolved and limited conversation to collaborators Jul 3, 2022
Sign up for free to 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.

3 participants