commit | 27d1f3031197428b5745d09c167f982d638b8776 | [log] [tgz] |
---|---|---|
author | Ian Lance Taylor <iant@golang.org> | Thu Sep 26 23:12:44 2019 -0700 |
committer | Ian Lance Taylor <iant@golang.org> | Fri Sep 27 17:34:24 2019 +0000 |
tree | 52697d814d0d0fa7f4a19db456c0d7f24e8beeb8 | |
parent | d1fa6c34e56eade6fb5b6291f0a727b1a12bf6f1 [diff] |
compiler: only check whether struct or array types are big Fetching the size of a type typically involves a hash table lookup, and is generally non-trivial. The escape analysis code calls is_big more than one might expect. So only fetch the size if we need it. Change-Id: I44f28030f75c3e993020932631eea46fc6158b30 Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/197699 Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Cherry Zhang <cherryyz@google.com>