Large Memory Page Migration via Segmentation and Dual Write
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing solutions for memory migration, such as suspending I/O devices or dual write capability, are inadequate for migrating large system memory pages, leading to performance issues and limitations in managing memory space and logical partitions, especially for page sizes larger than 64K.
Innovation Solution
The method involves converting large pages into smaller subpages, allowing continuous CPU access during migration, and using dual write mode for specific segments to efficiently migrate large system memory pages, enabling migration of pages of any size without suspending hardware.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If the memory is accessed directly via I/O devices, then I/O performance is improved, but memory migration becomes difficult as updates may be lost during the move
Solution Approach 1:
The patent creates a duplicate copy of the memory page at the destination location before migrating the I/O device's memory window. The I/O device continues to write to both the source and destination pages simultaneously during the migration process, ensuring no data is lost. This copying approach allows memory migration to proceed without suspending I/O operations, maintaining I/O performance while enabling successful migration of large memory pages.
2Reliability
If the I/O device is suspended during migration, then data consistency is maintained, but hardware utilization decreases and performance drops
Solution Approach 1:
The patent enables continuous I/O operations during memory page migration by implementing dual write capability. The I/O device maintains its useful action (writing to memory) throughout the migration process by writing to both the source and destination pages simultaneously. This eliminates the need to suspend the I/O device, maintaining both data consistency through controlled dual writes and high hardware utilization through continuous operation.
3Reliability
If dual write capability is used for small pages, then migration is successful without suspension, but the approach becomes prohibitively slow for large page sizes
Solution Approach 1:
The patent segments the large memory page into multiple smaller sub-pages, each of which can be migrated independently using dual write capability. By dividing a large page (e.g., 16MB or 256MB) into smaller manageable units, the system can migrate each sub-page sequentially while the I/O device continues to operate. This segmentation approach maintains migration reliability through controlled dual writes while reducing the time loss compared to migrating the entire large page at once.
4Reliability
If CPU prevents access to migrating page for long duration, then migration completeness is ensured, but application disruptions occur
Solution Approach 1:
The patent performs preliminary actions by creating the destination page copy and setting up the dual write capability before the I/O device begins writing to the new location. The CPU prepares the migration infrastructure in advance, allowing the I/O device to continue operating without interruption. This preliminary setup ensures migration completeness while maintaining application continuity, as the CPU does not need to block access for the entire migration duration.
Data Source
AI summary
A method, system and computer program product are provided for implementing memory migration of large system memory pages in a computer system. A large page to be migrated from a current location to a target location is converted into a plurality of smaller subpages for a processor or system page table. The migrated page is divided into first, second and third segments, each segment composed of the smaller subpages and each respective segment changes as each individual subpage is migrated. CPU and I/O accesses to respective subpages of the first segment are directed to corresponding subpages of the target page or new page. I/O accesses to respective subpages of the second segment use a dual write mode targeting corresponding subpages of both the current page and the target page. CPU and I/O accesses to the subpages of the third segment access the corresponding subpages of the current page.


