IP Library › Granted Patent US 9,965,390
Granted Patent B2
US 9,965,390 · App. 14/943,954 · Granted May 8, 2018

Reducing defragmentation in a multi-grained writeback cache

Inventors: Aayush Gupta (San Jose, CA); James L. Hafner (Pacific Grove, CA); Mohit Saxena (San Jose, CA)
Assignee: International Business Machines Corporation
G06F12/0806G06F12/0871G06F2212/621
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,965,390
App. No.
14/943,954
Granted
May 8, 2018
Kind
B2
Abstract

In one embodiment, a system includes a cache storage device and a processor and logic integrated with and/or executable by the processor. The logic is configured to select a cache block descriptor (CBD) from amongst a plurality of CBDs, the selected CBD including indications of being fragmented in the cache storage device. The logic is also configured to determine whether to defragment the selected CBD. Moreover, the logic is configured to defragment the selected CBD on the cache storage device in response to a decision to defragment the selected CBD.

Claims (50)

1. A system, comprising:

a cache storage device; and

a processor and logic integrated with and/or executable by the processor, the logic being configured to:

select a cache block descriptor (CBD) from amongst a plurality of CBDs stored to the cache storage device, the selected CBD comprising indications of being fragmented in the cache storage device, wherein the indications of being fragmented in the cache storage device include a number of fine block descriptors (FBDs) allocated to the CBD being greater than a threshold amount;

determine whether to defragment the selected CBD on the cache storage device; and

defragment the selected CBD on the cache storage device in response to a decision to defragment the selected CBD,

wherein the logic configured to determine whether to defragment the selected CBD is configured to:

determine utilization of FBDs allocated to the selected CBD to determine whether to defragment the selected CBD, wherein FBDs having a lower utilization rate are determinative for defragmentation as opposed to FBDs having a relatively higher utilization rate; and

determine whether the selected CBD has high utilization of a FBD free pool that is low on available FBDs.

2. The system as recited in claim 1 , wherein the logic configured to defragment the selected CBD is configured to merge data from one or more FBDs stored in the cache storage device and allocated to the selected CBD to form a larger chunk of data.

3. The system as recited in claim 2 , wherein the logic configured to select the CBD from amongst the plurality of CBDs is configured to select a CBD that will yield a greatest number of FBDs having a chunk size of which a least amount of free FBDs are available in the cache storage device.

4. The system as recited in claim 2 , wherein the logic is further configured to:

determine whether an amount of data merged together into the larger chunk of data is about equal to a block size used to store data to a back-end storage device; and

destage the larger chunk of data from the cache storage device to the back-end storage device in response to a determination that the amount of data merged together into the larger chunk of data is about equal to the block size used to store data to the back-end storage device.

5. The system as recited in claim 1 , wherein each CBD of the plurality of CBDs stored to the cache storage device have a plurality of FBDs allocated thereto.

6. A computer-implemented method, comprising:

selecting a cache block descriptor (CBD) from amongst a plurality of CBDs stored to a cache storage device, the selected CBD being determined to yield a greatest number of fine block descriptors (FBDs) having a chunk size of which a least amount of free FBDs are available in the cache storage device, the selected CBD comprising indications of being fragmented in the cache storage device;

determining whether to defragment the selected CBD; and

defragmenting the selected CBD on the cache storage device in response to a decision to defragment the selected CBD,

wherein the determining whether to defragment the selected CBD further comprises:

determining utilization of FBDs allocated to the selected CBD to determine whether to defragment the selected CBD, wherein FBDs having a lower utilization rate are determinative for defragmentation as opposed to FBDs having a relatively higher utilization rate; and

determining whether the selected CBD has high utilization of a FBD free pool that is low on available FBDs.

7. The method as recited in claim 6 , wherein the defragmenting the selected CBD further comprises merging data from one or more FBDs stored in the cache storage device and allocated to the selected CBD to form a larger chunk of data.

8. The method as recited in claim 6 , wherein each CBD of the plurality of CBDs stored to the cache storage device have a plurality of FBDs allocated thereto.

9. The method as recited in claim 7 , further comprising:

determining whether an amount of data merged together into the larger chunk of data is about equal to a block size used to store data to a back-end storage device; and

destaging the larger chunk of data from the cache storage device to the back-end storage device in response to a determination that the amount of data merged together into the larger chunk of data is about equal to the block size used to store data to the back-end storage device.

10. The method as recited in claim 6 , wherein the indications of being fragmented in the cache storage device comprise:

a number of FBDs allocated to the CBD being greater than a threshold amount.

11. A computer program product, the computer program product comprising a computer readable storage medium having program instructions embodied therewith, wherein the computer readable storage medium is not a transitory signal per se, the embodied program instructions readable/executable by a controller to cause the controller to:

select, by the controller, a cache block descriptor (CBD) from amongst a plurality of CBDs, the selected CBD comprising indications of being fragmented in a cache storage device;

determine, by the controller, whether to defragment the selected CBD; and

defragment, by the controller, the selected CBD on the cache storage device in response to a decision to defragment the selected CBD,

wherein the embodied program instructions readable/executable by the controller to determine whether to defragment the selected CBD are further readable/executable by the controller to:

determine utilization of fine block descriptors (FBDs) allocated to the selected CBD to determine whether to defragment the selected CBD, wherein FBDs having a lower utilization rate are determinative for defragmentation as opposed to FBDs having a relatively higher utilization rate; and

determine whether the selected CBD has high utilization of a FBD free pool that is low on available FBDs.

12. The computer program product as recited in claim 11 , wherein the embodied program instructions readable/executable by the controller to defragment the selected CBD are further readable/executable by the controller to merge data from one or more fine block descriptors (FBDs) stored in the cache storage device and allocated to the selected CBD to form a larger chunk of data.

13. The computer program product as recited in claim 12 , wherein the embodied program instructions readable/executable by the controller to select the CBD from amongst the plurality of CBDs are further readable/executable by the controller to select a CBD that will yield a greatest number of FBDs having a chunk size of which a least amount of free FBDs are available in the cache storage device.

14. The computer program product as recited in claim 12 , wherein the embodied program instructions are further readable/executable by the controller to:

determine whether an amount of data merged together into the larger chunk of data is about equal to a block size used to store data to a back-end storage device; and

destage the larger chunk of data from the cache storage device to the back-end storage device in response to a determination that the amount of data merged together into the larger chunk of data is about equal to the block size used to store data to the back-end storage device.

15. The computer program product as recited in claim 11 , wherein the indications of being fragmented in the cache storage device comprise:

a number of fine block descriptors (FBDs) allocated to the CBD being greater than a first threshold amount; and

a median or average chunk size of all FBDs allocated to the CBD being less than a second threshold.

16. The computer program product as recited in claim 12 , wherein each CBD of the plurality of CBDs stored to the cache storage device have a plurality of FBDs allocated thereto, and wherein an allocated FBD is not a free FBD available for use.

17. A computer program product, the computer program product comprising a computer readable storage medium having program instructions embodied therewith, wherein the computer readable storage medium is not a transitory signal per se, the embodied program instructions readable/executable by a controller to cause the controller to:

select, by the controller, a cache block descriptor (CBD) from amongst a plurality of CBDs, the selected CBD comprising indications of being fragmented in a cache storage device, wherein each CBD of the plurality of CBDs stored to the cache storage device have a plurality of fine block descriptors (FBDs) allocated thereto, and wherein an allocated FBD is not a free FBD available for use;

determine, by the controller, whether to defragment the selected CBD; and

defragment, by the controller, the selected CBD on the cache storage device by merging data from one or more FBDs stored in the cache storage device and allocated to the selected CBD to form a larger chunk of data in response to a decision to defragment the selected CBD,

wherein the selected CBD has a plurality of first FBDs allocated thereto of various chunk sizes, wherein defragmenting the selected CBD frees up a number of second FBDs having a same chunk size on the cache storage device, and wherein less FBDs having the chunk size of the second FBDs are available on the cache storage device than any single other FBD having a different chunk size than the second FBDs.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Feb 22, 2016
From: HAFNER, JAMES L.
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 037791/0433 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 17, 2015
From: GUPTA, AAYUSH; SAXENA, MOHIT
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 037064/0761 →
Continuity (1)
Related Publication 20170139830A1 · May 18, 2017