1. 05 Jan, 2017 5 commits
    • Lion Yang's avatar
      x/crypto/chacha20poly1305: fix detection of BMI on AMD64 · b820ef5c
      Lion Yang authored
      This change uses runtime.support_bmi2 as an additional condition
      to examine the usability of AVX2 version algorithm, fixes
      the crash on the platfrom which supports AVX2 but not support BMI2.
      
      Fixes #18512
      
      Change-Id: I408c0844ae2eb242dacf70cb9e8cec1b8f3bd941
      Reviewed-on: https://go-review.googlesource.com/34851Reviewed-by: default avatarIan Lance Taylor <iant@golang.org>
      Run-TryBot: Ian Lance Taylor <iant@golang.org>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      b820ef5c
    • Lion Yang's avatar
      crypto: detect BMI usability on AMD64 for sha1 and sha256 · a2b615d5
      Lion Yang authored
      The existing implementations on AMD64 only detects AVX2 usability,
      when they also contains BMI (bit-manipulation instructions).
      These instructions crash the running program as 'unknown instructions'
      on the architecture, e.g. i3-4000M, which supports AVX2 but not
      support BMI.
      
      This change added the detections for BMI1 and BMI2 to AMD64 runtime with
      two flags as the result, `support_bmi1` and `support_bmi2`,
      in runtime/runtime2.go. It also completed the condition to run AVX2 version
      in packages crypto/sha1 and crypto/sha256.
      
      Fixes #18512
      
      Change-Id: I917bf0de365237740999de3e049d2e8f2a4385ad
      Reviewed-on: https://go-review.googlesource.com/34850Reviewed-by: default avatarIan Lance Taylor <iant@golang.org>
      Run-TryBot: Ian Lance Taylor <iant@golang.org>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      a2b615d5
    • Russ Cox's avatar
      .gitignore: fix attempt at rooted paths · f5608c20
      Russ Cox authored
      When I wrote the lines
      
      	bin/
      	pkg/
      
      I was trying to match just the top-level bin and pkg directories, and I put the
      final slash in because 'git help gitignore' says:
      
             o   If the pattern does not contain a slash /, Git treats it as a shell
                 glob pattern and checks for a match against the pathname relative
                 to the location of the .gitignore file (relative to the toplevel of
                 the work tree if not from a .gitignore file).
      
             o   Otherwise, Git treats the pattern as a shell glob suitable for
                 consumption by fnmatch(3) with the FNM_PATHNAME flag: wildcards in
                 the pattern will not match a / in the pathname. For example,
                 "Documentation/*.html" matches "Documentation/git.html" but not
                 "Documentation/ppc/ppc.html" or
                 "tools/perf/Documentation/perf.html".
      
      Putting a trailing slash was my way of opting in to the "rooted path" semantics
      without looking different from the surrounding rooted paths like "src/go/build/zcgo.go".
      
      But HA HA GIT FOOLED YOU! above those two bullets the docs say:
      
             o   If the pattern ends with a slash, it is removed for the purpose of
                 the following description, ...
      
      Change all the patterns to use a leading slash for "rooted" behavior.
      
      This bit me earlier today because I had a perfectly reasonable source
      code directory go/src/cmd/go/testdata/src/empty/pkg that was
      not added by 'git add empty'.
      
      Change-Id: I6f8685b3c5be22029c33de9ccd735487089a1c03
      Reviewed-on: https://go-review.googlesource.com/34832Reviewed-by: default avatarIan Lance Taylor <iant@golang.org>
      f5608c20
    • Brad Fitzpatrick's avatar
      lib/time: update tzdata to 2016j · c3fc9b4b
      Brad Fitzpatrick authored
      Fixes #18500
      
      Change-Id: I4dddd1b99aecf86b9431b0c14f452152dff9b95a
      Reviewed-on: https://go-review.googlesource.com/34816Reviewed-by: default avatarIan Lance Taylor <iant@golang.org>
      Run-TryBot: Ian Lance Taylor <iant@golang.org>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      c3fc9b4b
    • Kale Blankenship's avatar
      cmd/go: retain test binary when go test is run with -mutexprofile · 2547aec4
      Kale Blankenship authored
      Fixes #18494
      
      Change-Id: I8a190acae6d5f1d20d4e4e4547d84e10e8a7fe68
      Reviewed-on: https://go-review.googlesource.com/34793Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
      Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
      2547aec4
  2. 04 Jan, 2017 6 commits
  3. 03 Jan, 2017 5 commits
  4. 02 Jan, 2017 3 commits
  5. 31 Dec, 2016 1 commit
  6. 30 Dec, 2016 1 commit
  7. 29 Dec, 2016 1 commit
  8. 28 Dec, 2016 1 commit
  9. 24 Dec, 2016 2 commits
  10. 23 Dec, 2016 3 commits
  11. 22 Dec, 2016 4 commits
    • Raul Silvera's avatar
      cmd/pprof: Re-enable weblist and disasm · 8887be46
      Raul Silvera authored
      Previous changes started using the full filename for object files
      on graph nodes, instead of just the file basename. The basename
      was still being used when selecting mappings to disassemble for
      weblist and disasm commands, causing a mismatch.
      
      This fixes #18385. It was already fixed on the upstream pprof.
      
      Change-Id: I1664503634f2c8cd31743561301631f12c4949c9
      Reviewed-on: https://go-review.googlesource.com/34665Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
      Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      8887be46
    • Brad Fitzpatrick's avatar
      net/http: restore Transport's Request.Body byte sniff in limited cases · 6e36811c
      Brad Fitzpatrick authored
      In Go 1.8, we'd removed the Transport's Request.Body
      one-byte-Read-sniffing to disambiguate between non-nil Request.Body
      with a ContentLength of 0 or -1. Previously, we tried to see whether a
      ContentLength of 0 meant actually zero, or just an unset by reading a
      single byte of the Request.Body and then stitching any read byte back
      together with the original Request.Body.
      
      That historically has caused many problems due to either data races,
      blocking forever (#17480), or losing bytes (#17071). Thus, we removed
      it in both HTTP/1 and HTTP/2 in Go 1.8. Unfortunately, during the Go
      1.8 beta, we've found that a few people have gotten bitten by the
      behavior change on requests with methods typically not containing
      request bodies (e.g. GET, HEAD, DELETE). The most popular example is
      the aws-go SDK, which always set http.Request.Body to a non-nil value,
      even on such request methods. That was causing Go 1.8 to send such
      requests with Transfer-Encoding chunked bodies, with zero bytes,
      confusing popular servers (including but limited to AWS).
      
      This CL partially reverts the no-byte-sniffing behavior and restores
      it only for GET/HEAD/DELETE/etc requests, and only when there's no
      Transfer-Encoding set, and the Content-Length is 0 or -1.
      
      Updates #18257 (aws-go) bug
      And also private bug reports about non-AWS issues.
      
      Updates #18407 also, but haven't yet audited things enough to declare
      it fixed.
      
      Change-Id: Ie5284d3e067c181839b31faf637eee56e5738a6a
      Reviewed-on: https://go-review.googlesource.com/34668
      Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      Reviewed-by: default avatarIan Lance Taylor <iant@golang.org>
      6e36811c
    • Elias Naur's avatar
      runtime: skip floating point hardware check on Android · f419b563
      Elias Naur authored
      CL 33652 removed the fake auxv for Android, and replaced it with
      a /proc/self/auxv fallback. When /proc/self/auxv is unreadable,
      however, hardware capabilities detection won't work and the runtime
      will mistakenly think that floating point hardware is unavailable.
      
      Fix this by always assuming floating point hardware on Android.
      
      Manually tested on a Nexus 5 running Android 6.0.1. I suspect the
      android/arm builder has a readable /proc/self/auxv and therefore
      does not trigger the failure mode.
      
      Change-Id: I95c3873803f9e17333c6cb8b9ff2016723104085
      Reviewed-on: https://go-review.googlesource.com/34641Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
      Reviewed-by: default avatarMinux Ma <minux@golang.org>
      Run-TryBot: Elias Naur <elias.naur@gmail.com>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      f419b563
    • Mikio Hara's avatar
      cmd/go: skip flaky TestCgoConsistentResults on FreeBSD · 17190343
      Mikio Hara authored
      FreeBSD 11 or above uses clang-3.6 or higher by default.
      
      Updates #15405.
      
      Change-Id: If49ce298130165f9e1525c7fd0fd5aa39099ad53
      Reviewed-on: https://go-review.googlesource.com/34675Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
      Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      17190343
  12. 21 Dec, 2016 8 commits