{"id":24313632,"url":"https://github.com/stuarthayhurst/lmc-simulator","last_synced_at":"2026-04-28T16:35:43.077Z","repository":{"id":192691201,"uuid":"620539645","full_name":"stuarthayhurst/lmc-simulator","owner":"stuarthayhurst","description":"Assemble and execute Little Man Computer assembly","archived":false,"fork":false,"pushed_at":"2026-04-23T18:35:39.000Z","size":125,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-04-23T20:23:02.272Z","etag":null,"topics":["assembler","assembly","little-man-computer"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stuarthayhurst.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"stuarthayhurst","ko_fi":"stuarthayhurst","custom":"https://paypal.me/stuartahayhurst"}},"created_at":"2023-03-28T22:12:38.000Z","updated_at":"2026-04-23T18:35:45.000Z","dependencies_parsed_at":null,"dependency_job_id":"7abb6548-c8f1-4979-a29e-4039e1fa456f","html_url":"https://github.com/stuarthayhurst/lmc-simulator","commit_stats":null,"previous_names":["stuarthayhurst/lmc-simulator"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/stuarthayhurst/lmc-simulator","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuarthayhurst%2Flmc-simulator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuarthayhurst%2Flmc-simulator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuarthayhurst%2Flmc-simulator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuarthayhurst%2Flmc-simulator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stuarthayhurst","download_url":"https://codeload.github.com/stuarthayhurst/lmc-simulator/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuarthayhurst%2Flmc-simulator/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32390049,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-28T14:34:11.604Z","status":"ssl_error","status_checked_at":"2026-04-28T14:32:37.009Z","response_time":56,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["assembler","assembly","little-man-computer"],"created_at":"2025-01-17T09:12:43.337Z","updated_at":"2026-04-28T16:35:43.073Z","avatar_url":"https://github.com/stuarthayhurst.png","language":"C++","funding_links":["https://github.com/sponsors/stuarthayhurst","https://ko-fi.com/stuarthayhurst","https://paypal.me/stuartahayhurst"],"categories":[],"sub_categories":[],"readme":"## lmc-simulator\n  - Assemble and execute assembly of the [Little Man Computer](https://en.wikipedia.org/wiki/Little_Man_Computer) instruction set\n  - Additionally supports comments starting with '`#`' or '`//`'\n\n## Requirements:\n  - A compiler supporting `c++-20`\n    - Override the default by setting the `CXX` environment variable, if required\n\n## Building:\n  - `make`: Builds the simulator\n    - Supports multiple threads with `-j[THREAD COUNT]`\n    - Use `make -j$(nproc)` to build with all available threads\n  - `make debug`: Builds the simulator with `DEBUG=true`\n  - `make clean`: Removes the compiled simulator, if present\n  - `DEBUG=[true/false]`: Environment variable to enable debug support\n    - Includes debug symbols, retains the frame pointer and uses sanitisers\n  - `BUILD_DIR`: Environment variable to configure built object output\n\n## Usage:\n  - `./simulator [FILE] [MEMORY SIZE]`\n    - For example, `./simulator programs/power.asm`\n    - Or to limit the memory size to 50, `./simulator programs/power.asm 50`\n  - Set `DEBUG=\"true\"` as an environment variable, to enable debug output\n    - `DEBUG=\"true\" ./simulator [FILE]`\n\n## Sample programs:\n  - In order of complexity, some sample programs are kept in `programs/`:\n    - `multiply.asm`: Multiply 2 inputs together\n    - `modulus.asm`: Carry out modular division between 2 inputs\n    - `triangular.asm`: Output the first `n` triangular numbers\n    - `fibonacci.asm`: Output the first `n` terms of the Fibonacci sequence\n    - `gcd.asm`: Output the greatest common divisor between 2 inputs\n    - `power.asm`: Raise the first input to the power of the second\n    - `iteration.asm`: Iterate over a group of addresses\n    - `quine.asm`: Iterate over the program's instructions to print its own code\n    - `binary.asm`: Convert an integer from input into 8-bit binary\n    - `leapyear.asm`: Check if a year from 1 to 999 was a leap year\n\n## Contributing:\n  - Feel free to submit pull requests!\n  - Contributed code must fit the style of the codebase so far\n  - Sample assembly is also welcome, as long as it's under `programs/`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstuarthayhurst%2Flmc-simulator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstuarthayhurst%2Flmc-simulator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstuarthayhurst%2Flmc-simulator/lists"}