{"action":"opened","issue":{"url":"https://api.github.com/repos/golang/go/issues/9862","labels_url":"https://api.github.com/repos/golang/go/issues/9862/labels{/name}","comments_url":"https://api.github.com/repos/golang/go/issues/9862/comments","events_url":"https://api.github.com/repos/golang/go/issues/9862/events","html_url":"https://github.com/golang/go/issues/9862","id":57561926,"number":9862,"title":"Large bss isn't initialized on darwin","user":{"login":"randall77","id":6889504,"avatar_url":"https://avatars.githubusercontent.com/u/6889504?v=3","gravatar_id":"","url":"https://api.github.com/users/randall77","html_url":"https://github.com/randall77","followers_url":"https://api.github.com/users/randall77/followers","following_url":"https://api.github.com/users/randall77/following{/other_user}","gists_url":"https://api.github.com/users/randall77/gists{/gist_id}","starred_url":"https://api.github.com/users/randall77/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/randall77/subscriptions","organizations_url":"https://api.github.com/users/randall77/orgs","repos_url":"https://api.github.com/users/randall77/repos","events_url":"https://api.github.com/users/randall77/events{/privacy}","received_events_url":"https://api.github.com/users/randall77/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-02-13T05:42:06Z","updated_at":"2015-02-13T05:42:06Z","closed_at":null,"body":"The following code prints 2!\r\n\r\n    package main\r\n    var a[1<<31]byte\r\n    func main() {\r\n         println(a[0])\r\n    }\r\n\r\nIt seems that when bss is big, bad things happen on darwin.  At 1<<30, it works (prints 0).  It also fails at 1<<31, 1<<32, 1<<33.  We get a compile error at 1<<31 - 1:\r\n\r\n    runtime.mallocinit: non-pc-relative relocation address is too big: 0x80070dbf\r\n\r\nWe should fail instead of silently generating bad code.\r\n\r\nLinux works correctly: succeeds for up to close to 1<<32, fails with the above error for larger sizes.\r\n"}}