99爱在线视频这里只有精品_窝窝午夜看片成人精品_日韩精品久久久毛片一区二区_亚洲一区二区久久

合肥生活安徽新聞合肥交通合肥房產生活服務合肥教育合肥招聘合肥旅游文化藝術合肥美食合肥地圖合肥社保合肥醫院企業服務合肥法律

代做COMP2046、代寫Memory Management

時間:2023-12-17  來源:合肥網hfw.cc  作者:hfw.cc 我要糾錯


Coursework COMP2046: Memory Management and Concurrent Programming

 Weight: 20% module marks

Deadline: 22nd December 2023, 5pm Beiging time

Submission: Create a single scyXXX.zip (Student account) file containing your source code files and reports. We will need to rebuild your code to test your implementation. You should submit your single zip file through Moodle.

Copying Code and Plagiarism

 You may freely copy and adapt any code samples provided in the lab exercises or lectures. You may freely copy code samples from the Linux/POSIX websites, which has many examples explaining how to do specific tasks. This coursework assumes that you will do so and doing so is a part of the coursework. You are therefore not passing someone else’s code off as your own, thus doing so does not count as plagiarism. Note that some of the examples provided omit error checking for clarity of the code. You are required to add error checking wherever necessary.

You must not copy code samples from any other source, including another student on this or any other course, or any third party (such as GPT). If you do so then you are attempting to pass someone else’s work off as your own and this is plagiarism. The University takes plagiarism extremely

seriously and this can result in getting 0 for the coursework, the entire module, or potentially much worse.

Coding and Compiling Your Coursework

 You are free to use a code editor of your choice, but your code MUST compile and run on a Linux environment. It will be tested and marked on these machines.

IMPORTANT: There are source file memory_allocation_simulation.c available on Moodle for download that you must use. To ensure consistency across all students, apart from the number parameter setting changes and the required TODO code, you are not allowed to change anything in the given source files. You need to compile your code using gcc compiler (e.g. gcc task1.c - o taks1 or gcc task2.c -pthread -o task2 ). Code cannot be successfully compiled on linux

     

 environment will receive ZERO marks.

 Introduction

 This coursework simulates real-world scenarios in memory management and concurrent programming. It is designed to deepen your understanding of these fundamental concepts through hands-on implementation and analysis.

Task 1: Memory Allocation Algorithm Implementation within a Bounded Buffer (6 Marks)

Objective

Implement and complete a memory allocation algorithm within a bounded buffer to emulate real- world memory management scenarios.

System Overview and Simulation Context

Code Base: You are provided with memory_allocation_simulation.c , which sets the groundwork for the simulation.

Simulation Environment: The code simulates a memory management system, reflecting typical real-world constraints and behaviors.

Random Memory Requests: The system generates multiple random memory requests, each with a unique ID, required memory size, allocation time, and duration.

Bounded Buffer Implementation: A bounded buffer, acting as a queue, stores up to 100 memory allocation requests. It manages incoming requests when immediate allocation is not feasible.

Memory Allocation Recording: A linked-list structure records the allocation status, with each node indicating process or hole status, request ID, and other relevant data.

Fixed-Size Memory Blocks: Memory is pre-allocated in 1MB (1024KB) blocks, subdivided into 1KB slices for allocation to requests.

Allocation Failure Handling: Requests failing immediate allocation due to space constraints or fragmentation are queued in the buffer.

Periodic Deallocation and Compaction: The system periodically deallocates memory and compacts freed spaces to optimize allocation efficiency.

 

 Configuration Parameters: The simulation works with a total memory size of 1MB, slice size of 1KB, and request sizes varying between 2KB to 50KB.

Detailed Requirements

Complete the Code: Complete the TODO code sections and enhance the provided simulation code to fully implement the memory management system.

Allocation Algorithms: Implement and integrate the Next Fit and Worst Fit allocation algorithms, in addition to the existing First Fit algorithm.

Memory Compaction: Develop a method to compact memory upon deallocation, improving allocation efficiency.

Submission

Submit task1.c containing your source code.

Ensure your code includes clear, explanatory comments.

Evaluation Criteria

Correct Implementation (**%): Accurate and efficient functioning of the Next Fit and Worst Fit algorithms, and the memory compaction method.

Documentation and Comments (10%): Clarity and usefulness of comments explaining the logic behind your implementation.

   Task 2: Multi-threaded Producer-Consumer Simulation with Counted Semaphores (6 Marks)

Objective

Based on the memory management simulation provided by Task 1 ( task1.c ), the objective of this task is to develop a multi-threaded simulation of a producer-consumer system, specifically focusing on memory management. This task requires the use of counted semaphores to manage synchronization between multiple producer and consumer threads.

Detailed Requirements

 Thread Creation and Roles:

 

 Implement a multi-threaded environment with separate threads acting as producers and consumers.

Producers generate memory allocation requests, while consumers process these requests.

Producer Threads:

Each producer thread should generate a random number of memory allocation requests. Request sizes should be random within a specified range (e.g., 2KB to 50KB).

Once generated, these requests must be enqueued into a shared bounded buffer.

Consumer Threads:

Consumer threads are responsible for dequeuing and processing memory allocation

requests from the buffer.

Processing includes simulating the allocation or deallocation of memory blocks, adhering to the memory allocation algorithms implemented in Task 1.

Synchronization with Counted Semaphores:

Utilize counted semaphores to manage access to the shared bounded buffer effectively.

Implement semaphores to signal when the buffer is not empty (for consumers) and not full (for producers), ensuring efficient and safe operation of the producer-consumer system.

Ensure thread safety and prevent race conditions with proper semaphore operations (wait and signal).

Logging and Monitoring:

Provide console output indicating the activities of consumer threads, including

allocation and deallocation of memory blocks.

Include details such as thread ID, operation type, and memory block size in the log messages.

Evaluation Criteria

Implementation of Semaphores (30%): Efficient semaphore use. Functionality (30%): Proper thread operation.

Synchronization (30%): Effective synchronization method.

 

 Documentation and Comments (10%): Quality of comments. Submission

Submit a file named task2.c containing the source code for this simulation.

The code should be well-commented, detailing the implementation and usage of semaphores and thread interactions.

  Task 3: Testing and Performance Analysis (8 Marks)

Objective

Implement and write a report that evaluates the correctness and performance of your implementation in the real-world scenario simulation.

Detailed Requirements:

Test the program using different scenarios, such as varying numbers of producer and consumer threads, different buffer sizes, and a variety of memory allocation patterns.

Measure and analyze key performance metrics, such as throughput (requests processed per second), respond time (hint: you can sue logging time method in the lab to measure the time), and resource utilization.

Discuss the advantages and disadvantages of the chosen memory allocation algorithm in the context of the simulated real-world scenario.

Evaluation Criteria

Testing Accuracy (40%): The thoroughness and relevance of the testing scenarios. Performance Analysis (20%): Depth and accuracy of performance metrics analysis.

Algorithm Evaluation (20%): Critical analysis of the chosen memory allocation algorithm's effectiveness.

Report Quality (20%): Clarity, structure, and comprehensiveness of the written report.

Submission

 Submit a file named task3.pdf containing the report for this performance analysis. The

 

 report should clearly articulate the testing process, performance metrics, and your analysis of the memory allocation algorithm. The length of the report should be less than three pages.

You can also submit your supporting documents (optional):

Source code used to generate evaluation metrics. This code should be well-commented and organized for easy understanding.

Any additional supporting documents such as screenshots of testing, graphs, charts, or other visual aids that illustrate your testing and analysis.

Ensure that all documents are comprehensively labeled and easy to navigate.

 Conclusion

 Completing these tasks will provide invaluable experience in integrating and evaluating memory management algorithms within concurrent programming environments. Good luck, and remember that assistance is available if you have any questions or need further guidance.

 

請加QQ:99515681 或郵箱:99515681@qq.com   WX:codehelp

 

掃一掃在手機打開當前頁
  • 上一篇:G6017編程代做代寫、MATLAB編程設計代做
  • 下一篇:代做Writing a Dynamic Storage Allocator
  • 無相關信息
    合肥生活資訊

    合肥圖文信息
    急尋熱仿真分析?代做熱仿真服務+熱設計優化
    急尋熱仿真分析?代做熱仿真服務+熱設計優化
    出評 開團工具
    出評 開團工具
    挖掘機濾芯提升發動機性能
    挖掘機濾芯提升發動機性能
    海信羅馬假日洗衣機亮相AWE  復古美學與現代科技完美結合
    海信羅馬假日洗衣機亮相AWE 復古美學與現代
    合肥機場巴士4號線
    合肥機場巴士4號線
    合肥機場巴士3號線
    合肥機場巴士3號線
    合肥機場巴士2號線
    合肥機場巴士2號線
    合肥機場巴士1號線
    合肥機場巴士1號線
  • 短信驗證碼 豆包 幣安下載 AI生圖 目錄網

    關于我們 | 打賞支持 | 廣告服務 | 聯系我們 | 網站地圖 | 免責聲明 | 幫助中心 | 友情鏈接 |

    Copyright © 2025 hfw.cc Inc. All Rights Reserved. 合肥網 版權所有
    ICP備06013414號-3 公安備 42010502001045

    99爱在线视频这里只有精品_窝窝午夜看片成人精品_日韩精品久久久毛片一区二区_亚洲一区二区久久

          9000px;">

                欧美一级高清大全免费观看| 7777精品伊人久久久大香线蕉超级流畅 | 国产视频一区二区在线观看| 粉嫩av一区二区三区| 日本一区二区视频在线观看| 在线免费视频一区二区| 日产欧产美韩系列久久99| 久久综合色婷婷| 在线一区二区三区四区五区 | 欧美吻胸吃奶大尺度电影| 亚洲国产美国国产综合一区二区| 欧美变态tickle挠乳网站| jlzzjlzz亚洲日本少妇| 五月天亚洲精品| 亚洲欧美怡红院| 欧美一级久久久| 99re在线精品| 韩国女主播成人在线观看| 一区二区三区蜜桃| 国产欧美视频一区二区三区| 欧美精品亚洲一区二区在线播放| 国产99久久精品| 久久精品国产99久久6| 亚洲欧美日韩中文字幕一区二区三区| 欧美成人精品福利| 欧美日韩亚洲综合在线 欧美亚洲特黄一级 | 91久久人澡人人添人人爽欧美| 久久电影国产免费久久电影| 亚洲自拍偷拍欧美| 中文字幕免费观看一区| 91精品黄色片免费大全| 91九色最新地址| 成人免费视频视频在线观看免费| 毛片av一区二区| 丝袜脚交一区二区| 亚洲午夜一区二区| 一级女性全黄久久生活片免费| 国产精品久久久久永久免费观看| 久久蜜桃av一区精品变态类天堂| 91麻豆精品91久久久久久清纯 | 亚洲五月六月丁香激情| 国产精品久久久久影视| 久久色.com| 日韩一区二区三| 91精品国模一区二区三区| 欧美久久高跟鞋激| 在线播放亚洲一区| 欧美一区在线视频| 日韩一区二区电影在线| 欧美日本视频在线| 7777精品伊人久久久大香线蕉经典版下载 | 精品国产一区二区三区不卡| 日韩午夜精品视频| 制服视频三区第一页精品| 欧美在线观看视频一区二区 | 制服丝袜中文字幕一区| 欧美二区在线观看| 欧美一区二区在线免费播放| 欧美一级免费大片| 精品国产不卡一区二区三区| 久久久亚洲高清| 亚洲欧洲精品一区二区三区不卡| 亚洲乱码中文字幕| 五月婷婷久久丁香| 国产又黄又大久久| av网站免费线看精品| 色偷偷久久一区二区三区| 欧美日本韩国一区二区三区视频 | 欧美一区二区三区不卡| 2021久久国产精品不只是精品| 欧美激情一区二区三区全黄| 一区二区三区日本| 精品一区二区免费看| 99久久久国产精品| 91麻豆精品国产91| 国产日韩亚洲欧美综合| 亚洲精品老司机| 蜜臀久久久99精品久久久久久| 成人免费毛片高清视频| 欧美日韩国产在线播放网站| 精品国产免费久久| 一区二区三区在线视频播放| 日本v片在线高清不卡在线观看| 成人av网址在线| 正在播放亚洲一区| 亚洲人成伊人成综合网小说| 精品在线播放午夜| 欧美亚洲国产一区二区三区| www久久精品| 亚洲午夜在线视频| 成人黄色免费短视频| 欧美一区二区三区视频免费| 亚洲女与黑人做爰| 国产老妇另类xxxxx| 欧美一区二区三区日韩视频| 亚洲蜜桃精久久久久久久| 国产自产v一区二区三区c| 欧美性色aⅴ视频一区日韩精品| 欧美国产精品v| 狠狠色狠狠色综合系列| 欧美另类久久久品| 亚洲精品日韩综合观看成人91| 国产成人av电影| 日韩欧美在线综合网| 五月激情综合色| 欧美视频日韩视频| 自拍偷拍亚洲激情| 懂色中文一区二区在线播放| 久久久www免费人成精品| 日本在线不卡视频| 这里只有精品99re| 视频一区二区不卡| 欧美精品电影在线播放| 亚洲国产裸拍裸体视频在线观看乱了| 91视频你懂的| 亚洲精品大片www| 欧美性大战久久| 亚洲大尺度视频在线观看| 欧美日韩国产综合一区二区三区 | 精品美女一区二区| 日本女人一区二区三区| 欧美视频一区二| 午夜精品久久久| 日韩一区二区免费视频| 美女精品自拍一二三四| 精品国产一区二区国模嫣然| 国产中文字幕精品| 国产拍欧美日韩视频二区| 国产成人免费在线观看不卡| 国产女主播视频一区二区| 99久久久国产精品免费蜜臀| 亚洲精品免费视频| 在线播放视频一区| 国产真实精品久久二三区| 国产精品视频线看| 在线精品观看国产| 亚洲成人福利片| 久久亚洲影视婷婷| 91免费视频网| 麻豆精品国产传媒mv男同| 久久久久国产精品人| 99综合影院在线| 午夜欧美视频在线观看| 精品成人一区二区三区| 国产xxx精品视频大全| 一区二区三区国产精华| 3d动漫精品啪啪一区二区竹菊 | 日韩欧美一区二区三区在线| 国产精品99久久久久| 亚洲国产欧美一区二区三区丁香婷| 日韩欧美久久久| 成人av第一页| 日韩电影一区二区三区四区| 国产精品网站一区| 8x8x8国产精品| 成人精品国产一区二区4080| 日韩av不卡在线观看| 国产精品欧美极品| 制服.丝袜.亚洲.另类.中文| www.亚洲精品| 久草中文综合在线| 一区二区在线观看视频在线观看| 日韩视频免费观看高清完整版 | 北岛玲一区二区三区四区| 亚洲综合免费观看高清完整版| 精品国产91乱码一区二区三区| 色哟哟一区二区在线观看| 国产成人精品三级麻豆| 日本少妇一区二区| 一区二区在线观看不卡| 国产清纯白嫩初高生在线观看91| 在线不卡中文字幕播放| 91首页免费视频| 国产精品77777| 久久99久久久久久久久久久| 一区二区三区在线观看国产| 国产日韩三级在线| 精品国产欧美一区二区| 欧美妇女性影城| 精品视频在线看| 在线观看视频一区二区 | 久久久久久影视| 日韩欧美电影在线| 欧美区在线观看| 欧美日韩高清在线| 欧美日韩在线一区二区| 色国产综合视频| 在线精品观看国产| 欧美性一二三区| 在线观看日韩高清av| 91国偷自产一区二区三区成为亚洲经典 | 日韩一级片在线播放| 欧美精品乱人伦久久久久久| 欧美视频一区二区三区在线观看| av中文一区二区三区| 99国产精品国产精品久久| 成人精品视频一区| 99精品国产视频| 91久久线看在观草草青青| 色av综合在线|