1. 03 Mar, 2017 5 commits
    • Austin Clements's avatar
      runtime: simplify sweep allocation counting · b50b7285
      Austin Clements authored
      Currently sweep counts the number of allocated objects, computes the
      number of free objects from that, then re-computes the number of
      allocated objects from that. Simplify and clean this up by skipping
      these intermediate steps.
      
      Change-Id: I3ed98e371eb54bbcab7c8530466c4ab5fde35f0a
      Reviewed-on: https://go-review.googlesource.com/34935
      Run-TryBot: Austin Clements <austin@google.com>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      Reviewed-by: default avatarMarvin Stenger <marvin.stenger94@gmail.com>
      Reviewed-by: default avatarRick Hudson <rlh@golang.org>
      b50b7285
    • Austin Clements's avatar
      runtime: don't rescan finalizers queue during mark termination · f1ba75f8
      Austin Clements authored
      Currently we scan the finalizers queue both during concurrent mark and
      during mark termination. This costs roughly 20ns per queued finalizer
      and about 1ns per unused finalizer queue slot (allocated queue length
      never decreases), which can drive up STW time if there are many
      finalizers.
      
      However, we only add finalizers to this queue during sweeping, which
      means that the second scan will never find anything new. Hence, we can
      fix this by simply not scanning the finalizers queue during mark
      termination. This brings the STW time under the 100µs goal even with
      1,000,000 queued finalizers.
      
      Fixes #18869.
      
      Change-Id: I4ce5620c66fb7f13ebeb39ca313ce57047d1d0fb
      Reviewed-on: https://go-review.googlesource.com/36013
      Run-TryBot: Austin Clements <austin@google.com>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      Reviewed-by: default avatarRick Hudson <rlh@golang.org>
      f1ba75f8
    • Austin Clements's avatar
      runtime: remove wbufptr · 98da2d1f
      Austin Clements authored
      Since workbuf is now marked go:notinheap, the write barrier-preventing
      wrapper type wbufptr is no longer necessary. Remove it.
      
      Change-Id: I3e5b5803a1547d65de1c1a9c22458a38e08549b7
      Reviewed-on: https://go-review.googlesource.com/35971
      Run-TryBot: Austin Clements <austin@google.com>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      Reviewed-by: default avatarRick Hudson <rlh@golang.org>
      98da2d1f
    • Austin Clements's avatar
      cmd/compile: accept string debug flags · 8eb14e9d
      Austin Clements authored
      The compiler's -d flag accepts string-valued flags, but currently only
      for SSA debug flags. Extend it to support string values for other
      flags. This also makes the syntax somewhat more sane so flag=value and
      flag:value now both accept integers and strings.
      
      Change-Id: Idd144d8479a430970cc1688f824bffe0a56ed2df
      Reviewed-on: https://go-review.googlesource.com/37345
      Run-TryBot: Austin Clements <austin@google.com>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      Reviewed-by: default avatarDavid Chase <drchase@google.com>
      8eb14e9d
    • Cherry Zhang's avatar
      cmd/compile: get rid of "volatile" in SSA · 5bfd1ef0
      Cherry Zhang authored
      A value is "volatile" if it is a pointer to the argument region
      on stack which will be clobbered by function call. This is used
      to make sure the value is safe when inserting write barrier calls.
      The writebarrier pass can tell whether a value is such a pointer.
      Therefore no need to mark it when building SSA and thread this
      information through.
      
      Passes "toolstash -cmp" on std.
      
      Updates #17583.
      
      Change-Id: Idc5fc0d710152b94b3c504ce8db55ea9ff5b5195
      Reviewed-on: https://go-review.googlesource.com/36835
      Run-TryBot: Cherry Zhang <cherryyz@google.com>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      Reviewed-by: default avatarKeith Randall <khr@golang.org>
      5bfd1ef0
  2. 02 Mar, 2017 27 commits
  3. 01 Mar, 2017 8 commits