Skip to content

Commit

Permalink
Port Fix AwaitableSocketAsyncEventArgs reorderings on weaker memory m… (
Browse files Browse the repository at this point in the history
#5343)

* Port Fix AwaitableSocketAsyncEventArgs reorderings on weaker memory models

* Remove dotnet-blob-feed
  • Loading branch information
HongGit authored Nov 3, 2023
1 parent 66845f0 commit fe8bfd5
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
4 changes: 0 additions & 4 deletions azure-pipelines-arcade.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,16 +80,12 @@ stages:
# Internal/Official Build Variables
- ${{ if eq(variables._RunAsInternal, True) }}:
# Only enable publishing in non-public, non PR scenarios.
# DotNet-Blob-Feed provides: dotnetfeed-storage-access-key-1
# Publish-Build-Assets provides: MaestroAccessToken, BotAccount-dotnet-maestro-bot-PAT
# DotNet-HelixApi-Access provides: HelixApiAccessToken
- group: DotNet-Blob-Feed
- group: Publish-Build-Assets
- group: DotNet-HelixApi-Access
- _PublishBlobFeedUrl: https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json
- _InternalBuildArgs: /p:DotNetSignType=$(_SignType) /p:TeamName=$(_TeamName)
/p:DotNetPublishBlobFeedKey=$(dotnetfeed-storage-access-key-1)
/p:DotNetPublishBlobFeedUrl=$(_PublishBlobFeedUrl)
/p:DotNetPublishToBlobFeed=$(_DotNetPublishToBlobFeed)
/p:DotNetPublishUsingPipelines=$(_PublishUsingPipelines)
/p:DotNetArtifactsCategory=$(_DotNetArtifactsCategory)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@ internal class SocketAwaitableEventArgs : SocketAsyncEventArgs, IValueTaskSource
{
private static readonly Action<object> _continuationCompleted = _ => { };

private Action<object> _continuation;
// There are places where we read the _continuation field and then read some other state which we assume to be consistent
// with the value we read in _continuation. Without a fence, those secondary reads could be reordered with respect to the first.
// https://github.com/dotnet/runtime/pull/84432
// https://github.com/dotnet/aspnetcore/issues/50623
private volatile Action<object> _continuation;

public SocketAwaitableEventArgs() : base(unsafeSuppressExecutionContextFlow: true) { }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@ internal class SocketAwaitableEventArgs : SocketAsyncEventArgs, IValueTaskSource
{
private static readonly Action<object> _continuationCompleted = _ => { };

private Action<object> _continuation;
// There are places where we read the _continuation field and then read some other state which we assume to be consistent
// with the value we read in _continuation. Without a fence, those secondary reads could be reordered with respect to the first.
// https://github.com/dotnet/runtime/pull/84432
// https://github.com/dotnet/aspnetcore/issues/50623
private volatile Action<object> _continuation;

public SocketAwaitableEventArgs() : base(unsafeSuppressExecutionContextFlow: true) { }

Expand Down

0 comments on commit fe8bfd5

Please sign in to comment.