aboutsummaryrefslogtreecommitdiff
path: root/libgo/go
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@google.com>2012-11-29 18:11:17 +0000
committerIan Lance Taylor <ian@gcc.gnu.org>2012-11-29 18:11:17 +0000
commit744c3195ef778200a0acfc4779e3f2d48237bbf1 (patch)
treed146677ebcdb05c9d7a8c8b84cab5fb7fa9a0f99 /libgo/go
parent53750ab003876bae145f36431392e2531e70e7cc (diff)
downloadgcc-744c3195ef778200a0acfc4779e3f2d48237bbf1.zip
gcc-744c3195ef778200a0acfc4779e3f2d48237bbf1.tar.gz
gcc-744c3195ef778200a0acfc4779e3f2d48237bbf1.tar.bz2
compiler, runtime: Track fields with tag go:"track".
* go-gcc.cc: Include "output.h". (global_variable): Add is_unique_section parameter. (global_variable_set_init): Adjust unique section if necessary. * Make-lang.in (go/go-gcc.o): Add dependency on output.h. From-SVN: r193945
Diffstat (limited to 'libgo/go')
-rw-r--r--libgo/go/runtime/debug.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/libgo/go/runtime/debug.go b/libgo/go/runtime/debug.go
index 0211ce6..9da71a7 100644
--- a/libgo/go/runtime/debug.go
+++ b/libgo/go/runtime/debug.go
@@ -168,3 +168,10 @@ func BlockProfile(p []BlockProfileRecord) (n int, ok bool)
// If all is true, Stack formats stack traces of all other goroutines
// into buf after the trace for the current goroutine.
func Stack(buf []byte, all bool) int
+
+// Get field tracking information. Only fields with a tag go:"track"
+// are tracked. This function will add every such field that is
+// referenced to the map. The keys in the map will be
+// PkgPath.Name.FieldName. The value will be true for each field
+// added.
+func Fieldtrack(map[string]bool)