Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Use the portable timer implementation in CoreCLR#71864

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
jkotas merged 1 commit intodotnet:mainfromkouvel:PTimer
Jul 9, 2022

Conversation

kouvel
Copy link
Contributor

Fixes#46266

@kouvelkouvel added this to the7.0.0 milestoneJul 9, 2022
@kouvelkouvel self-assigned thisJul 9, 2022
@ghost
Copy link

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

Issue Details

Fixes#46266

Author:kouvel
Assignees:kouvel
Labels:

area-System.Threading

Milestone:7.0.0

@kouvel
Copy link
ContributorAuthor

No significant difference in timer microbenchmarks:

MethodToolchainMeanErrorStdDev
ShortScheduleAndDisposeBefore137.8 ns4.31 ns4.96 ns
ShortScheduleAndDisposeAfter129.9 ns3.48 ns4.01 ns
LongScheduleAndDisposeBefore131.5 ns2.60 ns2.43 ns
LongScheduleAndDisposeAfter129.9 ns3.38 ns3.89 ns
ScheduleManyThenDisposeManyBefore469,028,385.0 ns10,482,945.31 ns12,072,175.41 ns
ScheduleManyThenDisposeManyAfter450,835,495.0 ns28,191,768.65 ns32,465,682.70 ns
ShortScheduleAndDisposeWithFiringTimersBefore153.8 ns6.07 ns6.24 ns
ShortScheduleAndDisposeWithFiringTimersAfter160.6 ns4.80 ns5.33 ns
SynchronousContentionBefore4,334,738,207.1 ns26,386,498.36 ns23,390,943.51 ns
SynchronousContentionAfter4,332,649,160.0 ns26,337,511.15 ns24,636,124.27 ns
AsynchronousContentionBefore4,333,695,664.3 ns12,912,192.76 ns11,446,322.56 ns
AsynchronousContentionAfter4,338,598,086.7 ns12,938,144.86 ns12,102,348.73 ns
am11 reacted with rocket emoji

@am11
Copy link
Member

am11 commentedJul 9, 2022

Do we want to update NativeAOT's project file too?src/coreclr/nativeaot/System.Private.CoreLib/src/System.Private.CoreLib.csproj

cc@MichalStrehovsky

@jkotas
Copy link
Member

Do we want to update NativeAOT's project file too?

This is switching CoreCLR to what NativeAOT used since forever.

Copy link
Member

@jkotasjkotas left a comment

Choose a reason for hiding this comment

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

Nice!

@am11
Copy link
Member

am11 commentedJul 9, 2022

@jkotas, I meant these defaults:

<PropertyGroup>
<FeaturePortableThreadPoolCondition="'$(FeaturePortableThreadPool)' == ''">false</FeaturePortableThreadPool>
<FeaturePortableThreadPoolCondition="'$(TargetsUnix)' == 'true'">true</FeaturePortableThreadPool>
</PropertyGroup>
<PropertyGroup>
<FeaturePortableTimerCondition="'$(FeaturePortableTimer)' == ''">false</FeaturePortableTimer>
<FeaturePortableTimerCondition="'$(TargetsUnix)' == 'true'">true</FeaturePortableTimer>
</PropertyGroup>
on windows, it isfalse.

@jkotas
Copy link
Member

jkotas commentedJul 9, 2022
edited
Loading

NativeAOT is using native Windows OS threadpool and timers on Windows. We may want to change it, but not in this PR. It is not obvious that it would be an improvement.

am11 reacted with thumbs up emoji

@jkotasjkotas merged commit2d41986 intodotnet:mainJul 9, 2022
@davidfowl
Copy link
Member

❤️

@davidfowl
Copy link
Member

The only nit would be to remove the comment saying that this is a Unix specific implementation of the timer queue

@kouvelkouvel deleted the PTimer branchJuly 11, 2022 16:56
@ghostghost locked asresolvedand limited conversation to collaboratorsAug 10, 2022
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@filipnavarafilipnavarafilipnavara approved these changes

@jkotasjkotasjkotas approved these changes

@AntonLapounovAntonLapounovAwaiting requested review from AntonLapounov

@eduardo-vpeduardo-vpAwaiting requested review from eduardo-vp

@mangod9mangod9Awaiting requested review from mangod9

Assignees

@kouvelkouvel

Projects
None yet
Milestone
7.0.0
Development

Successfully merging this pull request may close these issues.

Use Portable TimerQueue when using Portable ThreadPool
5 participants
@kouvel@am11@jkotas@davidfowl@filipnavara

[8]ページ先頭

©2009-2025 Movatter.jp