)]}'
{
  "commit": "a5d1a72a40b59db0d2f3f5d3fbb2ed60aafb7fdf",
  "tree": "b6edf8790228d3dfe3381b2d1764b0c1e61b863d",
  "parents": [
    "10c8b2374f413ef6225555893cad5d2a530f77d5"
  ],
  "author": {
    "name": "Ian Lance Taylor",
    "email": "iant@golang.org",
    "time": "Thu May 19 16:27:23 2016 -0700"
  },
  "committer": {
    "name": "Ian Lance Taylor",
    "email": "iant@golang.org",
    "time": "Wed May 25 23:22:24 2016 +0000"
  },
  "message": "cmd/cgo, runtime, runtime/cgo: TSAN support for malloc\n\nAcquire and release the TSAN synchronization point when calling malloc,\njust as we do when calling any other C function. If we don\u0027t do this,\nTSAN will report false positive errors about races calling malloc and\nfree.\n\nWe used to have a special code path for malloc and free, going through\nthe runtime functions cmalloc and cfree. The special code path for cfree\nwas no longer used even before this CL. This CL stops using the special\ncode path for malloc, because there is no place along that path where we\ncould conditionally insert the TSAN synchronization. This CL removes\nthe support for the special code path for both functions.\n\nInstead, cgo now automatically generates the malloc function as though\nit were referenced as C.malloc.  We need to automatically generate it\neven if C.malloc is not called, even if malloc and size_t are not\ndeclared, to support cgo-provided functions like C.CString.\n\nChange-Id: I829854ec0787a80f33fa0a8a0dc2ee1d617830e2\nReviewed-on: https://go-review.googlesource.com/23260\nReviewed-by: Dmitry Vyukov \u003cdvyukov@google.com\u003e\nRun-TryBot: Ian Lance Taylor \u003ciant@golang.org\u003e\nTryBot-Result: Gobot Gobot \u003cgobot@golang.org\u003e\nReviewed-by: Austin Clements \u003caustin@google.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "8718815d3e19c229f7d94607401b124fc730044a",
      "old_mode": 33261,
      "old_path": "misc/cgo/testsanitizers/test.bash",
      "new_id": "c30df3b6c2a5ec72f4f3dd17436e7bb94b8528cc",
      "new_mode": 33261,
      "new_path": "misc/cgo/testsanitizers/test.bash"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "f0c76d84116a6010977c09a531bbc96bf208e1cf",
      "new_mode": 33188,
      "new_path": "misc/cgo/testsanitizers/tsan4.go"
    },
    {
      "type": "modify",
      "old_id": "256b059e57211b2286fad7cb3cd55d95acc8baae",
      "old_mode": 33188,
      "old_path": "src/cmd/cgo/out.go",
      "new_id": "5d6930d3ea402ca09fd9afdefa7f7ebd4d479626",
      "new_mode": 33188,
      "new_path": "src/cmd/cgo/out.go"
    },
    {
      "type": "modify",
      "old_id": "4fb4a613e044d4fdeecba9b3ea96900a3583e994",
      "old_mode": 33188,
      "old_path": "src/runtime/cgo.go",
      "new_id": "9cf7b58a2f7a2ec301f66956a4fe20411c68bf96",
      "new_mode": 33188,
      "new_path": "src/runtime/cgo.go"
    },
    {
      "type": "modify",
      "old_id": "d0f63fb4ff9d74a583f7991554783e64adef9b2a",
      "old_mode": 33188,
      "old_path": "src/runtime/cgo/callbacks.go",
      "new_id": "9bde5a933fcd15da4e1e41031c73c4da01199302",
      "new_mode": 33188,
      "new_path": "src/runtime/cgo/callbacks.go"
    },
    {
      "type": "modify",
      "old_id": "e20d206be6d7996407b9cb84e6118bdff161d270",
      "old_mode": 33188,
      "old_path": "src/runtime/cgo/gcc_util.c",
      "new_id": "4111fe11951df885c29052c6e2a4b634b842bd13",
      "new_mode": 33188,
      "new_path": "src/runtime/cgo/gcc_util.c"
    },
    {
      "type": "modify",
      "old_id": "1e0d4c7f19504a795d38e0f122e88b19650a80bf",
      "old_mode": 33188,
      "old_path": "src/runtime/cgocall.go",
      "new_id": "0f8386b10f54d50e26a569c5acd69f0a8f41e9ff",
      "new_mode": 33188,
      "new_path": "src/runtime/cgocall.go"
    },
    {
      "type": "modify",
      "old_id": "8f98cfa8a4a91157a1fdf96e2ec2bffe51dd6906",
      "old_mode": 33188,
      "old_path": "src/runtime/proc.go",
      "new_id": "ee895471046e62decc2c79b4872433d69a775ad6",
      "new_mode": 33188,
      "new_path": "src/runtime/proc.go"
    }
  ]
}
