12.07.2015 Views

A Practical Introduction to Data Structures and Algorithm Analysis

A Practical Introduction to Data Structures and Algorithm Analysis

A Practical Introduction to Data Structures and Algorithm Analysis

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

446 Chap. 12 Lists <strong>and</strong> Arrays Revisited• add two matrices.12.2 Implement the MemManager ADT shown at the beginning of Section 12.3.Use a separate linked list <strong>to</strong> implement the freelist. Your implementationshould work for any of the three sequential-fit methods: first fit, best fit, <strong>and</strong>worst fit. Test your system empirically <strong>to</strong> determine under what conditionseach method performs well.12.3 Implement the MemManager ADT shown at the beginning of Section 12.3.Do not use separate memory for the free list, but instead embed the free listin<strong>to</strong> the memory pool as shown in Figure 12.12. Your implementation shouldwork for any of the three sequential-fit methods: first fit, best fit, <strong>and</strong> worstfit. Test your system empirically <strong>to</strong> determine under what conditions eachmethod performs well.12.4 Implement the MemManager ADT shown at the beginning of Section 12.3using the buddy method of Section 12.3.1. Your system should supportrequests for blocks of a specified size <strong>and</strong> release of previously requestedblocks.12.5 Implement the Deutsch-Schorr-Waite garbage collection algorithm that is illustratedby Figure 12.18.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!