{"id":16952942,"url":"https://github.com/crenshaw-dev/cpusim","last_synced_at":"2026-04-29T06:36:44.569Z","repository":{"id":104979505,"uuid":"87452591","full_name":"crenshaw-dev/CPUsim","owner":"crenshaw-dev","description":"A very simple CPU simulator in Python","archived":false,"fork":false,"pushed_at":"2017-04-06T16:42:55.000Z","size":19,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-21T11:21:21.720Z","etag":null,"topics":["compiler","lexer"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/crenshaw-dev.png","metadata":{"files":{"readme":"README","changelog":null,"contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-04-06T16:42:21.000Z","updated_at":"2023-01-30T04:56:18.000Z","dependencies_parsed_at":null,"dependency_job_id":"6c2eaf32-aaab-49f7-8b01-3765cd797b6f","html_url":"https://github.com/crenshaw-dev/CPUsim","commit_stats":{"total_commits":1,"total_committers":1,"mean_commits":1.0,"dds":0.0,"last_synced_commit":"ac7d13205c7de628e33c1bfad2fe8cecc60b976e"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/crenshaw-dev/CPUsim","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crenshaw-dev%2FCPUsim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crenshaw-dev%2FCPUsim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crenshaw-dev%2FCPUsim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crenshaw-dev%2FCPUsim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/crenshaw-dev","download_url":"https://codeload.github.com/crenshaw-dev/CPUsim/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crenshaw-dev%2FCPUsim/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262954379,"owners_count":23390409,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["compiler","lexer"],"created_at":"2024-10-13T22:05:16.770Z","updated_at":"2026-04-29T06:36:39.542Z","avatar_url":"https://github.com/crenshaw-dev.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"= Simple CPU Simulator =\n\nA project written by Michael Crenshaw \u003cmcrenshaw10@gmail.com\u003e to fulfill Honors\nPetition requirements for CSIS 434-001, Spring 2016.\n\n== Usage ==\n\nCPU.py when run alone checks for a file named program.dat in the current working\ndirectory. It then assembles that code, compiles it, and then runs it. It writes\noutput from the lexical analyser, assembler, and compiler to intuitively-named\noutput files, and it writes the CPU's register and memory data to cpu_output.txt\nand prints it to the screen.\n\nIf no program.dat exists, a default program hard-coded in CPU.py will be \nexecuted.\n\n== Language Definition ==\n\n\u003cprogram\u003e -\u003e \u003cseries\u003e\n\u003cseries\u003e -\u003e \u003cstatement\u003e | \u003cstatement\u003e; \u003cseries\u003e\n\u003cstatement\u003e -\u003e \u003cassign statement\u003e | \u003cloop\u003e\n\u003cassign statement\u003e -\u003e \u003cvariable\u003e := \u003cexpression\u003e\n\u003cdefinite loop\u003e -\u003e TO \u003cexpression\u003e DO \u003csegment\u003e END\n\u003csegment\u003e -\u003e \u003cassign statement\u003e | \u003cassign statement\u003e; \u003csegment\u003e\n\u003cexpression\u003e -\u003e \u003celement\u003e | \u003celement\u003e \u003cmath operator\u003e \u003celement\u003e\n\u003celement\u003e -\u003e \u003cconstant\u003e | \u003cvariable\u003e\n\u003cconstant\u003e -\u003e \u003cdigit\u003e | \u003cconstant\u003e \u003cdigit\u003e\n\u003cvariable\u003e -\u003e \u003cletter\u003e | \u003cvariable\u003e \u003cletter\u003e | \u003cvariable\u003e \u003cdigit\u003e\n\u003cmath operator\u003e -\u003e + | - | * | /\n\u003cdigit\u003e -\u003e 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9\n\u003cletter\u003e -\u003e a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | \n            r | s | t | u | v | w | x | y | z\n\nTwo major limitations of this language are that it does not allow nested loops\nand that it does not allow complex math operations (that is, they must occur one\nat a time). ","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrenshaw-dev%2Fcpusim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcrenshaw-dev%2Fcpusim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrenshaw-dev%2Fcpusim/lists"}