Skip to content
This repository has been archived by the owner on May 3, 2024. It is now read-only.

Separate WaitGroup #572

Merged
merged 4 commits into from
Nov 3, 2023
Merged

Separate WaitGroup #572

merged 4 commits into from
Nov 3, 2023

Conversation

MBkkt
Copy link
Contributor

@MBkkt MBkkt commented Nov 2, 2023

No description provided.

@MBkkt MBkkt requested a review from Dronplane November 2, 2023 11:46
Copy link
Contributor

@Dronplane Dronplane left a comment

Choose a reason for hiding this comment

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

Why not use "counter*2" as delta values for Add and Done? And keep "1" as wait indicator. That will give us always accurate Count.

core/utils/wait_group.hpp Outdated Show resolved Hide resolved
@MBkkt
Copy link
Contributor Author

MBkkt commented Nov 3, 2023

Why not use "counter*2" as delta values for Add and Done? And keep "1" as wait indicator. That will give us always accurate Count.

We don't need "accurate" count.

Co-authored-by: Andrei Lobov <andrei.lobov@arangodb.com>
@Dronplane
Copy link
Contributor

Why not use "counter*2" as delta values for Add and Done? And keep "1" as wait indicator. That will give us always accurate Count.

We don't need "accurate" count.

Why we need method that intentionally lies?

@MBkkt
Copy link
Contributor Author

MBkkt commented Nov 3, 2023

Why we need method that intentionally lies?

it's not lies

@MBkkt MBkkt requested a review from Dronplane November 3, 2023 14:13
Copy link
Contributor

@Dronplane Dronplane left a comment

Choose a reason for hiding this comment

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

LGTM

@MBkkt MBkkt merged commit b2fe116 into master Nov 3, 2023
@MBkkt MBkkt deleted the chore/separate-wait-group branch November 3, 2023 20:22
Dronplane added a commit that referenced this pull request Nov 21, 2023
* Separate WaitGroup

* Update core/utils/wait_group.hpp

Co-authored-by: Andrei Lobov <andrei.lobov@arangodb.com>

* Exact count

* fix lints

---------

Co-authored-by: Andrei Lobov <andrei.lobov@arangodb.com>
Dronplane added a commit that referenced this pull request Nov 23, 2023
* Feature/use nonpriority pool (#570)

* new thread pool

* fix

* wip

* add static

* attempt to fix compile warning (#569)

the compile option `-fsized-deallocation` should only be used for C++
code, but not for C code. otherwise clang warns with the following
message:
```
warning: command-line option ‘-fsized-deallocation’ is valid for C++/ObjC++ but not for C
```

* Improve thread pool (#571)

* WIP

* WIP

* WIP

* WIP

* Update core/utils/async_utils.cpp

* Separate WaitGroup (#572)

* Separate WaitGroup

* Update core/utils/wait_group.hpp

Co-authored-by: Andrei Lobov <andrei.lobov@arangodb.com>

* Exact count

* fix lints

---------

Co-authored-by: Andrei Lobov <andrei.lobov@arangodb.com>

* Backport and start

* fix

* fix datarace

* fix build

---------

Co-authored-by: Jan <jsteemann@users.noreply.github.com>
Co-authored-by: Valery Mironov <32071355+MBkkt@users.noreply.github.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants