{"id":28717181,"url":"https://github.com/priyanshscpp/scheduler-gtest","last_synced_at":"2025-09-04T18:15:47.920Z","repository":{"id":297779238,"uuid":"997881029","full_name":"priyanshscpp/scheduler-gtest","owner":"priyanshscpp","description":"Demonstrates OS-level thinking (round-robin, priority, etc.). Very relevant for CPU/microarchitecture work.","archived":false,"fork":false,"pushed_at":"2025-06-13T17:35:32.000Z","size":80,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-15T03:13:53.428Z","etag":null,"topics":["cpp","gtest","operating-systems","qualcomm","unit-testing"],"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/priyanshscpp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","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}},"created_at":"2025-06-07T11:49:02.000Z","updated_at":"2025-06-07T12:32:50.000Z","dependencies_parsed_at":"2025-06-07T12:41:20.904Z","dependency_job_id":null,"html_url":"https://github.com/priyanshscpp/scheduler-gtest","commit_stats":null,"previous_names":["priyanshscpp/scheduler-gtest"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/priyanshscpp/scheduler-gtest","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/priyanshscpp%2Fscheduler-gtest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/priyanshscpp%2Fscheduler-gtest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/priyanshscpp%2Fscheduler-gtest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/priyanshscpp%2Fscheduler-gtest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/priyanshscpp","download_url":"https://codeload.github.com/priyanshscpp/scheduler-gtest/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/priyanshscpp%2Fscheduler-gtest/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273651040,"owners_count":25143952,"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","status":"online","status_checked_at":"2025-09-04T02:00:08.968Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["cpp","gtest","operating-systems","qualcomm","unit-testing"],"created_at":"2025-06-15T03:13:35.663Z","updated_at":"2025-09-04T18:15:47.860Z","avatar_url":"https://github.com/priyanshscpp.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CPU Scheduler Simulator\n\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\nA production-grade CPU scheduler simulator that implements various scheduling algorithms with detailed performance analysis and visualization capabilities.\n\n## 🎯 Features\n\n- Multiple scheduling algorithms:\n  - First Come First Serve (FCFS)\n  - Shortest Job First (SJF)\n  - Round Robin (RR)\n  - Priority Scheduling\n  - Multilevel Feedback Queue\n- Real-time visualization of process scheduling\n- Detailed performance metrics and benchmarking\n- Support for custom workload scenarios via JSON/CSV\n- Memory management simulation\n- Context switch overhead simulation\n- Comprehensive test suite\n\n\n\n## Process State Transition Diagram\n\n![image](https://github.com/user-attachments/assets/a660c776-dfb0-46ea-801b-1625b4856a91)\n\n\n## Data Flow Diagram\n\n![image](https://github.com/user-attachments/assets/9c238cab-bf95-4a76-a3a7-aa35a0b5ce0d)\n\n\n## 🚀 Getting Started\n\n### Prerequisites\n\n- CMake 3.14 or higher\n- C++17 compatible compiler\n- Google Test (for unit testing)\n- Docker (optional)\n\n### Building from Source\n\n```bash\n# Clone the repository\ngit clone https://github.com/yourusername/cpu-scheduler-simulator-cpp.git\ncd cpu-scheduler-simulator-cpp\n\n# Create build directory\nmkdir build \u0026\u0026 cd build\n\n# Configure and build\ncmake .. -DCMAKE_TOOLCHAIN_FILE=[path to vcpkg]/scripts/buildsystems/vcpkg.cmake\ncmake --build .\n\n# Run tests\nctest --output-on-failure\n```\n\n### Using Docker\n\n```bash\n# Build the Docker image\ndocker build -t cpu-scheduler .\n\n# Run the simulator\ndocker run -it cpu-scheduler\n```\n\n## 📊 Usage\n\n### Basic Usage\n\n```bash\n# Run with default FCFS scheduler\n./cpu-scheduler --algorithm fcfs\n\n# Run with Round Robin (quantum = 4)\n./cpu-scheduler --algorithm rr --quantum 4\n\n# Load custom workload\n./cpu-scheduler --workload workloads/example.json\n```\n\n### Sample Output\n\n```\nTime Quantum: 4\nProcess ID | Arrival Time | Burst Time | Priority\n------------------------------------------------\n1          | 0           | 10         | 2\n2          | 2           | 5          | 1\n3          | 4           | 8          | 3\n\nScheduling Timeline:\n[P1][P2][P1][P3][P1]...\n```\n\n## 🔧 Architecture\n\nThe simulator is built with a modular, object-oriented design:\n\n```\nsrc/\n├── core/\n│   ├── process.hpp\n│   ├── scheduler.hpp\n│   └── simulator.hpp\n├── algorithms/\n│   ├── fcfs.hpp\n│   ├── sjf.hpp\n│   └── round_robin.hpp\n└── utils/\n    ├── metrics.hpp\n    └── visualization.hpp\n```\n\n\n## Component Architecture Diagram \n\n![image](https://github.com/user-attachments/assets/5e065dc5-aaa3-4ab3-a87d-4a4b056e1cf5)\n\n\n## 📈 Benchmarks\n\nSee [BENCHMARKS.md](BENCHMARKS.md) for detailed performance comparisons between different scheduling algorithms.\n\n## 🤝 Contributing\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes (`git commit -m 'Add amazing feature'`)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\nSee [CONTRIBUTING.md](CONTRIBUTING.md) for detailed guidelines.\n\n## 📝 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## 🙏 Acknowledgments\n\n- Operating Systems Concepts (Silberschatz et al.)\n- Modern Operating Systems (Tanenbaum)\n# scheduler-gtest\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpriyanshscpp%2Fscheduler-gtest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpriyanshscpp%2Fscheduler-gtest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpriyanshscpp%2Fscheduler-gtest/lists"}