{"action":"created","issue":{"url":"https://api.github.com/repos/JuliaLang/julia/issues/28075","repository_url":"https://api.github.com/repos/JuliaLang/julia","labels_url":"https://api.github.com/repos/JuliaLang/julia/issues/28075/labels{/name}","comments_url":"https://api.github.com/repos/JuliaLang/julia/issues/28075/comments","events_url":"https://api.github.com/repos/JuliaLang/julia/issues/28075/events","html_url":"https://github.com/JuliaLang/julia/pull/28075","id":340552420,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAwOTM1MTEy","number":28075,"title":"Make julia + repl start twice as fast [do not merge]","user":{"login":"KristofferC","id":1282691,"node_id":"MDQ6VXNlcjEyODI2OTE=","avatar_url":"https://avatars1.githubusercontent.com/u/1282691?v=4","gravatar_id":"","url":"https://api.github.com/users/KristofferC","html_url":"https://github.com/KristofferC","followers_url":"https://api.github.com/users/KristofferC/followers","following_url":"https://api.github.com/users/KristofferC/following{/other_user}","gists_url":"https://api.github.com/users/KristofferC/gists{/gist_id}","starred_url":"https://api.github.com/users/KristofferC/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KristofferC/subscriptions","organizations_url":"https://api.github.com/users/KristofferC/orgs","repos_url":"https://api.github.com/users/KristofferC/repos","events_url":"https://api.github.com/users/KristofferC/events{/privacy}","received_events_url":"https://api.github.com/users/KristofferC/received_events","type":"User","site_admin":false},"labels":[{"id":240125929,"node_id":"MDU6TGFiZWwyNDAxMjU5Mjk=","url":"https://api.github.com/repos/JuliaLang/julia/labels/precompile","name":"precompile","color":"fad8c7","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2018-07-12T09:10:09Z","updated_at":"2018-07-13T09:17:25Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/JuliaLang/julia/pulls/28075","html_url":"https://github.com/JuliaLang/julia/pull/28075","diff_url":"https://github.com/JuliaLang/julia/pull/28075.diff","patch_url":"https://github.com/JuliaLang/julia/pull/28075.patch"},"body":"I compiled julia with `#define TRACE_COMPILE`, started `./julia 2 > precompile.txt`, copy pasted the output into `precompile.jl`. Note that anonymous functions are kept. I recorded time to start julia, and also recorded the number of frames (60 FPS) until the banner and prompt showed.\r\n\r\n#### Before PR:\r\n\r\n```\r\n➜  time ./julia -e 1+1\r\n./julia -e 1+1  0.38s user 0.14s system 149% cpu 0.352 total\r\n➜  time ./julia -e 1+1\r\n./julia -e 1+1  0.38s user 0.14s system 149% cpu 0.347 total\r\n➜  time ./julia -e 1+1\r\n./julia -e 1+1  0.39s user 0.15s system 149% cpu 0.359 total\r\n```\r\n\r\n```\r\n14 frames banner\r\n32 frames prompt\r\n```\r\n\r\n#### After PR\r\n\r\n```\r\n➜ time ./julia -e 1+1\r\n./julia -e 1+1  0.22s user 0.12s system 113% cpu 0.293 total\r\n➜ time ./julia -e 1+1\r\n./julia -e 1+1  0.21s user 0.12s system 113% cpu 0.292 total\r\n➜  time ./julia -e 1+1\r\n./julia -e 1+1  0.22s user 0.11s system 111% cpu 0.289 total\r\n```\r\n\r\n```\r\n13 frames banner\r\n17 frames prompt\r\n```\r\n\r\n#### 0.6.4\r\n\r\n```\r\n➜  time julia -e 1+1\r\njulia -e 1+1  0.31s user 0.11s system 122% cpu 0.339 total\r\n➜ time julia -e 1+1\r\njulia -e 1+1  0.30s user 0.10s system 123% cpu 0.328 total\r\n➜  time julia -e 1+1\r\njulia -e 1+1  0.30s user 0.10s system 121% cpu 0.335 total\r\n```\r\n\r\n```\r\n12 frames banner\r\n27 frames prompt\r\n```\r\n\r\n\r\n----------------------\r\n\r\nSo ` time ./julia -e 1+1` is approx 70% faster, and the time until the REPL prompt shows is approx 90% faster with this PR vs master. Also significantly faster vs 0.6.\r\n\r\n— But won't these anonymous functions go stale quickly?\r\n— Yeah maybe, but let's just have them in for the release then, and then revert the commit or something.\r\n\r\n— But won't these anonymous functions be different on different systems?\r\n— Yeah, if different functions are defined on different systems, the precompile list from one system is not directly transferable. Needs something like https://github.com/JuliaLang/julia/issues/26503 to deal with that.\r\n\r\nI also have a commit that does the same thing, but in addition, does some moving around in the REPL and it feels awesome to use. But one thing at a time."},"comment":{"url":"https://api.github.com/repos/JuliaLang/julia/issues/comments/404776948","html_url":"https://github.com/JuliaLang/julia/pull/28075#issuecomment-404776948","issue_url":"https://api.github.com/repos/JuliaLang/julia/issues/28075","id":404776948,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNDc3Njk0OA==","user":{"login":"KristofferC","id":1282691,"node_id":"MDQ6VXNlcjEyODI2OTE=","avatar_url":"https://avatars1.githubusercontent.com/u/1282691?v=4","gravatar_id":"","url":"https://api.github.com/users/KristofferC","html_url":"https://github.com/KristofferC","followers_url":"https://api.github.com/users/KristofferC/followers","following_url":"https://api.github.com/users/KristofferC/following{/other_user}","gists_url":"https://api.github.com/users/KristofferC/gists{/gist_id}","starred_url":"https://api.github.com/users/KristofferC/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KristofferC/subscriptions","organizations_url":"https://api.github.com/users/KristofferC/orgs","repos_url":"https://api.github.com/users/KristofferC/repos","events_url":"https://api.github.com/users/KristofferC/events{/privacy}","received_events_url":"https://api.github.com/users/KristofferC/received_events","type":"User","site_admin":false},"created_at":"2018-07-13T09:17:25Z","updated_at":"2018-07-13T09:17:25Z","author_association":"CONTRIBUTOR","body":"A short animation of starting + restarting julia with this PR and then with the beta:\r\n\r\nhttps://asciinema.org/a/hMmHsdvVxqhQTkcO60uz1c23U"}}
{"actor":{"display_login":"KristofferC"}}