{"action":"created","issue":{"url":"https://api.github.com/repos/bem/bem-xjst/issues/496","repository_url":"https://api.github.com/repos/bem/bem-xjst","labels_url":"https://api.github.com/repos/bem/bem-xjst/issues/496/labels{/name}","comments_url":"https://api.github.com/repos/bem/bem-xjst/issues/496/comments","events_url":"https://api.github.com/repos/bem/bem-xjst/issues/496/events","html_url":"https://github.com/bem/bem-xjst/pull/496","id":288991886,"number":496,"title":"bem-xjst: clean cached flags for wrap() and extend() (fix for #495)","user":{"login":"miripiruni","id":144537,"avatar_url":"https://avatars2.githubusercontent.com/u/144537?v=4","gravatar_id":"","url":"https://api.github.com/users/miripiruni","html_url":"https://github.com/miripiruni","followers_url":"https://api.github.com/users/miripiruni/followers","following_url":"https://api.github.com/users/miripiruni/following{/other_user}","gists_url":"https://api.github.com/users/miripiruni/gists{/gist_id}","starred_url":"https://api.github.com/users/miripiruni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miripiruni/subscriptions","organizations_url":"https://api.github.com/users/miripiruni/orgs","repos_url":"https://api.github.com/users/miripiruni/repos","events_url":"https://api.github.com/users/miripiruni/events{/privacy}","received_events_url":"https://api.github.com/users/miripiruni/received_events","type":"User","site_admin":false},"labels":[{"id":263491866,"url":"https://api.github.com/repos/bem/bem-xjst/labels/status:%20review","name":"status: review","color":"ededed","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2018-01-16T17:28:44Z","updated_at":"2018-04-09T11:27:54Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/bem/bem-xjst/pulls/496","html_url":"https://github.com/bem/bem-xjst/pull/496","diff_url":"https://github.com/bem/bem-xjst/pull/496.diff","patch_url":"https://github.com/bem/bem-xjst/pull/496.patch"},"body":"Fixes #495\r\n\r\n### Changes proposed in this pull request\r\n\r\nOn every `templates.apply(bemjson)` call we can use copy of `bemjson`, not the `bemjson` by link.\r\n\r\n### Checklist\r\n\r\n - [x] Tests added\r\n - [x] Benchmark checked\r\n\r\n\r\n```\r\n./lib/compare.py ./dat-10550-4ee9b ./dat-10550-4ee9b/10550d5fa9e1cf54edec5b86e30b261b533488c6-2000-1523269017851.dat ./dat-10550-4ee9b/4ee9bbd2059c6e8dc6627785e591bf9fa3a27a06-2000-1523269032181.dat\r\n/bin/sh: gnuplot: command not found\r\n/bin/sh: gnuplot: command not found\r\nPercentile:  0.5\r\n{ rev1: 4.211397,\r\n  rev2: 4.089813,\r\n  'diff abs': 0.12158399999999947,\r\n  'diff percent': 2.8870229997314256 }\r\n\r\nPercentile:  0.9\r\n{ rev1: 6.285278,\r\n  rev2: 6.214809,\r\n  'diff abs': 0.07046900000000011,\r\n  'diff percent': 1.1211755470482032 }\r\n\r\nPercentile:  0.95\r\n{ rev1: 7.158743,\r\n  rev2: 6.986244,\r\n  'diff abs': 0.17249900000000018,\r\n  'diff percent': 2.4096269414895954 }\r\n```\r\n\r\n\r\n@tadatuta if it looks like production decision for you, I can run benchmarks."},"comment":{"url":"https://api.github.com/repos/bem/bem-xjst/issues/comments/379720289","html_url":"https://github.com/bem/bem-xjst/pull/496#issuecomment-379720289","issue_url":"https://api.github.com/repos/bem/bem-xjst/issues/496","id":379720289,"user":{"login":"miripiruni","id":144537,"avatar_url":"https://avatars2.githubusercontent.com/u/144537?v=4","gravatar_id":"","url":"https://api.github.com/users/miripiruni","html_url":"https://github.com/miripiruni","followers_url":"https://api.github.com/users/miripiruni/followers","following_url":"https://api.github.com/users/miripiruni/following{/other_user}","gists_url":"https://api.github.com/users/miripiruni/gists{/gist_id}","starred_url":"https://api.github.com/users/miripiruni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miripiruni/subscriptions","organizations_url":"https://api.github.com/users/miripiruni/orgs","repos_url":"https://api.github.com/users/miripiruni/repos","events_url":"https://api.github.com/users/miripiruni/events{/privacy}","received_events_url":"https://api.github.com/users/miripiruni/received_events","type":"User","site_admin":false},"created_at":"2018-04-09T11:27:54Z","updated_at":"2018-04-09T11:27:54Z","author_association":"CONTRIBUTOR","body":"@tadatuta \r\n\r\n> How many wrap/extend calls are there in bench templates?\r\n\r\n11. (and ~450 `block()` subpredicates). How many times `wrap()` was matched I don’t know.\r\n\r\n\r\n> 2% slower then previous solution with shallow copy?\r\n> Looks to much for me.\r\n\r\nmeasurement error ~1%. It’s normal measurement error on my macbook with turned off network.\r\n\r\n[After optimisation commit](https://github.com/bem/bem-xjst/pull/496/commits/f3eb9232ce3d6ae88e65fc3d5249b87eb657f9e5) results looks better:\r\n```\r\nrm -fr dat-10550-4ee9b/ && node runner.js --rev1 10550d5fa9e1cf54edec5b86e30b261b533488c6 --rev2 4ee9bbd2059c6e8dc6627785e591bf9fa3a27a06 --bemjson 2000 --dataPath ~/Documents/www/web-data/data --templatePath ./template-8x.js\r\nPercentile:  0.5\r\n{ rev1: 4.059073,\r\n  rev2: 3.991944,\r\n  'diff abs': 0.06712899999999955,\r\n  'diff percent': 1.6538012496941978 }\r\n\r\nPercentile:  0.9\r\n{ rev1: 6.045441,\r\n  rev2: 6.015059,\r\n  'diff abs': 0.030382000000000353,\r\n  'diff percent': 0.5025605245341125 }\r\n\r\nPercentile:  0.95\r\n{ rev1: 7.035301,\r\n  rev2: 6.961316,\r\n  'diff abs': 0.07398499999999952,\r\n  'diff percent': 1.0516252254167857 }\r\n```\r\n\r\nI tend to think of this as an insignificant speed change."}}
{"actor":{"display_login":"miripiruni"}}