Applied memory management method and device
A technology of memory management and memory, which is applied in the field of communication, can solve problems such as insufficient application memory management, and achieve the effect of high coverage
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0044] see figure 1 , an embodiment of the present invention provides an application memory management method, including:
[0045] 101: After receiving the application memory request from the application, query the memory application interface for operating memory paging;
[0046] 102: Allocate a memory block for the application according to the size of the memory page provided by the memory application interface for operating memory paging;
[0047] 103: Add a guard page at the beginning or end of the memory block allocated for the application, and the guard page is used to provide exception detection for the debugger.
[0048] In this embodiment, the allocation of a memory block for the application according to the size of the memory page provided by the memory application interface for operating memory paging includes:
[0049] Allocating a memory block for the application, and aligning the allocated memory block with the size of the memory page provided by the memory app...
Embodiment 2
[0062] The embodiment of the present invention provides a method for managing application memory. The method for managing application memory provided by the embodiment of the present invention is suitable for emulators. The method provided by the embodiment of the present invention can only be used on operating systems that support the memory paging mechanism. Such as Windows, Linux, Mac OS and other operating systems.
[0063] In the embodiment of the present invention, such as figure 2 As shown, the memory usage model of the Windows operating system is generally layered and includes: an application upper layer module, an application memory management device, and a C library encapsulating Malloc, HeapAlloc, and VirtualAlloc interfaces. Based on the system architecture of the Windows operating system, the application memory management module does not directly use the interface provided by the system (referring to the mobile phone platform / mobile phone emulator platform) memor...
Embodiment 3
[0077] see Figure 5 , the embodiment of the present invention provides an application memory management device, including: a takeover module 301, an allocation module 302 and an addition module 303.
[0078] The takeover module 301 is configured to query the memory application interface for operating memory paging after receiving the application memory request from the application;
[0079] An allocation module 302, configured to allocate a memory block for the application according to the size of the memory page provided by the memory application interface for operating the memory page;
[0080] The adding module 303 is configured to add a guard page at the beginning or end of the memory block allocated for the application, and the guard page is used to provide exception detection for the debugger.
[0081] Wherein, the allocation module 302 is specifically used for:
[0082] Allocating a memory block for the application, and aligning the allocated memory block with the si...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


