OneBin Allocator and SPHeap Allocator
Explore the repository»
View Problem Statement
tags : memory allocator, weighted buddy, buddy, onebin, exponential buddy system
This project deals with the implementation of Weighted Buddy Method for Dynamic Storage Allocation
proposed by Shen & Peterson and OneBin Dynamic Storage Allocation
. We keep track of the memory space, Available Space List, KVAL, TAG and TYPE fields for the memory blocks centrally. We also keep track of the numbers of allocation requests, deallocation requests, area splits, buddy recombinations, internal fragmentation and external fragmentation. The program has been segregated to two folders:
- Tests: Tests folder contain the SPHeap implementation with the uniform and exponential synthetic testing for performance evaluation.
- Polynomial: Polynomial folder contains the implementing of SPHeap and OneBin memory allocation in the polynomial arithmetic program.
Within each directory, there are sub-directories corresponding to the memory allocators implemented. The program for each data structure is written in three files - client.c
, header.c
, and implement.c
. Comments have been added frequently to help in understanding the logic behind implementation. Refer Problem statement file for detailed information.
This project was built with
- C
- Ubuntu 18.04.1
- gcc version 7.4.0
Clone the repository into a local machine using
git clone https://github.com/vineeths96/Memory-Allocators
Open the terminal, and run the following command where TestMethod
is Exponential
or Uniform
.
cd Tests/<TestMethod>
Make the program and run it.
make
./a.out
Open the terminal, and run the following command where AllocMethod
is OneBin
or SPHeap
.
cd Polynomial/<AllocMethod>
Make the program and run it.
make
./a.out
Distributed under the MIT License. See LICENSE
for more information.
Vineeth S - vs96codes@gmail.com
Project Link: https://github.com/vineeths96/Memory-Allocators