{"id":24562517,"url":"https://github.com/z1skgr/memory-management-i-o","last_synced_at":"2026-02-21T17:01:57.959Z","repository":{"id":163130776,"uuid":"314716368","full_name":"z1skgr/Memory-Management-I-O","owner":"z1skgr","description":"Memory orchestration at the different levels of languages","archived":false,"fork":false,"pushed_at":"2024-12-05T11:20:34.000Z","size":57,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-20T07:16:51.220Z","etag":null,"topics":["assembly","c","clang","cygwin","exceptions-handling","interrupts","memory-allocation","memory-layout","merge-sort","mergesort","mips-architecture","pcspim","program-execution","stack"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/z1skgr.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}},"created_at":"2020-11-21T02:28:48.000Z","updated_at":"2024-12-19T09:16:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"0dac6e91-39de-4209-b6cd-da0fa017a1a4","html_url":"https://github.com/z1skgr/Memory-Management-I-O","commit_stats":null,"previous_names":["z1skgr/memory-management-i-o","z1skgr/c-clang-assembly-memory-management"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/z1skgr/Memory-Management-I-O","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/z1skgr%2FMemory-Management-I-O","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/z1skgr%2FMemory-Management-I-O/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/z1skgr%2FMemory-Management-I-O/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/z1skgr%2FMemory-Management-I-O/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/z1skgr","download_url":"https://codeload.github.com/z1skgr/Memory-Management-I-O/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/z1skgr%2FMemory-Management-I-O/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29688216,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-21T15:51:39.154Z","status":"ssl_error","status_checked_at":"2026-02-21T15:49:03.425Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["assembly","c","clang","cygwin","exceptions-handling","interrupts","memory-allocation","memory-layout","merge-sort","mergesort","mips-architecture","pcspim","program-execution","stack"],"created_at":"2025-01-23T09:11:19.547Z","updated_at":"2026-02-21T17:01:57.942Z","avatar_url":"https://github.com/z1skgr.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# memory structure\n\u003e Μemory management at programming levels (high-\u003e mid -\u003e low (Assembly)) \n\n ## Table of contents\n* [Labs](#labs)\n   * [1](#1)\n   * [2](#2)\n   * [3](#3)\n   * [4](#4)\n   * [5](#5)\n   * [6](#6) \n* [How to run](#how-to-run)\n* [Acknowledgments](#acknowledgments)\n\n## Labs\n\n### _1_ \n#### Memory management and data structures\n* Hexadeced representation. \n* Ordering elements in memory using pointers and arrays. \n* Structs declaration\n   * 2 structs with different variable content\n* Dynamic memory allocation \n* Μemory use map\n\n\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\n\n\n### _2_ \n#### Structure management in memory using linked data list operations.\n##### C\nMenu for the options \n* Create List\n* Insert Element\n    * (id, value)\n* Delete First\n* Print \n    * Address/Value element\n    * List count\n    * List address\n    * Address element field\n    * List size (bytes)\n    * Element size (bytes)\n\n\u003cbr\u003e\u003cbr\u003e\n\n##### CLang\n* Create List\n* Insert Element\n    * (id, value)\n* Delete First\n* Print element value\n\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\n\n### _3_\n#### Deepening the understanding of memory function in Clang/understanding of Assembly\n##### C\nNew operation\n * Print function address\n * Calculate list size to bytes from addresses that occupy items\n\n\u003cbr\u003e\u003cbr\u003e\n\n##### CLang\nConversion of all the variables used in c\nMenu for the options using standards (reference registers, etc)\n* Create List\n* Insert Element\n    * (id, value)\n* Delete First\n* Print \n    * Address/Value element\n    * List count\n    * List address\n    * Address element field\n    * List size (bytes)\n    * Element size (bytes)\n\n\u003cbr\u003e\u003cbr\u003e\n\n##### Assembly\nMenu options (no functionality)\n\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\n\n### _4_ \n#### Deepening the understanding of Clang/Assembly\n##### CLang\nModification from previous implementation\n* Create finite list\n* Delete Last\n* Print element with minimum value\n\n\u003cbr\u003e\u003c/br\u003e\n\n##### Assembly\n* 100 nodes on list (static array)\n* Correctness of assembly contracts (register contracts)\n* Menu functionality (#3)\n* Jal commands for call functions\n\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\u003cbr\u003e\n\n### _5_ \n#### Modification from previous implementation\n##### Assembly\n* Ascending sort using ***recursive*** Merge sort [^1]\n    * Stack emerged\n* Convert values from type int -\u003e short\n\n\u003cbr\u003e\u003c/br\u003e\u003cbr\u003e\u003cbr/\u003e\n\n### _6_\n#### I/O Exceptions\n##### Assembly\nManagement of input/output devices, using the memory display of the units I/O\n###### Polling\nChecking peripheral devices if they are ready to accept/export data without syscall (*write_ch,read_ch*).\n\n\n\n| Functions | |\n| :---: | :---: | \n| write_ch | Reads register Transmission control (TC) / Check device (crosscheck instruction and LSB) |\n| read_ch | Waiting for new registration |\n| print_str | Candidate for printing char per char  |\n\n\u003cbr\u003e\u003cbr\u003e\n\n\n##### Interrupts\n| Menu | \n| :---: | \n| Choice #1 |\n| Choice #2 |\n| Exit |\n\n\u003cbr\u003e\n\nMenu options for keyboard using interrupts\n    * cflag, cdata for handler\n\u003cbr\u003e\n\u003e Choice 1 for 1 \u003cbr\u003e\n\u003e Choice 2 for 2 \u003cbr\u003e\n\u003e Exit for space. \u003cbr\u003e\n\u003e Message appears \u003cbr\u003e\n\n\n\n\n\n\u003cbr\u003e\u003c/br\u003e\u003cbr\u003e\u003c/br\u003e\n## How to run \n### C/CLang\n\n1. Instal cygwin compiler for your operation system\n```\nhttps://www.cygwin.com/install.html\n```\n* Create folder Cygwin\n* Open installer \n* Install from internet\n* Select your path folder\n* Select `+` and install compiler and debugger\n* Find `gcc-core, gcc-g++, gdb, make`\n\u003cbr\u003e\u003cbr\u003e\n\n2. Configure `PATH` variable\n* Go to System and Security in Control Panel\n* Advanced System Settings\n* Environmental Variables\n* Add to path variable the path ``cygwin-directory\\bin`` of your cygwin folder\n\u003cbr\u003e\u003cbr\u003e\n\n3. Install Apache NetBeans (or any other C IDE)\n```\nhttps://netbeans.apache.org/download/index.html\n```\n4. Instal NetBeans plugins\n5. Import .c files to your workspace or Create a new C project\n6. Run your .c source files\n7. To execute clang files, use _gcc 5.2__ or below\n\n\u003cbr\u003e\u003cbr\u003e\n### Assembly\n1. Install PCSpim from website\n```\nhttp://spimsimulator.sourceforge.net/\n```\n\n2. Install Notepad [^2]  software (or mipster [^3]) \n3. Simulator-\u003eSettings\n    * Mapped I/O\n    * Load Exception file\n4. File-\u003eReinitialize-\u003eLoad File [^4][^5] -\u003e Run\n\n\u003cbr\u003e\u003cbr\u003e\n\nFor (#6), necessery modifications on file\n* Exception file\n```\nlui $k1 0xFFFF\nlw  $k0 4($k1)\n\nla $t1, cdata\nsw $k0,0($t1)\nla $t1, cflag\naddi $k0, $zero,1\nsw $k0,0($t1)\n```\n\n## Acknowledgments\nProjects were created for the requirements of the lesson Digital Computers\n\n\n\n\n\n\n\n\n\n\n\n\n[^1]: https://en.wikipedia.org/wiki/Merge_sort#:~:text=In%20computer%20science%2C%20merge%20sort%20%28also%20commonly%20spelled,was%20invented%20by%20John%20von%20Neumann%20in%201945.\n[^2]: MIPS simulator recognizes programs written in text editors\n[^3]: https://mipster.software.informer.com/\n[^4]: Reinitialize and load every time you run the program\n[^5]: Extension .asm to run files on SPIM\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fz1skgr%2Fmemory-management-i-o","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fz1skgr%2Fmemory-management-i-o","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fz1skgr%2Fmemory-management-i-o/lists"}