Method for effectively solving insufficient available memory of 32-bit program process space

By splitting functional modules and fusion of windows for 32-bit programs, combining cross-process communication and socket communication, the problem of insufficient memory of 32-bit programs is solved, and more efficient memory usage and user experience optimization is achieved.

CN119311439AActive Publication Date: 2025-01-14SICHUAN MEIKANG PHARM SOFTWARE RES & DEV
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411567620.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-05
Publication Date
2025-01-14
Estimated Expiration
2044-11-05

AI Technical Summary

Technical Problem

When 32-bit programs process large amounts of data or perform complex tasks, they are prone to encounter problems of insufficient available memory, resulting in slow program running, data loss, crashes, system page errors and increased load, affecting user experience and system stability.

Method used

By splitting functional modules of 32-bit programs, developing subfunction modules and subprograms, and performing window fusion and cross-process communication in the shared memory area, using socket technology to realize network communication, expanding the number of processes to break through the limitation of virtual address space .

Benefits of technology

It completely solves the memory limit problem of 32-bit applications, reduces memory usage, improves program performance and user experience, and ensures stable operation of the system and good user interaction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119311439A_ABST
    Figure CN119311439A_ABST
Patent Text Reader

Abstract

The invention provides a method for effectively solving the problem of insufficient available memory of a 32-bit program process space, which comprises the following steps of: analyzing a source code of a main program, and splitting a functional module to obtain a plurality of sub-functional modules; developing a new program matched with the sub-function module, adding a user-defined message processing function into a sub-program of the sub-function module, unifying a scheduling interface of the sub-function module, and completing program packaging of the sub-function module; creating a shared memory area, and fusing the windows of the main program and the subprogram in the shared memory area to obtain a unified interface; performing data interaction and program function scheduling between the windows, and developing a fusion program to complete cross-process communication of window messages; wherein a socket technology is introduced to carry out network communication between programs. According to the method, the memory occupation can be reduced, an application group with complete and operable functions and a complete, continuous and uniform man-machine interaction interface is provided for a user, and the user experience is greatly optimized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer memory management, and in particular to a method for effectively solving the problem of insufficient available memory in a 32-bit program process space. Background Art

[0002] In the Microsoft Windows operating system, due to the limitation of the 32-bit process virtual address space (usually the user mode address space is 2GB or less), when a 32-bit program needs to process a large amount of data or perform complex tasks, it may encounter the problem of insufficient available memory. When the available memory space of the main program of a 32-bit application is insufficient (referred to as insufficient memory), it will have a significant negative impact on the process itself and the operating system, and may cause a variety of problems, including but not limited to:

[0003] 1. Slow program operation: When the memory is insufficient, the operating system will constantly transfer data from the memory to the virtual memory on the hard disk to make room. This frequent data exchange will cause the program to run significantly slower, because the hard disk reads and writes much slower than the memory. 2. Program data loss: Due to insufficient memory, some data is not correctly written to the memory and is lost, affecting the results of program execution. 3. Program crash: Insufficient memory makes it impossible to run the program normally. The program may crash and exit abnormally, affecting the stability and reliability of the program. 4. System page error: When the memory is insufficient, the operating system will frequently perform page exchange, which may lead to an increase in page faults and affect the running efficiency of the program. 5. Increased system load: When the memory is insufficient, the system needs to constantly manage and schedule memory, which will increase the system load and reduce the system's response speed and stability. 6. System crash or freeze: The main program of the running application may suddenly stop working, or the system may freeze completely. This will not only affect the work in progress, but may also cause user data to be lost or damaged.

[0004] These problems will directly affect the user experience and work efficiency. Therefore, for 32-bit programs that occupy a large amount of memory, optimizing their memory usage is crucial to ensure the stable operation of the program and the system and a good user experience. Summary of the invention

[0005] In order to overcome the shortcomings of the prior art, the purpose of the present invention is to provide a method for effectively solving the problem of insufficient available memory in the process space of a 32-bit program, effectively breaking through the operating system's limitation on available memory in the virtual address space of a 32-bit application, reducing memory usage, and providing users with a complete and continuous application group with a complete and unified human-computer interaction interface, thereby greatly optimizing the user experience.

[0006] To achieve the above object, the present invention provides the following solution: a method for effectively solving the problem of insufficient available memory in a 32-bit program process space, comprising the following steps:

[0007] Obtaining an application main program, analyzing the source code of the application main program to obtain a functional module in the application main program that has memory requirements, and then splitting the functional module according to the memory requirements to obtain a plurality of sub-functional modules and sub-programs of the sub-functional modules;

[0008] Develop new programs that are compatible with the sub-function modules according to the different sub-function modules, add custom message processing functions to the sub-programs of the sub-function modules, unify the scheduling interfaces of the sub-function modules, and complete the program encapsulation of the sub-function modules;

[0009] Creating a shared memory area, and in the shared memory area, using a window API function, merging the windows of the main application program and the subprogram to complete appearance fusion and obtain a unified interface;

[0010] Use window API functions to exchange data between windows and schedule program functions, and complete cross-process communication of window messages;

[0011] Socket technology is introduced to enable network communication between the main application program, subprograms and new programs.

[0012] Optionally, obtaining an application main program, analyzing the source code of the application main program, obtaining a functional module in the application main program that has memory requirements, and then splitting the functional module according to the memory requirements to obtain multiple sub-functional modules and sub-programs of the sub-functional modules, including:

[0013] Obtaining an application main program, analyzing the source code of the application main program, and obtaining functional modules in the application main program that require memory;

[0014] Based on the memory requirement of 1 GB to 1.4 GB, the functional module is split to obtain a plurality of sub-functional modules and subroutines of the sub-functional modules;

[0015] All the sub-functional modules are analyzed to determine whether there is a sub-functional module with a memory requirement exceeding 2 GB. If the determination result is yes, the sub-functional module with a memory requirement exceeding 2 GB is split into multiple low-demand functional modules.

[0016] Optionally, a new program adapted to the sub-function module is developed according to different sub-function modules, and a custom message processing function is added to the sub-program of the sub-function module, the scheduling interface of the sub-function module is unified, and the program encapsulation of the sub-function module is completed, including:

[0017] Develop new programs according to different sub-function modules and low-demand function modules; wherein the number of the new programs is the sum of the sub-function modules and the low-demand function modules;

[0018] According to the input and output parameters of each functional module, a scheduling interface is designed in the subroutine of each functional module, and the scheduling interface is trimmed to complete the unification of the subroutine scheduling interface;

[0019] Introduce custom message processing functions into the main window message loop of each subroutine to perform cross-process message driving functions and complete the encapsulation of all functional modules.

[0020] Optionally, create a shared memory zone, including:

[0021] Based on the sub-function modules, a new computer program is created to obtain a new main program;

[0022] A blank window is created in the new main program, and the blank window is set as the parent window of the subprogram; wherein the number of the blank windows is the same as the number of the subwindows to be displayed in the subprogram and corresponds one to one.

[0023] Optionally, using a window API function, the windows of the main application program and the subprogram are merged to complete the appearance fusion and obtain a unified interface, including:

[0024] When the main application program is running, the CreateProcess function is called to start the new main program and the subprogram using the main application program, and then the FindWindowEx function is called to find out the windows of all the subprograms;

[0025] Calling SetParent function to designate the blank window of the new main program as the parent window of the subprogram;

[0026] The SetWindowPos function is called to adjust the display position and size of the child window of the subroutine in the parent window, so as to realize the fusion and cooperative operation between the child window and the parent window.

[0027] Optionally, using the window API function to perform data interaction and program function scheduling between windows, and developing a fusion program for sharing and interacting between the subroutines to complete cross-process communication of window messages, including:

[0028] One or more message identifiers for distinguishing different message types are defined between the sending process and the receiving process of the program; the message identifiers are user-defined message identifiers;

[0029] Calling the FindWindowEx function to find the window handle of the receiving process, and according to the window handle of the receiving process, the sending process uses the SendMessage or PostMessage function to send a message to the receiving process;

[0030] According to the customized message type, the window procedure is rewritten using the receiving window to perform an operation corresponding to the customized message;

[0031] The receiving process uses the SendMessage or PostMessage function to return the processing result of the custom message to the target window message queue of the sending process for processing.

[0032] The present invention provides a method for effectively solving the problem of insufficient available memory in a 32-bit program process space, and discloses the following technical effects:

[0033] 1. Completely solve the problem of available memory limitation faced by 32-bit applications: According to the technical solution of the present invention, a multi-process design is performed for the target 32-bit application, and each process can have a maximum process space of 4GB. By expanding the number of processes, the problem of insufficient available memory for the application can be completely solved.

[0034] 2. Reduce memory usage: After splitting a 32-bit application that occupies a lot of memory into multiple sub-programs, the memory occupied by a single program will be significantly reduced, which helps to improve the overall performance of the program and reduce problems such as program crashes caused by insufficient memory. In addition, by creating a shared memory area, multiple processes can access the same memory space to achieve fast reading, writing and sharing of data. However, attention should be paid to synchronization and mutual exclusion issues to avoid data competition and inconsistency.

[0035] 3. Modular development: Through program splitting and encapsulation, complex functions can be divided into independent subprograms for development. This helps to improve the maintainability and reusability of the code and reduce development and maintenance costs.

[0036] 4. User experience optimization: Use window fusion technology to integrate windows of multiple processes into the main program interface, while the window functions are managed by the processes to which they belong, and the operating system is responsible for resource scheduling. This not only maintains the unity and consistency of the user interface, but also enables users to get faster operation response, smoother human-computer interaction, and better user operation experience.

[0037] 5. Socket communication: In more complex scenarios, you can use socket communication technology to achieve network communication between applications. Through sockets, you can achieve cross-network and cross-platform data exchange and functional collaboration.

[0038] The technical solution of the present invention is further described in detail below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0040] Figure 1 A schematic diagram of a method flow chart provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0041] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0042] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0043] In the Microsoft Windows operating system, all system resources are allocated for processes. The operating system allocates an independent 4GB virtual address space for each 32-bit application process, of which about 2GB (or less) is the user mode address space. The user's application code and running data all share this 2GB address space. If there is a 32-bit application A (referred to as program A) that needs to store more than 2GB (for example, 6GB) of data in the process space during operation, then the process will encounter the problem of insufficient available memory in the process space. At this time, program A may experience program function abnormalities, program data loss, or program crashes during operation, and in severe cases, it may even affect the stability of the operating system itself. In general, all 32-bit applications running in the Microsoft Windows operating system environment cannot break through the maximum 4GB process space limit of a single process, which is determined by the design and implementation of the operating system itself.

[0044] The present invention can solve the practical problem of insufficient available memory in the process space when a 32-bit application stores and uses more than 2GB of data, while meeting the limitation of a single process's maximum process space of 4GB. Taking the aforementioned program A as an example, assuming that its memory requirement during runtime is 6GB, the technical solution described in this application is applied to it, and the steps are as follows:

[0045] like Figure 1 As shown, the present invention provides a method for effectively solving the problem of insufficient available memory in the process space of a 32-bit program, so as to solve the practical problem of insufficient available memory in the process space when a 32-bit application program stores and uses more than 2GB of data while meeting the limitation of a maximum process space of 4GB for a single process. Taking the aforementioned program A as an example, it is assumed that its memory requirement during operation is 6GB. The present invention includes the following steps:

[0046] 1. Program splitting

[0047] Obtain an application main program, analyze the source code of the application main program, obtain functional modules in the application main program that have memory requirements, and then split the functional modules according to the memory requirements to obtain multiple sub-functional modules and sub-programs of the sub-functional modules.

[0048] A computer program is essentially composed of source code statements. From the source code structure of a computer program, multiple source code statements constitute a functional module, and multiple functional modules constitute a computer program. Therefore, a conclusion can be drawn: a complete computer program can be divided into multiple functional modules at the source code level. This conclusion provides the most fundamental technical theoretical support for the technical solution described in this application. The technical solution described in this application is mainly to solve the problem of insufficient memory in the process space. Therefore, in the current step, the aforementioned program A will be split and packaged based on the memory requirement as a metric.

[0049] Program splitting: We first need to analyze the source code of program A, focusing on the functional modules that have memory requirements in the program, and then split program A into functional modules according to the memory requirements. In this process, if there is a functional module with a memory requirement of more than 2GB, it is necessary to analyze the functional module again and split it into multiple sub-functional modules with lower memory requirements. The functional module splitting of program A according to the memory requirement should not be too fine. According to experience, it is recommended to split the functional modules based on the memory requirement of 1-1.4GB. In this example, it is assumed that program A is split into 5 functional modules according to the memory requirement, namely M1, M2, M3, M4, and M5, a total of 5 functional modules, and the maximum memory requirement of a single module is within 1.4GB. At this point, the splitting of program A has been completed.

[0050] 2. Program packaging

[0051] According to the different sub-function modules, new programs adapted to the sub-function modules are developed, and custom message processing functions are added to the sub-programs of the sub-function modules, the scheduling interfaces of the sub-function modules are unified, and the program encapsulation of the sub-function modules is completed.

[0052] Program encapsulation: In the above steps, program A has been split into 5 functional modules, M1, M2, M3, M4, and M5. Next, subroutine encapsulation is performed. Create a new computer program A1, integrate the functional module M1 into program A1; create a new computer program A2, integrate the functional module M2 into program A2... and so on, complete the development of programs A1, A2, A3, A4, and A5. In this process, it is necessary to carefully sort out the input and output parameters of each functional module, and then implement the scheduling interface of the module function in the subroutine that integrates the functional module, and finally add a custom message processing function to the main window message loop of the subroutine to achieve the purpose of using cross-process messages to drive the functional module. According to practical experience, it is recommended to trim the scheduling interface of the functional module in the process of encapsulating the functional module into a subroutine, so as to unify the scheduling interface of the subroutine as much as possible and reduce the complexity of the program. At this point, the work of unpacking and encapsulating program A into 5 subroutines, including programs A1, A2, A3, A4, and A5, has been completed.

[0053] The current step is the most critical step in the present invention. In the present invention, a program with a total memory requirement of 6GB is split into 5 sub-programs with a single memory requirement of less than 1.4GB, so that the application can finally use 6GB of memory space, successfully solving the execution problem of the application with a large memory requirement that cannot be normally executed due to the limitation of the operating system process space.

[0054] 3. Window Fusion Technology

[0055] A shared memory area is created, and in the shared memory area, the windows of the main application program and the subprogram are merged by using a window API function to complete appearance fusion and obtain a unified interface.

[0056] By creating a shared memory area, multiple processes can access the same memory space to achieve fast data reading, writing and sharing. However, attention should be paid to synchronization and mutual exclusion issues to avoid data competition and inconsistency.

[0057] In the Microsoft Windows operating system, the operating system provides a series of window API functions, which greatly facilitate various operations on program windows. Among the API functions related to the technical solution described in this application, the most important functions are 4:

[0058] 1) CreateProcess function: Creates a new process and its main thread. This new process runs the specified executable file.

[0059] 2) FindWindowEx function: Search for a child window that meets the specified conditions in the window list managed by the operating system.

[0060] 3) SetParent function: This function can set the parent window for a child window, and the child window will be displayed in the client area of ​​the parent window.

[0061] 4) SetWindowPos function: This function can be used to display the specified child window at the specified position and size of the parent window.

[0062] Using the above four API functions, you can achieve cross-process window fusion: when the user runs the main program, the main program (calls the CreateProcess function) automatically starts the subprogram, then (calls the FindWindowEx function) finds the windows in all subprograms, then (calls the SetParent function) specifies the window in the main program as the parent window of the subprogram window, and finally (calls the SetWindowPos function) adjusts the display position and size of the subwindow in the parent window, so that the fusion effect of the subwindow and the parent window appears more natural and smooth. In this way, the main program and the subprogram run in coordination, and the windows of all subprograms will be displayed in the corresponding window of the main program, so that they can form a whole visually, providing users with a continuous and unified interface experience.

[0063] Create a shared memory area: After the previous step, program A has been split and encapsulated into five subprograms, namely, programs A1, A2, A3, A4, and A5. In the current step, firstly, a new computer program A0 is created as a new main program after the transformation using the technical solution described in this application, and then, according to the number of subwindows to be displayed in subprograms A1-A5, a one-to-one corresponding blank window is created in the new main program A0 as the parent window of the subwindows in subprograms A1-A5. During the operation of program A0, the above four API functions are used to merge the windows in the subprograms into the parent window corresponding to the main program as needed, and fill the visible area of ​​the parent window, making it look like part of a 32-bit application for users to view and operate.

[0064] Window fusion technology uses the API functions provided by the operating system to achieve the effect of window fusion, allowing windows between different programs to form a visual whole through window fusion technology, providing users with a continuous and unified interface experience.

[0065] 4. Window message technology realizes multi-process communication

[0066] The window API function is used to perform data exchange and program function scheduling between windows, and to complete cross-process communication of window messages; among them, the socket technology is introduced for network communication between programs.

[0067] The biggest feature of the Microsoft Windows operating system is its graphical operating interface, which is based on its message processing mechanism. In the Microsoft Windows operating system, the window is the core of the operating system to provide human-computer interaction functions, and the window message is the basis for the normal operation of the window. Each window has a window procedure to receive the message passed to the window. Its task is to get the message and respond to it. The operating system provides a large number of API functions related to windows and window messages. Among the API functions related to the technical solution described in this application, the most important functions are 2:

[0068] 1)SendMessage function: Sends a message to the specified window and waits for the message to be processed.

[0069] 2) PostMessage function: Posts a message to the message queue of the specified window and then returns immediately.

[0070] In the previous steps, the subprogram window has been merged into the parent window of the main program, but this is only a fusion of appearance. The ownership and function scheduling of each subwindow still belong to the corresponding subprogram. At this time, when there is a need for data interaction between windows or program function scheduling, it is necessary to use the above two API functions to realize the cross-process communication function. Cross-process communication is an important means to realize multi-task parallel processing, resource sharing and data exchange. Using window messages for cross-process communication is a common inter-process communication method in the Windows operating system. The implementation method recommended in the technical solution described in this application is as follows:

[0071] 1) Define message identifiers: Between the sending and receiving processes, you first need to define one or more unique message identifiers. These message identifiers are used to distinguish different message types. Usually, these identifiers can be custom integer constants, or one of the Windows predefined messages (but for clarity and security of cross-process communication, it is recommended to use custom message identifiers).

[0072] 2) Find the target window handle: The sending process needs to know the handle of the receiving process's window in order to send the message to it. This is usually achieved by calling the FindWindowEx function. This function allows you to search for a window handle based on the window's class name or title.

[0073] 3) Sending a message: Once the handle of the receiving window is obtained, the sending process can use the SendMessage or PostMessage function to send a message. The SendMessage function will immediately send the message to the target window and wait for the window to process the message before returning. The PostMessage function only puts the message into the message queue of the target window and then returns immediately without waiting for the message to be processed.

[0074] 4) Processing messages: The receiving process needs to rewrite its window procedure (WindowProcedure) so that it can perform corresponding operations when receiving a custom message. The window procedure is a callback function that receives a message as input and executes corresponding processing logic according to the message type.

[0075] 5) Return result: When the receiving process needs to return the custom message processing result to the sending process, you can also use the SendMessage or PostMessage function to send the custom message to the target window message queue of the sending process, and then the window procedure of the sending process is responsible for receiving and processing.

[0076] The above steps have split program A into five subprograms, A1-A5, and specially written a program A0 as a new main program to merge the subprogram windows. By applying the cross-process communication solution recommended in the current step, you can complete the two-way interaction between the main program A0 and subprograms A1-A5, and the two-way interaction between subprograms A1-A5.

[0077] Cross-process communication is an indispensable part between the operating system and applications, and between applications. It is an important means to achieve multi-task parallel processing, resource sharing and data exchange. Using window messages for cross-process communication is a common inter-process communication method in the Windows operating system. This communication method is simple, efficient and suitable for most situations.

[0078] 5. Socket communication

[0079] In more complex scenarios, socket communication technology can be used to implement network communication between applications (application main program, subprograms and new main program). Through sockets, data exchange and functional collaboration across networks and platforms can be achieved.

[0080] Therefore, the present invention provides a method for effectively solving the problem of insufficient available memory in the process space of 32-bit programs, effectively breaking through the available memory restriction of the operating system on the virtual address space of 32-bit application programs, reducing memory usage, and providing users with a complete and continuous application group with a complete and unified human-computer interaction interface, thereby greatly optimizing the user experience.

[0081] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0082] The principles and implementation methods of the present invention are described in this article using specific examples. The description of the above embodiments is only used to help understand the method and core idea of ​​the present invention. At the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting the present invention.

Claims

1. A method for effectively solving the problem of insufficient available memory in a 32-bit program process space, characterized in that: The following steps are involved: Obtaining an application main program, analyzing the source code of the application main program to obtain a functional module in the application main program that has memory requirements, and then splitting the functional module according to the memory requirements to obtain a plurality of sub-functional modules and sub-programs of the sub-functional modules; Develop new programs that are compatible with the sub-function modules according to the different sub-function modules, add custom message processing functions to the sub-programs of the sub-function modules, unify the scheduling interfaces of the sub-function modules, and complete the program encapsulation of the sub-function modules; Creating a shared memory area, and in the shared memory area, using a window API function, merging the windows of the main application program and the subprogram to complete appearance fusion and obtain a unified interface; Use window API functions to exchange data between windows and schedule program functions, and complete cross-process communication of window messages; Socket technology is introduced to enable network communication between the main application program, subprograms and new programs.

2. The method for effectively solving the problem of insufficient available memory in a 32-bit program process space according to claim 1, characterized in that: Obtaining an application main program, analyzing the source code of the application main program, obtaining a functional module in the application main program that has memory requirements, and then splitting the functional module according to the memory requirements to obtain multiple sub-functional modules and sub-programs of the sub-functional modules, including: Obtaining an application main program, analyzing the source code of the application main program, and obtaining functional modules in the application main program that require memory; Based on the memory requirement of 1 GB to 1.4 GB, the functional module is split to obtain a plurality of sub-functional modules and subroutines of the sub-functional modules; All the sub-functional modules are analyzed to determine whether there is a sub-functional module with a memory requirement exceeding 2 GB. If the determination result is yes, the sub-functional module with a memory requirement exceeding 2 GB is split into multiple low-demand functional modules.

3. The method for effectively solving the problem of insufficient available memory in a 32-bit program process space according to claim 2, characterized in that: Develop new programs that are compatible with the sub-function modules according to different sub-function modules, add custom message processing functions to the sub-programs of the sub-function modules, unify the scheduling interfaces of the sub-function modules, and complete the program encapsulation of the sub-function modules, including: Develop new programs according to different sub-function modules and low-demand function modules; wherein the number of the new programs is the sum of the sub-function modules and the low-demand function modules; According to the input and output parameters of each functional module, a scheduling interface is designed in the subroutine of each functional module, and the scheduling interface is trimmed to complete the unification of the subroutine scheduling interface; Introduce custom message processing functions into the main window message loop of each subroutine to perform cross-process message driving functions and complete the encapsulation of all functional modules.

4. The method for effectively solving the problem of insufficient available memory in a 32-bit program process space according to claim 3, characterized in that: Create a shared memory zone, including: Based on the sub-function modules, a new computer program is created to obtain a new main program; A blank window is created in the new main program, and the blank window is set as the parent window of the subprogram; wherein the number of the blank windows is the same as the number of the subwindows to be displayed in the subprogram and corresponds one to one.

5. The method for effectively solving the problem of insufficient available memory in a 32-bit program process space according to claim 4, characterized in that: Using the window API function, the windows of the main application program and the subprogram are merged to complete the appearance fusion and obtain a unified interface, including: When the main application program is running, the CreateProcess function is called to start the new main program and the subprogram using the main application program, and then the FindWindowEx function is called to find out the windows of all the subprograms; Calling SetParent function to designate the blank window of the new main program as the parent window of the subprogram; The SetWindowPos function is called to adjust the display position and size of the child window of the subroutine in the parent window, so as to realize the fusion and cooperative operation between the child window and the parent window.

6. The method for effectively solving the problem of insufficient available memory in a 32-bit program process space according to claim 5, characterized in that: Use the window API function to exchange data between windows and schedule program functions, and complete cross-process communication of window messages, including: One or more message identifiers for distinguishing different message types are defined between the sending process and the receiving process of the program; the message identifiers are user-defined message identifiers; Calling the FindWindowEx function to find the window handle of the receiving process, and according to the window handle of the receiving process, the sending process uses the SendMessage or PostMessage function to send a message to the receiving process; According to the customized message type, the window procedure is rewritten using the receiving window to perform an operation corresponding to the customized message; The receiving process uses the SendMessage or PostMessage function to return the processing result of the custom message to the target window message queue of the sending process for processing.

Citation Information

Patent Citations

  • Progress invoking method of shared windows

    CN101097529A

  • Application program running method and device

    CN108334404A

  • System and method for an extensible 3D interface programming framework

    US20070169066A1