Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: golang/sync
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 8fcdb60
Choose a base ref
...
head repository: golang/sync
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 506c70f
Choose a head ref
  • 16 commits
  • 13 files changed
  • 13 contributors

Commits on Apr 19, 2023

  1. singleflight: make the check for exec support in TestPanicDoChan plat…

    …form-agnostic
    
    The new wasip1 GOOS does not support exec, but some ios environments
    (like Corellium) might. Update the test to exec itself with -test.list
    as a control case.
    
    For golang/go#58141.
    
    Change-Id: Id69950fc394910620f6c73cb437ca75c09ad8c29
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/485980
    Run-TryBot: Bryan Mills <bcmills@google.com>
    Commit-Queue: Bryan Mills <bcmills@google.com>
    Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
    Auto-Submit: Bryan Mills <bcmills@google.com>
    Reviewed-by: Johan Brandhorst-Satzkorn <johan.brandhorst@gmail.com>
    TryBot-Result: Gopher Robot <gobot@golang.org>
    Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
    Bryan C. Mills authored and gopherbot committed Apr 19, 2023
    Configuration menu
    Copy the full SHA
    1ea3257 View commit details
    Browse the repository at this point in the history

Commits on May 17, 2023

  1. go.mod: upgrade to go 1.17

    This change was produced using 'go mod tidy -go=1.17'
    with a go command built at CL 315210.
    
    This activates lazy loading, and updates the go.mod file to maintain
    the lazy-loading invariants (namely, including an explicit requirement
    for every package transitively imported by the main module).
    
    Note that this does *not* prevent users with earlier go versions from
    successfully building packages from this module.
    
    For golang/go#36460.
    
    Change-Id: Idb3d8d056d41bb254d0b5d9b2699ac33a51081f3
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/316130
    Auto-Submit: Bryan Mills <bcmills@google.com>
    Commit-Queue: Bryan Mills <bcmills@google.com>
    TryBot-Result: Gopher Robot <gobot@golang.org>
    Reviewed-by: Jonathan Amsterdam <jba@google.com>
    Run-TryBot: Bryan Mills <bcmills@google.com>
    Bryan C. Mills authored and gopherbot committed May 17, 2023
    Configuration menu
    Copy the full SHA
    a6666c1 View commit details
    Browse the repository at this point in the history

Commits on May 23, 2023

  1. singleflight: example for using Group

    Fixes golang/go#60208
    
    Change-Id: I422a45c0f139ba47045f47cec1c96d300a2a424f
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/496535
    Run-TryBot: Bryan Mills <bcmills@google.com>
    Auto-Submit: Bryan Mills <bcmills@google.com>
    TryBot-Result: Gopher Robot <gobot@golang.org>
    Reviewed-by: Ian Lance Taylor <iant@google.com>
    Reviewed-by: Bryan Mills <bcmills@google.com>
    seankhliao authored and gopherbot committed May 23, 2023
    Configuration menu
    Copy the full SHA
    4966af6 View commit details
    Browse the repository at this point in the history

Commits on Jun 1, 2023

  1. errgroup: use WithCancelCause to cancel context

    Fixes golang/go#59355
    
    Change-Id: Ib6a88e7e5fefe7b0d5672035af16d109aabcbf1e
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/481255
    TryBot-Result: Gopher Robot <gobot@golang.org>
    Run-TryBot: Bryan Mills <bcmills@google.com>
    Reviewed-by: Bryan Mills <bcmills@google.com>
    Run-TryBot: Ian Lance Taylor <iant@golang.org>
    Reviewed-by: Michael Knyszek <mknyszek@google.com>
    Auto-Submit: Bryan Mills <bcmills@google.com>
    jonjohnsonjr authored and gopherbot committed Jun 1, 2023
    Configuration menu
    Copy the full SHA
    93782cc View commit details
    Browse the repository at this point in the history

Commits on Sep 26, 2023

  1. singleflight: add panicError.Unwrap method

    Currently when singleflight recovers from a panic, it wraps it with the private
    error type panicError. This change adds an `Unwrap` method to panicError to
    allow wrapped errors to be returned.
    
    Updates golang/go#62511
    
    Change-Id: Ia510ad7d5881207ef71f9eb89c1766835af19b6b
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/526171
    Auto-Submit: Bryan Mills <bcmills@google.com>
    Reviewed-by: Than McIntosh <thanm@google.com>
    Reviewed-by: Bryan Mills <bcmills@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    ewohltman authored and gopherbot committed Sep 26, 2023
    Configuration menu
    Copy the full SHA
    22ba207 View commit details
    Browse the repository at this point in the history

Commits on Oct 11, 2023

  1. all: update go directive to 1.18

    Done with:
    
    go get go@1.18
    go mod tidy
    go fix ./...
    
    Using go1.21.3.
    
    While here, simplify package syncmap by taking advantage of knowing
    that all supported Go versions will have the go1.9 build constraint
    satisfied.
    
    For golang/go#60268.
    
    Change-Id: Ic0f24ab13ada6839573e55beee5516c1a6c7f3cc
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/534220
    Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org>
    Reviewed-by: Ian Lance Taylor <iant@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
    dmitshur authored and gopherbot committed Oct 11, 2023
    Configuration menu
    Copy the full SHA
    10739b0 View commit details
    Browse the repository at this point in the history

Commits on Dec 7, 2023

  1. errgroup: add reference to sync.WaitGroup

    Add doc link to sync.WaitGroup in the package documentation.
    
    Rationale:
    The reference to sync.WaitGroup might be obvious to the authors of this
    package, but it wasn't to me, so despites I had seen this package
    multiple times I had never made the link to sync.WaitGroup. So when
    playing with WaitGroup I was missing remembering about errgroup.
    In hope this will help others as well as my future self.
    
    Change-Id: I2c56976958ad9ab94c1596c96fa86c00dd73d2fb
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/538335
    Reviewed-by: Bryan Mills <bcmills@google.com>
    Reviewed-by: Carlos Amedee <carlos@golang.org>
    Auto-Submit: Bryan Mills <bcmills@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    dolmen authored and gopherbot committed Dec 7, 2023
    Configuration menu
    Copy the full SHA
    59c1ca1 View commit details
    Browse the repository at this point in the history

Commits on Mar 4, 2024

  1. semaphore: cancel acquisition with a done context

    When acquiring from a semaphore could proceed without contention, the
    previous behavior was to always do so, even when the provided context
    was done. This was the documented behavior, but it could lead to
    confusion. It isn't much more expensive to check the context error, so
    cancel acquisition if it's done.
    
    Fixes golang/go#63615.
    
    goos: linux
    goarch: amd64
    pkg: golang.org/x/sync/semaphore
    cpu: 12th Gen Intel(R) Core(TM) i5-1235U
                                            │  old.bench  │             new.bench              │
                                            │   sec/op    │   sec/op     vs base               │
    AcquireSeq/Weighted-acquire-1-1-1-12      26.45n ± 2%   27.25n ± 3%  +3.04% (p=0.001 n=20)
    AcquireSeq/Weighted-acquire-2-1-1-12      26.96n ± 1%   27.12n ± 1%       ~ (p=0.104 n=20)
    AcquireSeq/Weighted-acquire-16-1-1-12     26.07n ± 3%   27.48n ± 1%  +5.45% (p=0.000 n=20)
    AcquireSeq/Weighted-acquire-128-1-1-12    26.19n ± 2%   27.24n ± 1%  +4.01% (p=0.000 n=20)
    AcquireSeq/Weighted-acquire-2-2-1-12      25.61n ± 1%   25.99n ± 2%       ~ (p=0.066 n=20)
    AcquireSeq/Weighted-acquire-16-2-8-12     209.6n ± 2%   211.0n ± 3%       ~ (p=0.280 n=20)
    AcquireSeq/Weighted-acquire-128-2-64-12   1.669µ ± 1%   1.721µ ± 2%  +3.09% (p=0.000 n=20)
    AcquireSeq/Weighted-acquire-2-1-2-12      51.08n ± 1%   53.03n ± 2%  +3.82% (p=0.000 n=20)
    AcquireSeq/Weighted-acquire-16-8-2-12     52.48n ± 2%   53.66n ± 2%  +2.26% (p=0.028 n=20)
    AcquireSeq/Weighted-acquire-128-64-2-12   52.27n ± 1%   53.71n ± 2%  +2.75% (p=0.000 n=20)
    geomean                                   60.06n        61.69n       +2.71%
    
    Change-Id: I0ae1a0bb6c027461ac1a9ee71c51efd8427ab308
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/536275
    Auto-Submit: Bryan Mills <bcmills@google.com>
    Reviewed-by: Bryan Mills <bcmills@google.com>
    Reviewed-by: Michael Knyszek <mknyszek@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    zephyrtronium authored and gopherbot committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    14be23e View commit details
    Browse the repository at this point in the history

Commits on Jul 16, 2024

  1. LICENSE: update per Google Legal

    Very minor tweaks:
     - Remove (c) pseudosymbol.
     - Remove "All Rights Reserved."
     - Change "Google Inc." (no longer exists) to "Google LLC".
    
    [git-generate]
    echo '
    ,s/\(c\) //
    ,s/ All rights reserved.//
    ,s/Google Inc./Google LLC/
    w
    q
    ' | sam -d LICENSE
    
    Change-Id: Ifc1b84adca131018a48ba47e741a682a0ed9bb49
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/598584
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Reviewed-by: Ian Lance Taylor <iant@google.com>
    Auto-Submit: Russ Cox <rsc@golang.org>
    rsc authored and gopherbot committed Jul 16, 2024
    Configuration menu
    Copy the full SHA
    411f99e View commit details
    Browse the repository at this point in the history

Commits on Nov 1, 2024

  1. README: don't recommend go get

    These days people will just import the packages and the go tool will
    do the right thing. We don't need to explain it.
    
    Add a pointer to the git repo, though.
    
    For golang/go#62645
    
    Change-Id: Icbe33e05f96e1b32f6fcc99fb5fb0b2ecb213a08
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/623820
    Commit-Queue: Ian Lance Taylor <iant@google.com>
    Auto-Submit: Ian Lance Taylor <iant@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Reviewed-by: Alan Donovan <adonovan@google.com>
    Reviewed-by: Ian Lance Taylor <iant@google.com>
    ianlancetaylor authored and gopherbot committed Nov 1, 2024
    Configuration menu
    Copy the full SHA
    151027e View commit details
    Browse the repository at this point in the history

Commits on Nov 13, 2024

  1. singleflight: fix typo in singleflight_test.go

    Change-Id: Ia2160fdc8f1938d784a4e1595151c00bc521f5c3
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/626795
    TryBot-Result: Gopher Robot <gobot@golang.org>
    Auto-Submit: Ian Lance Taylor <iant@google.com>
    Run-TryBot: Emmanuel Odeke <emmanuel@orijtech.com>
    Commit-Queue: Ian Lance Taylor <iant@google.com>
    Reviewed-by: Emmanuel Odeke <emmanuel@orijtech.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Auto-Submit: Emmanuel Odeke <emmanuel@orijtech.com>
    Reviewed-by: Ian Lance Taylor <iant@google.com>
    Reviewed-by: Alan Donovan <adonovan@google.com>
    Reviewed-by: Cherry Mui <cherryyz@google.com>
    catatsuy authored and gopherbot committed Nov 13, 2024
    Configuration menu
    Copy the full SHA
    913fb63 View commit details
    Browse the repository at this point in the history

Commits on Jan 17, 2025

  1. sync/errgroup: improve documentation for semaphore limit behavior

    Updated the documentation for `SetLimit` and `Go` functions in the
    `errgroup` package. the note clarifies the behavior when the semaphore
    limit is set to zero, which could lead to a deadlock if not handled
    properly. the updated documentation warns users to set a positive
    semaphore limit to avoid blocking goroutines and potential deadlock
    
    this change improves the clarity of API and helps users understand how
    to properly use the semaphore limit to prevent issues in concurrent
    execution
    
    Change-Id: Ie62acc38ef804b3590c04bddba00a3cce21e8cef
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/642215
    Reviewed-by: Michael Knyszek <mknyszek@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Reviewed-by: Ian Lance Taylor <iant@google.com>
    Auto-Submit: Ian Lance Taylor <iant@google.com>
    berbreik authored and gopherbot committed Jan 17, 2025
    Configuration menu
    Copy the full SHA
    fe3591b View commit details
    Browse the repository at this point in the history

Commits on Feb 14, 2025

  1. all: upgrade go directive to at least 1.23.0 [generated]

    By now Go 1.24.0 has been released, and Go 1.22 is no longer supported
    per the Go Release Policy (https://go.dev/doc/devel/release#policy).
    
    For golang/go#69095.
    
    [git-generate]
    (cd . && go get go@1.23.0 && go mod tidy && go fix ./... && go mod edit -toolchain=none)
    
    Change-Id: I7e3b1e073a0a64e82e2b9e49387d5da0afd9d58b
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/649835
    Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
    Reviewed-by: Cherry Mui <cherryyz@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Auto-Submit: Gopher Robot <gobot@golang.org>
    gopherbot committed Feb 14, 2025
    Configuration menu
    Copy the full SHA
    960bf1f View commit details
    Browse the repository at this point in the history

Commits on Mar 4, 2025

  1. errgroup: drop support for Go versions before 1.20

    Change-Id: I7de5dfae21c4ffe31d6c16e3df0fed3e2269cb16
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/654421
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Reviewed-by: Ian Lance Taylor <iant@google.com>
    Auto-Submit: Ian Lance Taylor <iant@google.com>
    Commit-Queue: Ian Lance Taylor <iant@google.com>
    Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
    Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
    ianlancetaylor authored and gopherbot committed Mar 4, 2025
    Configuration menu
    Copy the full SHA
    b637f27 View commit details
    Browse the repository at this point in the history

Commits on Apr 2, 2025

  1. errgroup: document calling Go before Wait

    Fixes golang/go#70284
    
    Change-Id: I31d60ea182226c032b0ffbddcbb5b53675dfd5e6
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/660075
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    Reviewed-by: Alan Donovan <adonovan@google.com>
    Auto-Submit: Damien Neil <dneil@google.com>
    Reviewed-by: Damien Neil <dneil@google.com>
    seankhliao authored and gopherbot committed Apr 2, 2025
    Configuration menu
    Copy the full SHA
    396f3a0 View commit details
    Browse the repository at this point in the history

Commits on Apr 7, 2025

  1. errgroup: propagate panic and Goexit through Wait

    Recovered panic values are wrapped and saved in Group.
    Goexits are detected by a sentinel value set after the given function
    returns normally. Wait propagates the first instance of a panic or
    Goexit.
    
    According to the runtime.Goexit after the code will not be executed,
    with a bool, if f not call runtime.Goexit, is true,
    determine whether to propagate runtime.Goexit.
    
    Fixes golang/go#53757
    
    Change-Id: Ic6426fc014fd1c4368ebaceef5b0d6163770a099
    Reviewed-on: https://go-review.googlesource.com/c/sync/+/644575
    Reviewed-by: Sean Liao <sean@liao.dev>
    Auto-Submit: Alan Donovan <adonovan@google.com>
    Commit-Queue: Alan Donovan <adonovan@google.com>
    Reviewed-by: Alan Donovan <adonovan@google.com>
    Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
    LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
    qiulaidongfeng authored and gopherbot committed Apr 7, 2025
    Configuration menu
    Copy the full SHA
    506c70f View commit details
    Browse the repository at this point in the history
Loading