{"action":"closed","issue":{"url":"https://api.github.com/repos/dotnet/coreclr/issues/3251","repository_url":"https://api.github.com/repos/dotnet/coreclr","labels_url":"https://api.github.com/repos/dotnet/coreclr/issues/3251/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/coreclr/issues/3251/comments","events_url":"https://api.github.com/repos/dotnet/coreclr/issues/3251/events","html_url":"https://github.com/dotnet/coreclr/issues/3251","id":134850196,"number":3251,"title":"GC Tests : Red Black Tree does not correctly implement a red black tree","user":{"login":"mjp41","id":270363,"avatar_url":"https://avatars.githubusercontent.com/u/270363?v=3","gravatar_id":"","url":"https://api.github.com/users/mjp41","html_url":"https://github.com/mjp41","followers_url":"https://api.github.com/users/mjp41/followers","following_url":"https://api.github.com/users/mjp41/following{/other_user}","gists_url":"https://api.github.com/users/mjp41/gists{/gist_id}","starred_url":"https://api.github.com/users/mjp41/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mjp41/subscriptions","organizations_url":"https://api.github.com/users/mjp41/orgs","repos_url":"https://api.github.com/users/mjp41/repos","events_url":"https://api.github.com/users/mjp41/events{/privacy}","received_events_url":"https://api.github.com/users/mjp41/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/dotnet/coreclr/milestones/4","html_url":"https://github.com/dotnet/coreclr/milestones/1.0.0-rtm","labels_url":"https://api.github.com/repos/dotnet/coreclr/milestones/4/labels","id":1321405,"number":4,"title":"1.0.0-rtm","description":"2016 (https://github.com/dotnet/corefx/milestones)","creator":{"login":"joshfree","id":1302850,"avatar_url":"https://avatars.githubusercontent.com/u/1302850?v=3","gravatar_id":"","url":"https://api.github.com/users/joshfree","html_url":"https://github.com/joshfree","followers_url":"https://api.github.com/users/joshfree/followers","following_url":"https://api.github.com/users/joshfree/following{/other_user}","gists_url":"https://api.github.com/users/joshfree/gists{/gist_id}","starred_url":"https://api.github.com/users/joshfree/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joshfree/subscriptions","organizations_url":"https://api.github.com/users/joshfree/orgs","repos_url":"https://api.github.com/users/joshfree/repos","events_url":"https://api.github.com/users/joshfree/events{/privacy}","received_events_url":"https://api.github.com/users/joshfree/received_events","type":"User","site_admin":false},"open_issues":143,"closed_issues":77,"state":"open","created_at":"2015-09-24T02:23:52Z","updated_at":"2016-03-11T17:58:25Z","due_on":"2016-06-30T07:00:00Z","closed_at":null},"comments":1,"created_at":"2016-02-19T12:09:37Z","updated_at":"2016-03-11T17:58:25Z","closed_at":"2016-03-11T17:58:25Z","body":"The red black tree in the GC Stress tests does not correctly implement a red/black tree.  There are at least two bugs:\r\n\r\n1) The parent point is not updated in this rotation case: [https://github.com/dotnet/coreclr/blob/master/tests/src/GC/Stress/Tests/RedBlackTree.cs#L239-L268](https://github.com/dotnet/coreclr/blob/master/tests/src/GC/Stress/Tests/RedBlackTree.cs#L239-L268)\r\n\r\n2) One of the rotation cases, doesn't perform rotation, and thus breaks the red node with red child invariant. \r\n[https://github.com/dotnet/coreclr/blob/master/tests/src/GC/Stress/Tests/RedBlackTree.cs#L274-L289](https://github.com/dotnet/coreclr/blob/master/tests/src/GC/Stress/Tests/RedBlackTree.cs#L274-L289)\r\n\r\nThe second leads to the tree not being balanced, which probably does not mater for the GC benchmarking, but the first leads to objects being live longer than they should be."}}