{"action":"created","issue":{"url":"https://api.github.com/repos/k-takata/Onigmo/issues/52","labels_url":"https://api.github.com/repos/k-takata/Onigmo/issues/52/labels{/name}","comments_url":"https://api.github.com/repos/k-takata/Onigmo/issues/52/comments","events_url":"https://api.github.com/repos/k-takata/Onigmo/issues/52/events","html_url":"https://github.com/k-takata/Onigmo/pull/52","id":80578210,"number":52,"title":"Implement Direct Threaded VM described in #51. Improving ~49%.","user":{"login":"KeenS","id":4434568,"avatar_url":"https://avatars.githubusercontent.com/u/4434568?v=3","gravatar_id":"","url":"https://api.github.com/users/KeenS","html_url":"https://github.com/KeenS","followers_url":"https://api.github.com/users/KeenS/followers","following_url":"https://api.github.com/users/KeenS/following{/other_user}","gists_url":"https://api.github.com/users/KeenS/gists{/gist_id}","starred_url":"https://api.github.com/users/KeenS/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KeenS/subscriptions","organizations_url":"https://api.github.com/users/KeenS/orgs","repos_url":"https://api.github.com/users/KeenS/repos","events_url":"https://api.github.com/users/KeenS/events{/privacy}","received_events_url":"https://api.github.com/users/KeenS/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-05-25T15:55:05Z","updated_at":"2015-07-28T02:42:30Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/k-takata/Onigmo/pulls/52","html_url":"https://github.com/k-takata/Onigmo/pull/52","diff_url":"https://github.com/k-takata/Onigmo/pull/52.diff","patch_url":"https://github.com/k-takata/Onigmo/pull/52.patch"},"body":"Here are benchmark scores. Benchmark suite is derived form http://sljit.sourceforge.net/regex_perf.html.\r\n\r\n<table>\r\n    <tr><td></td><td>Master</td><td>This PR</td><td>Improve Rate</td></tr>\r\n    <tr><td class=\"pattern\">Twain</td><td class=\"time\">47 ms</td><td class=\"time\">47 ms</td><td>0%</td></tr>\r\n    <tr><td class=\"pattern\">^Twain</td><td class=\"time\">47 ms</td><td class=\"time\">47 ms</td><td>0%</td></tr>\r\n    <tr><td class=\"pattern\">Twain$</td><td class=\"time\">47 ms</td><td class=\"time\">47 ms</td><td>0%</td></tr>\r\n    <tr><td class=\"pattern\">Huck[a-zA-Z]+|Finn[a-zA-Z]+</td><td class=\"time\">127 ms</td><td class=\"time\">127 ms</td><td>0%</td></tr>\r\n    <tr><td class=\"pattern\">a[^x]{20}b</td><td class=\"time\">1172 ms</td><td class=\"time\">889 ms</td><td>31%</td></tr>\r\n    <tr><td class=\"pattern\">Tom|Sawyer|Huckleberry|Finn</td><td class=\"time\">151 ms</td><td class=\"time\">153 ms</td><td>-1%</td></tr>\r\n    <tr><td class=\"pattern\">.{0,3}(Tom|Sawyer|Huckleberry|Finn)</td><td class=\"time\">497 ms</td><td class=\"time\">449 ms</td><td>10%</td></tr>\r\n    <tr><td class=\"pattern\">[a-zA-Z]+ing</td><td class=\"time\">4032 ms</td><td class=\"time\">2705 ms</td><td>49%</td></tr>\r\n    <tr><td class=\"pattern\">^[a-zA-Z]{0,4}ing[^a-zA-Z]</td><td class=\"time\">96 ms</td><td class=\"time\">98 ms</td><td>-2%</td></tr>\r\n    <tr><td class=\"pattern\">[a-zA-Z]+ing$</td><td class=\"time\">4175 ms</td><td class=\"time\">2797 ms</td><td>49%</td></tr>\r\n    <tr><td class=\"pattern\">^[a-zA-Z ]{5,}$</td><td class=\"time\">1770 ms</td><td class=\"time\">1623 ms</td><td>9%</td></tr>\r\n    <tr><td class=\"pattern\">^.{16,20}$</td><td class=\"time\">1757 ms</td><td class=\"time\">1637 ms</td><td>7%</td></tr>\r\n    <tr><td class=\"pattern\">([a-f](.[d-m].){0,2}[h-n]){2}</td><td class=\"time\">1849 ms</td><td class=\"time\">1670 ms</td><td>11%</td></tr>\r\n    <tr><td class=\"pattern\">([A-Za-z]awyer|[A-Za-z]inn)[^a-zA-Z]</td><td class=\"time\">656 ms</td><td class=\"time\">607 ms</td><td>8%</td></tr>\r\n    <tr><td class=\"pattern\">\"[^\"]{0,30}[?!\\.]\"</td><td class=\"time\">115 ms</td><td class=\"time\">93 ms</td><td>24%</td></tr>\r\n    <tr><td class=\"pattern\">Tom.{10,25}river|river.{10,25}Tom</td><td class=\"time\">260 ms</td><td class=\"time\">262 ms</td><td>-1%</td></tr>\r\n</table>\r\n\r\nEnv:\r\n```\r\n$ uname -a\r\nLinux Dynabook 3.19.0-18-generic #18-Ubuntu SMP Tue May 19 18:31:35 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux\r\n\r\n$ cat /proc/cpuinfo\r\nprocessor\t: 0\r\nvendor_id\t: GenuineIntel\r\ncpu family\t: 6\r\nmodel\t\t: 37\r\nmodel name\t: Intel(R) Core(TM) i5 CPU       M 450  @ 2.40GHz\r\nstepping\t: 5\r\nmicrocode\t: 0x2\r\ncpu MHz\t\t: 1199.000\r\ncache size\t: 3072 KB\r\nphysical id\t: 0\r\nsiblings\t: 4\r\ncore id\t\t: 0\r\ncpu cores\t: 2\r\napicid\t\t: 0\r\ninitial apicid\t: 0\r\nfpu\t\t: yes\r\nfpu_exception\t: yes\r\ncpuid level\t: 11\r\nwp\t\t: yes\r\nflags\t\t: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est tm2 ssse3 cx16 xtpr pdcm pcid sse4_1 sse4_2 popcnt lahf_lm ida arat dtherm tpr_shadow vnmi flexpriority ept vpid\r\nbugs\t\t:\r\nbogomips\t: 4788.65\r\nclflush size\t: 64\r\ncache_alignment\t: 64\r\naddress sizes\t: 36 bits physical, 48 bits virtual\r\npower management:\r\n\r\nprocessor\t: 1\r\nvendor_id\t: GenuineIntel\r\ncpu family\t: 6\r\nmodel\t\t: 37\r\nmodel name\t: Intel(R) Core(TM) i5 CPU       M 450  @ 2.40GHz\r\nstepping\t: 5\r\nmicrocode\t: 0x2\r\ncpu MHz\t\t: 1199.000\r\ncache size\t: 3072 KB\r\nphysical id\t: 0\r\nsiblings\t: 4\r\ncore id\t\t: 0\r\ncpu cores\t: 2\r\napicid\t\t: 1\r\ninitial apicid\t: 1\r\nfpu\t\t: yes\r\nfpu_exception\t: yes\r\ncpuid level\t: 11\r\nwp\t\t: yes\r\nflags\t\t: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est tm2 ssse3 cx16 xtpr pdcm pcid sse4_1 sse4_2 popcnt lahf_lm ida arat dtherm tpr_shadow vnmi flexpriority ept vpid\r\nbugs\t\t:\r\nbogomips\t: 4788.65\r\nclflush size\t: 64\r\ncache_alignment\t: 64\r\naddress sizes\t: 36 bits physical, 48 bits virtual\r\npower management:\r\n\r\nprocessor\t: 2\r\nvendor_id\t: GenuineIntel\r\ncpu family\t: 6\r\nmodel\t\t: 37\r\nmodel name\t: Intel(R) Core(TM) i5 CPU       M 450  @ 2.40GHz\r\nstepping\t: 5\r\nmicrocode\t: 0x2\r\ncpu MHz\t\t: 2133.000\r\ncache size\t: 3072 KB\r\nphysical id\t: 0\r\nsiblings\t: 4\r\ncore id\t\t: 2\r\ncpu cores\t: 2\r\napicid\t\t: 4\r\ninitial apicid\t: 4\r\nfpu\t\t: yes\r\nfpu_exception\t: yes\r\ncpuid level\t: 11\r\nwp\t\t: yes\r\nflags\t\t: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est tm2 ssse3 cx16 xtpr pdcm pcid sse4_1 sse4_2 popcnt lahf_lm ida arat dtherm tpr_shadow vnmi flexpriority ept vpid\r\nbugs\t\t:\r\nbogomips\t: 4788.65\r\nclflush size\t: 64\r\ncache_alignment\t: 64\r\naddress sizes\t: 36 bits physical, 48 bits virtual\r\npower management:\r\n\r\nprocessor\t: 3\r\nvendor_id\t: GenuineIntel\r\ncpu family\t: 6\r\nmodel\t\t: 37\r\nmodel name\t: Intel(R) Core(TM) i5 CPU       M 450  @ 2.40GHz\r\nstepping\t: 5\r\nmicrocode\t: 0x2\r\ncpu MHz\t\t: 1199.000\r\ncache size\t: 3072 KB\r\nphysical id\t: 0\r\nsiblings\t: 4\r\ncore id\t\t: 2\r\ncpu cores\t: 2\r\napicid\t\t: 5\r\ninitial apicid\t: 5\r\nfpu\t\t: yes\r\nfpu_exception\t: yes\r\ncpuid level\t: 11\r\nwp\t\t: yes\r\nflags\t\t: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology nonstop_tsc aperfmperf pni dtes64 monitor ds_cpl vmx est tm2 ssse3 cx16 xtpr pdcm pcid sse4_1 sse4_2 popcnt lahf_lm ida arat dtherm tpr_shadow vnmi flexpriority ept vpid\r\nbugs\t\t:\r\nbogomips\t: 4788.65\r\nclflush size\t: 64\r\ncache_alignment\t: 64\r\naddress sizes\t: 36 bits physical, 48 bits virtual\r\npower management:\r\n\r\n$ cat /proc/meminfo\r\nMemTotal:        7965524 kB\r\nMemFree:         6007232 kB\r\nMemAvailable:    6635616 kB\r\nBuffers:          147344 kB\r\nCached:           791320 kB\r\nSwapCached:            0 kB\r\nActive:          1170092 kB\r\nInactive:         614612 kB\r\nActive(anon):     848752 kB\r\nInactive(anon):   164980 kB\r\nActive(file):     321340 kB\r\nInactive(file):   449632 kB\r\nUnevictable:          64 kB\r\nMlocked:              64 kB\r\nSwapTotal:             0 kB\r\nSwapFree:              0 kB\r\nDirty:               856 kB\r\nWriteback:             0 kB\r\nAnonPages:        846212 kB\r\nMapped:           257944 kB\r\nShmem:            167692 kB\r\nSlab:              81000 kB\r\nSReclaimable:      52676 kB\r\nSUnreclaim:        28324 kB\r\nKernelStack:        7824 kB\r\nPageTables:        27924 kB\r\nNFS_Unstable:          0 kB\r\nBounce:                0 kB\r\nWritebackTmp:          0 kB\r\nCommitLimit:     3982760 kB\r\nCommitted_AS:    4154020 kB\r\nVmallocTotal:   34359738367 kB\r\nVmallocUsed:      551880 kB\r\nVmallocChunk:   34359178716 kB\r\nHardwareCorrupted:     0 kB\r\nAnonHugePages:    327680 kB\r\nCmaTotal:              0 kB\r\nCmaFree:               0 kB\r\nHugePages_Total:       0\r\nHugePages_Free:        0\r\nHugePages_Rsvd:        0\r\nHugePages_Surp:        0\r\nHugepagesize:       2048 kB\r\nDirectMap4k:       99392 kB\r\nDirectMap2M:     8079360 kB\r\n\r\n$ gcc --version\r\ngcc (Ubuntu 4.9.2-10ubuntu13) 4.9.2\r\nCopyright (C) 2014 Free Software Foundation, Inc.\r\nThis is free software; see the source for copying conditions.  There is NO\r\nwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\r\n\r\n```"},"comment":{"url":"https://api.github.com/repos/k-takata/Onigmo/issues/comments/125416098","html_url":"https://github.com/k-takata/Onigmo/pull/52#issuecomment-125416098","issue_url":"https://api.github.com/repos/k-takata/Onigmo/issues/52","id":125416098,"user":{"login":"k-takata","id":840186,"avatar_url":"https://avatars.githubusercontent.com/u/840186?v=3","gravatar_id":"","url":"https://api.github.com/users/k-takata","html_url":"https://github.com/k-takata","followers_url":"https://api.github.com/users/k-takata/followers","following_url":"https://api.github.com/users/k-takata/following{/other_user}","gists_url":"https://api.github.com/users/k-takata/gists{/gist_id}","starred_url":"https://api.github.com/users/k-takata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k-takata/subscriptions","organizations_url":"https://api.github.com/users/k-takata/orgs","repos_url":"https://api.github.com/users/k-takata/repos","events_url":"https://api.github.com/users/k-takata/events{/privacy}","received_events_url":"https://api.github.com/users/k-takata/received_events","type":"User","site_admin":false},"created_at":"2015-07-28T02:42:30Z","updated_at":"2015-07-28T02:42:30Z","body":"Thank you for the information.\r\nI think this is very useful, but I haven't tried yet."}}