{"action":"created","issue":{"url":"https://api.github.com/repos/andrewthad/haskell-ip/issues/40","repository_url":"https://api.github.com/repos/andrewthad/haskell-ip","labels_url":"https://api.github.com/repos/andrewthad/haskell-ip/issues/40/labels{/name}","comments_url":"https://api.github.com/repos/andrewthad/haskell-ip/issues/40/comments","events_url":"https://api.github.com/repos/andrewthad/haskell-ip/issues/40/events","html_url":"https://github.com/andrewthad/haskell-ip/pull/40","id":335800799,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk3NDA4NDA4","number":40,"title":"Improve IPv6 parser performance/simplicity","user":{"login":"Porges","id":12575,"node_id":"MDQ6VXNlcjEyNTc1","avatar_url":"https://avatars3.githubusercontent.com/u/12575?v=4","gravatar_id":"","url":"https://api.github.com/users/Porges","html_url":"https://github.com/Porges","followers_url":"https://api.github.com/users/Porges/followers","following_url":"https://api.github.com/users/Porges/following{/other_user}","gists_url":"https://api.github.com/users/Porges/gists{/gist_id}","starred_url":"https://api.github.com/users/Porges/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Porges/subscriptions","organizations_url":"https://api.github.com/users/Porges/orgs","repos_url":"https://api.github.com/users/Porges/repos","events_url":"https://api.github.com/users/Porges/events{/privacy}","received_events_url":"https://api.github.com/users/Porges/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-06-26T12:41:21Z","updated_at":"2018-07-25T11:43:17Z","closed_at":"2018-07-16T20:21:39Z","author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/andrewthad/haskell-ip/pulls/40","html_url":"https://github.com/andrewthad/haskell-ip/pull/40","diff_url":"https://github.com/andrewthad/haskell-ip/pull/40.diff","patch_url":"https://github.com/andrewthad/haskell-ip/pull/40.patch"},"body":"Since performance was slightly worsened by #37, I did some work to both simplify the IPv6 parser for understandability, and to make it faster.\r\n\r\nAll the main cases are now faster than the pre-#37 parser.\r\n\r\nHere are the benchmark differences for this PR:\r\n\r\n```\r\nbenchmarking IPv6 from Text/New '::'\r\ntime                 94.52 ns   (92.94 ns .. 96.27 ns)\r\n                     0.996 R²   (0.994 R² .. 0.998 R²)\r\nmean                 97.46 ns   (95.18 ns .. 102.9 ns)\r\nstd dev              11.55 ns   (7.396 ns .. 19.11 ns)\r\nvariance introduced by outliers: 93% (severely inflated)\r\n\r\nbenchmarking IPv6 from Text/Old '::'\r\ntime                 106.2 ns   (104.4 ns .. 108.9 ns)\r\n                     0.995 R²   (0.991 R² .. 0.998 R²)\r\nmean                 109.2 ns   (106.6 ns .. 113.9 ns)\r\nstd dev              11.28 ns   (7.229 ns .. 16.38 ns)\r\nvariance introduced by outliers: 91% (severely inflated)\r\n\r\nbenchmarking IPv6 from Text/New '1:2:3:4:5:6:7:8'\r\ntime                 570.5 ns   (566.2 ns .. 576.0 ns)\r\n                     0.998 R²   (0.995 R² .. 0.999 R²)\r\nmean                 594.5 ns   (580.0 ns .. 630.7 ns)\r\nstd dev              75.65 ns   (45.32 ns .. 124.5 ns)\r\nvariance introduced by outliers: 93% (severely inflated)\r\n\r\nbenchmarking IPv6 from Text/Old '1:2:3:4:5:6:7:8'\r\ntime                 954.7 ns   (946.1 ns .. 963.0 ns)\r\n                     0.999 R²   (0.999 R² .. 1.000 R²)\r\nmean                 949.7 ns   (944.2 ns .. 955.7 ns)\r\nstd dev              19.29 ns   (16.17 ns .. 23.61 ns)\r\nvariance introduced by outliers: 24% (moderately inflated)\r\n\r\nbenchmarking IPv6 from Text/New '1:2::7:8'\r\ntime                 438.6 ns   (435.6 ns .. 441.9 ns)\r\n                     1.000 R²   (0.999 R² .. 1.000 R²)\r\nmean                 439.3 ns   (436.9 ns .. 441.6 ns)\r\nstd dev              7.777 ns   (6.695 ns .. 9.178 ns)\r\nvariance introduced by outliers: 21% (moderately inflated)\r\n\r\nbenchmarking IPv6 from Text/Old '1:2::7:8'\r\ntime                 547.8 ns   (543.4 ns .. 552.9 ns)\r\n                     0.999 R²   (0.999 R² .. 1.000 R²)\r\nmean                 547.1 ns   (543.8 ns .. 553.6 ns)\r\nstd dev              14.48 ns   (9.083 ns .. 27.68 ns)\r\nvariance introduced by outliers: 36% (moderately inflated)\r\n\r\nbenchmarking IPv6 from Text/New 'a:b::c:d'\r\ntime                 371.7 ns   (368.4 ns .. 375.7 ns)\r\n                     0.999 R²   (0.999 R² .. 1.000 R²)\r\nmean                 370.5 ns   (368.2 ns .. 373.3 ns)\r\nstd dev              8.435 ns   (6.527 ns .. 12.45 ns)\r\nvariance introduced by outliers: 30% (moderately inflated)\r\n\r\nbenchmarking IPv6 from Text/Old 'a:b::c:d'\r\ntime                 428.0 ns   (425.4 ns .. 431.2 ns)\r\n                     1.000 R²   (0.999 R² .. 1.000 R²)\r\nmean                 428.8 ns   (426.9 ns .. 430.7 ns)\r\nstd dev              6.405 ns   (5.121 ns .. 8.273 ns)\r\nvariance introduced by outliers: 15% (moderately inflated)\r\n```"},"comment":{"url":"https://api.github.com/repos/andrewthad/haskell-ip/issues/comments/407725819","html_url":"https://github.com/andrewthad/haskell-ip/pull/40#issuecomment-407725819","issue_url":"https://api.github.com/repos/andrewthad/haskell-ip/issues/40","id":407725819,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNzcyNTgxOQ==","user":{"login":"Porges","id":12575,"node_id":"MDQ6VXNlcjEyNTc1","avatar_url":"https://avatars3.githubusercontent.com/u/12575?v=4","gravatar_id":"","url":"https://api.github.com/users/Porges","html_url":"https://github.com/Porges","followers_url":"https://api.github.com/users/Porges/followers","following_url":"https://api.github.com/users/Porges/following{/other_user}","gists_url":"https://api.github.com/users/Porges/gists{/gist_id}","starred_url":"https://api.github.com/users/Porges/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Porges/subscriptions","organizations_url":"https://api.github.com/users/Porges/orgs","repos_url":"https://api.github.com/users/Porges/repos","events_url":"https://api.github.com/users/Porges/events{/privacy}","received_events_url":"https://api.github.com/users/Porges/received_events","type":"User","site_admin":false},"created_at":"2018-07-25T11:43:17Z","updated_at":"2018-07-25T11:43:17Z","author_association":"CONTRIBUTOR","body":"Belated thanks! 🙂 "}}
{"actor":{"display_login":"Porges"}}