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

Notify other threads before running callbacks #31713

Closed
wants to merge 2 commits into from

Conversation

xush6528
Copy link
Contributor

@xush6528 xush6528 commented Dec 30, 2019

Stack from ghstack:

  • In case the callbacks are heavy/slow, the other threads should be able to start work on the value of the future after the current thread moves the value and unlock the mutex.
  • completed() is not inlined. Avoid function call overhead.

Differential Revision: D5624371

In case the callbacks are heavy/slow, the other threads should be able to start work on the value of the future after the current thread moves the value and unlock the mutex.

Differential Revision: [D5624371](https://our.internmc.facebook.com/intern/diff/D5624371/)

[ghstack-poisoned]
xush6528 added a commit that referenced this pull request Dec 30, 2019
In case the callbacks are heavy/slow, the other threads should be able to start work on the value of the future after the current thread moves the value and unlock the mutex.

Differential Revision: [D5624371](https://our.internmc.facebook.com/intern/diff/D5624371/)

ghstack-source-id: 96189462
Pull Request resolved: #31713
@kostmo
Copy link
Member

kostmo commented Dec 30, 2019

💊 CircleCI build failures summary and remediations

As of commit c258e51:

Commit c258e51 was recently pushed. Waiting for builds...


This comment was automatically generated by Dr. CI (expand for details).Follow this link to opt-out of these comments for your Pull Requests.

Please report bugs/suggestions on the GitHub issue tracker.

This comment has been revised 5 times.

- In case the callbacks are heavy/slow, the other threads should be able to start work on the value of the future after the current thread moves the value and unlock the mutex.
- `completed()` is not inlined. Avoid function call overhead.

Differential Revision: [D5624371](https://our.internmc.facebook.com/intern/diff/D5624371/)

[ghstack-poisoned]
xush6528 added a commit that referenced this pull request Jan 15, 2020
Pull Request resolved: #31713

- In case the callbacks are heavy/slow, the other threads should be able to start work on the value of the future after the current thread moves the value and unlock the mutex.
- `completed()` is not inlined. Avoid function call overhead.

ghstack-source-id: 96694593

Differential Revision: [D5624371](https://our.internmc.facebook.com/intern/diff/D5624371/)
@facebook-github-bot
Copy link
Contributor

This pull request has been merged in 3d01e3d.

@facebook-github-bot facebook-github-bot deleted the gh/xush6528/53/head branch January 19, 2020 15:16
wuhuikx pushed a commit to wuhuikx/pytorch that referenced this pull request Jan 30, 2020
Summary:
Pull Request resolved: pytorch#31713

- In case the callbacks are heavy/slow, the other threads should be able to start work on the value of the future after the current thread moves the value and unlock the mutex.
- `completed()` is not inlined. Avoid function call overhead.

ghstack-source-id: 96694593

Test Plan: tdb

Differential Revision: D5624371

fbshipit-source-id: 5762e6e894d20108ec9afedd1a6e64bcd97ee3fe
ttumiel pushed a commit to ttumiel/pytorch that referenced this pull request Mar 4, 2020
Summary:
Pull Request resolved: pytorch#31713

- In case the callbacks are heavy/slow, the other threads should be able to start work on the value of the future after the current thread moves the value and unlock the mutex.
- `completed()` is not inlined. Avoid function call overhead.

ghstack-source-id: 96694593

Test Plan: tdb

Differential Revision: D5624371

fbshipit-source-id: 5762e6e894d20108ec9afedd1a6e64bcd97ee3fe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants