Skip to content

Conversation

@ManickaP
Copy link
Member

@ManickaP ManickaP commented May 7, 2022

This reverts commit 4820674.

Brings back #68288

Fixes #67377, #67301, #68954

@ghost ghost assigned ManickaP May 7, 2022
@ghost ghost added the area-System.Net.Quic label May 7, 2022
@ghost
Copy link

ghost commented May 7, 2022

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

Issue Details

This reverts commit 4820674.

Brings back #68288

Author: ManickaP
Assignees: ManickaP
Labels:

area-System.Net.Quic

Milestone: -

@ManickaP ManickaP changed the title Revert "Revert "[QUIC] Adopted msquic generated interop (#68288)" (#68940) "[QUIC] Adopted msquic generated interop (#68288)" attempt no 2 May 7, 2022
@ManickaP
Copy link
Member Author

ManickaP commented May 8, 2022

So the AOT itself is not failing anymore, but now I get:

Failed to load AOT module '/root/helix/work/correlation/System.Net.Quic.dll.so' ('/root/helix/work/correlation/System.Net.Quic.dll') in aot-only mode.

In Work Item JIT.Regression.JitBlue: https://helixre8s23ayyeko0k025g8.blob.core.windows.net/dotnet-runtime-refs-pull-69009-merge-bd97177d9b0441c6b0/JIT.Regression.JitBlue/1/console.ca962c5e.log?helixlogtype=result

@akoeplinger could help with this or do you know who could?

@ManickaP ManickaP force-pushed the mapichov/quic-interop-aot branch 2 times, most recently from fb127ca to bcace7d Compare May 9, 2022 13:09
@ManickaP
Copy link
Member Author

ManickaP commented May 9, 2022

I have a fix for #68954 ready, but I don't want to stop the pipeline by pushing it right now.

@ManickaP ManickaP force-pushed the mapichov/quic-interop-aot branch from 638702b to 3243fc1 Compare May 10, 2022 20:03
Comment on lines +148 to +178
Http3LoopbackStream requestStream = null;

while (true)
{
stream = await AcceptStreamAsync().ConfigureAwait(false);
var stream = await AcceptStreamAsync().ConfigureAwait(false);

// Accepted request stream.
if (stream.CanWrite)
{
return stream;
// Only one expected.
Assert.True(requestStream is null, "Expected single request stream, got a second");

// Control stream is set --> return the request stream.
if (_inboundControlStream is not null)
{
return stream;
}

// Control stream not set --> need to accept another stream.
requestStream = stream;
continue;
}

// Must be the control stream
// Must be the control stream.
await HandleControlStreamAsync(stream);

// We've already accepted request stream --> return it.
if (requestStream is not null)
{
return requestStream;
}
Copy link
Member Author

Choose a reason for hiding this comment

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

This is fix for the assert problem from #68954

Comment on lines +900 to 907

// Check if we already got final event.
bool releaseHandles = Interlocked.Exchange(ref _state.ShutdownDone, State.ShutdownDone_Disposed) == State.ShutdownDone_NotificationReceived;
if (releaseHandles)
{
_state.Cleanup();
}

Copy link
Member Author

Choose a reason for hiding this comment

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

This together with lines 871-877 in the original are a fix for the use after free part in #68954
Note that the removed: _state.ShutdownState = ShutdownState.Finished; is actually set in _state.Cleanup();:

<ItemGroup>
<TestsAndAssociatedAssemblies Include="%(TestDirs.Identity)/*.dll" Exclude="@(NoMonoAotAssemblyPaths)" />
<CoreRootDlls Include="$(CORE_ROOT)/*.dll" Exclude="$(CORE_ROOT)/xunit.performance.api.dll" />
<CoreRootDlls Include="$(CORE_ROOT)/*.dll" Exclude="$(CORE_ROOT)/xunit.performance.api.dll;$(CORE_ROOT)/System.Net.Quic.dll" />
Copy link
Member Author

Choose a reason for hiding this comment

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

Excludes us from mono AOT

Comment on lines +3029 to +3041

<ExcludeList Include="$(XunitTestBinBase)/JIT/Performance/RunBenchmarks/RunBenchmarks/**">
<Issue>https://github.com/dotnet/runtime/issues/52977</Issue>
</ExcludeList>
<ExcludeList Include="$(XunitTestBinBase)/JIT/Regression/JitBlue/GitHub_25468/GitHub_25468/**">
<Issue>https://github.com/dotnet/runtime/issues/52977</Issue>
</ExcludeList>
<ExcludeList Include="$(XunitTestBinBase)/JIT/CheckProjects/CheckProjects/**">
<Issue>https://github.com/dotnet/runtime/issues/52977</Issue>
</ExcludeList>
<ExcludeList Include="$(XunitTestBinBase)/ JIT/Performance/CodeQuality/BenchmarksGame/k-nucleotide/k-nucleotide-9/**">
<Issue>https://github.com/dotnet/runtime/issues/52977</Issue>
</ExcludeList>
Copy link
Member Author

Choose a reason for hiding this comment

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

Skips tests failing due to missing mono AOT generated System.Net.Quic.dll.so.

@ManickaP
Copy link
Member Author

ManickaP commented May 11, 2022

The pipeline is green and mono llvmfullaot ran: https://dev.azure.com/dnceng/public/_build/results?buildId=1763129&view=results

Can I get a review here? The PR is same as #68288 with the exceptions marked with comments, which are fixes for mono AOT error and #68954

@ManickaP ManickaP marked this pull request as ready for review May 11, 2022 08:19
@ManickaP ManickaP requested review from a team, CarnaViire, rzikm and wfurt May 11, 2022 08:19
@dotnet dotnet deleted a comment from azure-pipelines bot May 11, 2022
Copy link
Member

@rzikm rzikm left a comment

Choose a reason for hiding this comment

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

LGTM!

@ManickaP ManickaP merged commit 122c9d0 into dotnet:main May 11, 2022
@ManickaP ManickaP deleted the mapichov/quic-interop-aot branch May 11, 2022 14:29
@ghost ghost locked as resolved and limited conversation to collaborators Jun 10, 2022
@karelz karelz added this to the 7.0.0 milestone Jul 19, 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.

[QUIC] Adopt msquic generated interop layer

3 participants