{"action":"created","comment":{"url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/comments/60695320","id":60695320,"diff_hunk":"@@ -105,3 +114,76 @@ const Instr_t Factorial[PROGRAM_SIZE] = {\n     Instr_Print,    // n\n     Instr_Halt\n };\n+\n+cpu_t init_cpu () {\n+    cpu_t cpu = {.pc = 0, .sp = -1, .state = Cpu_Running,\n+                 .steps = 0, .stack = {0},\n+                 .pmem = LoadedProgram ? LoadedProgram : DefProgram};\n+    return cpu;\n+}\n+\n+static const char *steplimit_opt = \"--steplimit=\";\n+static const char *inp_prog_opt = \"--inp-prog=\";\n+\n+static inline\n+void help_dump(char * exec_name, int ret_code) {\n+    fprintf(stderr, \"Usage: %s %s<num> %s<str>\\n\", exec_name, steplimit_opt, inp_prog_opt);\n+    exit (2);","path":"common.c","position":45,"original_position":45,"commit_id":"838f815a9c5e48cca4d1d6b7e718be90e00266d7","original_commit_id":"838f815a9c5e48cca4d1d6b7e718be90e00266d7","user":{"login":"grigory-rechistov","id":865468,"avatar_url":"https://avatars.githubusercontent.com/u/865468?v=3","gravatar_id":"","url":"https://api.github.com/users/grigory-rechistov","html_url":"https://github.com/grigory-rechistov","followers_url":"https://api.github.com/users/grigory-rechistov/followers","following_url":"https://api.github.com/users/grigory-rechistov/following{/other_user}","gists_url":"https://api.github.com/users/grigory-rechistov/gists{/gist_id}","starred_url":"https://api.github.com/users/grigory-rechistov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grigory-rechistov/subscriptions","organizations_url":"https://api.github.com/users/grigory-rechistov/orgs","repos_url":"https://api.github.com/users/grigory-rechistov/repos","events_url":"https://api.github.com/users/grigory-rechistov/events{/privacy}","received_events_url":"https://api.github.com/users/grigory-rechistov/received_events","type":"User","site_admin":false},"body":"`ret_code` is passed as argument but is not used!","created_at":"2016-04-22T06:17:35Z","updated_at":"2016-04-22T06:17:35Z","html_url":"https://github.com/grigory-rechistov/interpreters-comparison/pull/18#discussion_r60695320","pull_request_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18","_links":{"self":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/comments/60695320"},"html":{"href":"https://github.com/grigory-rechistov/interpreters-comparison/pull/18#discussion_r60695320"},"pull_request":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18"}}},"pull_request":{"url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18","id":67386398,"html_url":"https://github.com/grigory-rechistov/interpreters-comparison/pull/18","diff_url":"https://github.com/grigory-rechistov/interpreters-comparison/pull/18.diff","patch_url":"https://github.com/grigory-rechistov/interpreters-comparison/pull/18.patch","issue_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/issues/18","number":18,"state":"open","locked":false,"title":"Add ability to load programs from external file.","user":{"login":"Vsevolod-Livinskij","id":3819178,"avatar_url":"https://avatars.githubusercontent.com/u/3819178?v=3","gravatar_id":"","url":"https://api.github.com/users/Vsevolod-Livinskij","html_url":"https://github.com/Vsevolod-Livinskij","followers_url":"https://api.github.com/users/Vsevolod-Livinskij/followers","following_url":"https://api.github.com/users/Vsevolod-Livinskij/following{/other_user}","gists_url":"https://api.github.com/users/Vsevolod-Livinskij/gists{/gist_id}","starred_url":"https://api.github.com/users/Vsevolod-Livinskij/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Vsevolod-Livinskij/subscriptions","organizations_url":"https://api.github.com/users/Vsevolod-Livinskij/orgs","repos_url":"https://api.github.com/users/Vsevolod-Livinskij/repos","events_url":"https://api.github.com/users/Vsevolod-Livinskij/events{/privacy}","received_events_url":"https://api.github.com/users/Vsevolod-Livinskij/received_events","type":"User","site_admin":false},"body":"Commit for issue #11 ","created_at":"2016-04-21T16:45:38Z","updated_at":"2016-04-22T06:17:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a8e5fe66349b3aecd9d6d484275e2d3d7084622b","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18/commits","review_comments_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18/comments","review_comment_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/comments{/number}","comments_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/issues/18/comments","statuses_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/statuses/838f815a9c5e48cca4d1d6b7e718be90e00266d7","head":{"label":"Vsevolod-Livinskij:ext-file","ref":"ext-file","sha":"838f815a9c5e48cca4d1d6b7e718be90e00266d7","user":{"login":"Vsevolod-Livinskij","id":3819178,"avatar_url":"https://avatars.githubusercontent.com/u/3819178?v=3","gravatar_id":"","url":"https://api.github.com/users/Vsevolod-Livinskij","html_url":"https://github.com/Vsevolod-Livinskij","followers_url":"https://api.github.com/users/Vsevolod-Livinskij/followers","following_url":"https://api.github.com/users/Vsevolod-Livinskij/following{/other_user}","gists_url":"https://api.github.com/users/Vsevolod-Livinskij/gists{/gist_id}","starred_url":"https://api.github.com/users/Vsevolod-Livinskij/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Vsevolod-Livinskij/subscriptions","organizations_url":"https://api.github.com/users/Vsevolod-Livinskij/orgs","repos_url":"https://api.github.com/users/Vsevolod-Livinskij/repos","events_url":"https://api.github.com/users/Vsevolod-Livinskij/events{/privacy}","received_events_url":"https://api.github.com/users/Vsevolod-Livinskij/received_events","type":"User","site_admin":false},"repo":{"id":56383470,"name":"interpreters-comparison","full_name":"Vsevolod-Livinskij/interpreters-comparison","owner":{"login":"Vsevolod-Livinskij","id":3819178,"avatar_url":"https://avatars.githubusercontent.com/u/3819178?v=3","gravatar_id":"","url":"https://api.github.com/users/Vsevolod-Livinskij","html_url":"https://github.com/Vsevolod-Livinskij","followers_url":"https://api.github.com/users/Vsevolod-Livinskij/followers","following_url":"https://api.github.com/users/Vsevolod-Livinskij/following{/other_user}","gists_url":"https://api.github.com/users/Vsevolod-Livinskij/gists{/gist_id}","starred_url":"https://api.github.com/users/Vsevolod-Livinskij/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Vsevolod-Livinskij/subscriptions","organizations_url":"https://api.github.com/users/Vsevolod-Livinskij/orgs","repos_url":"https://api.github.com/users/Vsevolod-Livinskij/repos","events_url":"https://api.github.com/users/Vsevolod-Livinskij/events{/privacy}","received_events_url":"https://api.github.com/users/Vsevolod-Livinskij/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Vsevolod-Livinskij/interpreters-comparison","description":"Sample programs for comparison of different VM interpretation techniques","fork":true,"url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison","forks_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/forks","keys_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/teams","hooks_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/hooks","issue_events_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/issues/events{/number}","events_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/events","assignees_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/assignees{/user}","branches_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/branches{/branch}","tags_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/tags","blobs_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/git/refs{/sha}","trees_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/statuses/{sha}","languages_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/languages","stargazers_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/stargazers","contributors_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/contributors","subscribers_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/subscribers","subscription_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/subscription","commits_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/commits{/sha}","git_commits_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/git/commits{/sha}","comments_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/comments{/number}","issue_comment_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/issues/comments{/number}","contents_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/contents/{+path}","compare_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/merges","archive_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/downloads","issues_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/issues{/number}","pulls_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/pulls{/number}","milestones_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/milestones{/number}","notifications_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/labels{/name}","releases_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/releases{/id}","deployments_url":"https://api.github.com/repos/Vsevolod-Livinskij/interpreters-comparison/deployments","created_at":"2016-04-16T12:54:43Z","updated_at":"2016-04-16T12:54:45Z","pushed_at":"2016-04-21T16:43:44Z","git_url":"git://github.com/Vsevolod-Livinskij/interpreters-comparison.git","ssh_url":"git@github.com:Vsevolod-Livinskij/interpreters-comparison.git","clone_url":"https://github.com/Vsevolod-Livinskij/interpreters-comparison.git","svn_url":"https://github.com/Vsevolod-Livinskij/interpreters-comparison","homepage":null,"size":60,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"grigory-rechistov:master","ref":"master","sha":"6bbbe2dcaba9eda4927c1de3cbe6c016ca4d6196","user":{"login":"grigory-rechistov","id":865468,"avatar_url":"https://avatars.githubusercontent.com/u/865468?v=3","gravatar_id":"","url":"https://api.github.com/users/grigory-rechistov","html_url":"https://github.com/grigory-rechistov","followers_url":"https://api.github.com/users/grigory-rechistov/followers","following_url":"https://api.github.com/users/grigory-rechistov/following{/other_user}","gists_url":"https://api.github.com/users/grigory-rechistov/gists{/gist_id}","starred_url":"https://api.github.com/users/grigory-rechistov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grigory-rechistov/subscriptions","organizations_url":"https://api.github.com/users/grigory-rechistov/orgs","repos_url":"https://api.github.com/users/grigory-rechistov/repos","events_url":"https://api.github.com/users/grigory-rechistov/events{/privacy}","received_events_url":"https://api.github.com/users/grigory-rechistov/received_events","type":"User","site_admin":false},"repo":{"id":38712654,"name":"interpreters-comparison","full_name":"grigory-rechistov/interpreters-comparison","owner":{"login":"grigory-rechistov","id":865468,"avatar_url":"https://avatars.githubusercontent.com/u/865468?v=3","gravatar_id":"","url":"https://api.github.com/users/grigory-rechistov","html_url":"https://github.com/grigory-rechistov","followers_url":"https://api.github.com/users/grigory-rechistov/followers","following_url":"https://api.github.com/users/grigory-rechistov/following{/other_user}","gists_url":"https://api.github.com/users/grigory-rechistov/gists{/gist_id}","starred_url":"https://api.github.com/users/grigory-rechistov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/grigory-rechistov/subscriptions","organizations_url":"https://api.github.com/users/grigory-rechistov/orgs","repos_url":"https://api.github.com/users/grigory-rechistov/repos","events_url":"https://api.github.com/users/grigory-rechistov/events{/privacy}","received_events_url":"https://api.github.com/users/grigory-rechistov/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/grigory-rechistov/interpreters-comparison","description":"Sample programs for comparison of different VM interpretation techniques","fork":false,"url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison","forks_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/forks","keys_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/keys{/key_id}","collaborators_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/teams","hooks_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/hooks","issue_events_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/issues/events{/number}","events_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/events","assignees_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/assignees{/user}","branches_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/branches{/branch}","tags_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/tags","blobs_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/git/refs{/sha}","trees_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/git/trees{/sha}","statuses_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/statuses/{sha}","languages_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/languages","stargazers_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/stargazers","contributors_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/contributors","subscribers_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/subscribers","subscription_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/subscription","commits_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/commits{/sha}","git_commits_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/git/commits{/sha}","comments_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/comments{/number}","issue_comment_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/issues/comments{/number}","contents_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/contents/{+path}","compare_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/compare/{base}...{head}","merges_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/merges","archive_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/downloads","issues_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/issues{/number}","pulls_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls{/number}","milestones_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/milestones{/number}","notifications_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/labels{/name}","releases_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/releases{/id}","deployments_url":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/deployments","created_at":"2015-07-07T20:22:30Z","updated_at":"2016-02-10T09:51:06Z","pushed_at":"2016-04-21T16:45:38Z","git_url":"git://github.com/grigory-rechistov/interpreters-comparison.git","ssh_url":"git@github.com:grigory-rechistov/interpreters-comparison.git","clone_url":"https://github.com/grigory-rechistov/interpreters-comparison.git","svn_url":"https://github.com/grigory-rechistov/interpreters-comparison","homepage":null,"size":57,"stargazers_count":8,"watchers_count":8,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":16,"forks":5,"open_issues":16,"watchers":8,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18"},"html":{"href":"https://github.com/grigory-rechistov/interpreters-comparison/pull/18"},"issue":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/issues/18"},"comments":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/issues/18/comments"},"review_comments":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18/comments"},"review_comment":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/pulls/18/commits"},"statuses":{"href":"https://api.github.com/repos/grigory-rechistov/interpreters-comparison/statuses/838f815a9c5e48cca4d1d6b7e718be90e00266d7"}}}}