当前位置:天才代写 > C++/C代写,c语言代写代考-100%安全,包过 > 编程作业堆管理代写 operating system代写 code代写 operating system代写

编程作业堆管理代写 operating system代写 code代写 operating system代写

2021-04-27 17:50 星期二 所属: C++/C代写,c语言代写代考-100%安全,包过 浏览:1256

编程作业1代写

Programming Assignment 4: Heap Management

编程作业堆管理代写 In this assignment you will build your own implementation of malloc and free.That is, you will need to implement a library that interacts

Due: December 3 2018 5:30PM

Description 编程作业堆管理代写

In this assignment you will build your own implementation of malloc and free. That is, you will need to implement a library that interacts with the operating system to perform heap management on behalf of a user process as demonstrated in class.

You may complete this assignment in groups of two or by yourself. If you wish to be in a group of two the group leader must email me your group member’s names by November 26th, 2018. Your email must have the subject line “3320 [Section #] Project 4 Group” where section number is 002 or 003. ( 003 is the 5:30pm class, 002 is 7:00pm )编程作业堆管理代写

The code you submit for this assignment will be verified against a database consisting of kernel source, github code, stackoverflow, previous student’s submissions and other internet resources. Code that is not 100% your own code will result in a grade of 0 and referral to the Office of Student Conduct.

This project must be completed, in C, on omega.uta.edu. Windows does not support the sbrk() system call and MacOS/OSX’s implementation of shared libraries is unconventional.

编程作业堆管理代写
编程作业堆管理代写

Getting the Source 编程作业堆管理代写

The source code for this assignment may be found at: https://github.com/CSE3320/Heap

Building and Running the Code 编程作业1代写

The code compiles into four shared libraries and four test programs. To build the code, change to your top level assignment directory and type:

make

Once you have the library, you can use it to override the existing malloc by using LD_PRELOAD:

$ env LD_PRELOAD=lib/libmalloc-ff.so cat README.md

or

$ env LD_PRELOAD=lib/libmalloc-ff.so tests/test1编程作业堆管理代写

To run the other heap management schemes replace libmalloc-ff.so with the appropriate library:

Best-Fit: libmalloc-bf.so

First-Fit: libmalloc-ff.so

Next-Fit: libmalloc-nf.so

Worst-Fit: libmalloc-wf.so

Program Requirements (75pts)编程作业堆管理代写

Using the framework of malloc and free provided on the course github repository:

  1. Implement splitting and coalescing of free blocks. If two free blocks are adjacent then combine them. If a free block is larger than the requested size then split the block into
  2. Implement three additional heap management strategies: Next Fit, Worst Fit, Best Fit (First Fit has already been implemented foryou).
  3. Counters exist in the code for tracking of the followingevents:
  • Number of times the user calls mallocsuccessfully编程作业堆管理代写
  • Number of times the user calls freesuccessfully
  • Number of times we reuse an existingblock
  • Number of times we request a newblock
  • Number of times we split ablock编程作业堆管理代写
  • Number of times we coalesceblocks
  • Number blocks in freelist
  • Total amount of memoryrequested
  • Maximum size of theheap

The code will print these statistics upon exit and should look like this:

mallocs: 8

frees: 8

reuses: 1

grows: 5

splits: 1编程作业堆管理代写

coalesces: 1

blocks: 5

requested: 7298

max heap: 4096

You will need to increment these counters where appropriate.编程作业堆管理代写

  1. Four test programs are provided to help debug your code. They are located in the tests directory.
  2. Create benchmarks to analyze the metrics above for the different strategies for thefive benchmark programs to be posted in the

Report Requirements (25pts) 编程作业堆管理代写

Each team will be required to provide a written report in PDF format that discusses:.

  • Benchmarks: Adiscussion on how you benchmarked your library and what the results were. You should address:
    • Which heap management strategy does the best job of reusing free blocks? Which one isthe worst?
    • Which heap management strategy requires the least amount of heap space? Which one isthe worst?
    • Which heap management strategy allows for the most splits? most coalescing?least?编程作业1代写
    • Which heap management strategy was the fastest?slowest?
    • Consider the benchmark
      • Which one requires the most mallocs?frees?
      • Which one requests the most amount ofspace?编程作业堆管理代写
      • Which one requires the largestheap?
  • You must provide graphs of data and diagrams to backup your
  • Analysis: A discussion of the followingquestions:
    • Which heap management strategy suffers the most from fragmentation (whattype)?
    • Which heap management strategy is thebest?编程作业堆管理代写
    • You should provide evidence for your
  • Summary: A summary of what you learned about memory
  • Note, you must incorporate images, graphs, diagrams and other visual elements as part ofyour report.
  • Your report must be in PDF

Extra Credit (10pts)编程作业堆管理代写

  • Implement realloc andcalloc:

void *calloc(size_t nmemb, size_t size); void *realloc(void *ptr, size_t size);

How to submit homework 编程作业堆管理代写

  1. Submit a gzipped tarball of your source code and the PDF onblackboard.

编程作业4:堆管理
截止日期:2018年12月3日下午5:30

描述 编编程作业堆管理代写

在此分配中,您将构建自己的malloc和free实现。也就是说,你会
需要实现一个与操作系统交互的库以执行堆管理
代表在课堂上演示的用户流程。
您可以两人一组完成这项作业,也可以由您自己完成。如果您想成为一个小组
小组负责人中的两个必须在2018年11月26日之前通过电子邮件将您小组成员的姓名发送给我。编程作业堆管理代写
您的电子邮件必须包含主题行“ 3320 [Section#] Project 4 Group”,其中部分编号
是002或003。(003是下午5:30的班级,002是7:00 pm的班级)编程作业1代写
您针对此作业提交的代码将针对由内核组成的数据库进行验证
来源,github代码,stackoverflow,以前的学生提交的内容和其他互联网资源。
不是您自己的代码的100%的代码将导致0级并转介给Office
学生行为。
该项目必须在omega.uta.edu上的C中完成。 Windows不支持
sbrk()系统调用和MacOS / OSX对共享库的实现是非常规的。
获取来源
可以在以下位置找到此作业的源代码:https://github.com/CSE3320/Heap
建立和运行代码
该代码编译为四个共享库和四个测试程序。要构建代码,请更改为
您的顶级分配目录并输入:编程作业堆管理代写
制作
一旦有了库,就可以使用它来覆盖现有的malloc,方法是使用
LD_PRELOAD:
$ env LD_PRELOAD = lib / libmalloc-ff.so目录README.md
或者
$ env LD_PRELOAD = lib / libmalloc-ff.so tests / test1
要运行其他堆管理方案,请将libmalloc-ff.so替换为适当的编程作业堆管理代写
图书馆:
最适合:libmalloc-bf.so
初学者:libmalloc-ff.so
下一步:libmalloc-nf.so
最差的拟合:libmalloc-wf.so

计划要求(75分)编程作业堆管理代写

使用课程github信息库中提供的malloc和free框架:
1.实施空闲块的拆分和合并。如果两个空闲块相邻,则
结合起来。如果空闲块大于请求的大小,则将块分成两部分。
2.实施另外三种堆管理策略:下一轮,最差,最佳(第一个)
健身已经为您实现)。编程作业1代写
3.代码中存在用于跟踪以下事件的计数器:
•用户成功调用malloc的次数
•用户成功拨打免费电话的次数
•重用现有区块的次数
•我们请求一个新区块的次数
•我们分割区块的次数
•我们合并区块的次数
•空闲列表中的数字块
•请求的内存总量
•堆的最大大小
该代码将在退出时打印这些统计信息,并且应如下所示:
malloc的:8
免费:8
重复使用次数:1
成长:5
分割数:1
合并:1
方块:5
要求:7298
最大堆数:4096
您将需要在适当的地方增加这些计数器。编程作业1代写
4.提供了四个测试程序来帮助您调试代码。它们位于测试中
目录。
5.创建基准以分析上述五个策略的度量标准
将在回购中发布的基准程序。

报告要求(25分)编程作业堆管理代写

每个小组将被要求提供一份PDF格式的书面报告,其中包括:
•基准:讨论如何对库进行基准测试以及结果如何。
您应该解决:
•哪种堆管理策略最能重用空闲块?哪一个是
最差?
•哪种堆管理策略需要最少的堆空间?哪一个是
最差?
•哪种堆管理策略允许最多的拆分?最融合?至少?编程作业堆管理代写
•哪种堆管理策略最快?最慢?编程作业1代写
•考虑基准程序。
•哪一个需要最多的malloc?免费吗?
•哪个请求最多的空间?
•哪个需要最大的堆?
•您必须提供数据图和图表来备份您的结论。
•分析:对以下问题的讨论:
•哪种堆管理策略受碎片(哪种类型)影响最大?
•哪种堆管理策略是最好的?
•您应提供选择依据。
•摘要:您对内存管理了解的摘要。
•注意,您必须将图像,图形,图表和其他视觉元素作为您的一部分
报告。
•您的报告必须为PDF格式。

额外学分(10分)编程作业堆管理代写

•实现realloc和calloc:
无效* calloc(size_t nmemb,size_t size);
void * realloc(void * ptr,size_t size);

如何提交作业 编程作业堆管理代写

1.在黑板上提交您的源代码和PDF的压缩压缩包。

编程作业堆管理代写
编程作业堆管理代写

其他代写:algorithm代写 analysis代写 app代写 加拿大代写 jupyter notebook代assembly代写 assignment代写 C++代写 code代写 course代写 dataset代写 考试助攻 source code代写 dataset代写 金融经济统计代写 java代写  web代写 北美作业代写 编程代写

合作平台:essay代写 论文代写 写手招聘 英国留学生代写

 

天才代写-代写联系方式