Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Memory optimization method, device, system and computer-readable storage medium

An optimization method and memory technology, applied in the direction of computing, multi-program device, program control design, etc., can solve the problems that business modules cannot realize self-service management of business life cycle, instance objects cannot be destroyed, etc., and achieve the effect of convenient data sharing

Active Publication Date: 2021-12-28
GUANGZHOU PINWEI SOFTWARE
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] The main purpose of the present invention is to provide a memory optimization method, which aims to solve the technical problem that the instance object cannot be destroyed when the business module of the existing architecture scheme cannot realize the self-service management of the business life cycle during the program development process of the prior art

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Memory optimization method, device, system and computer-readable storage medium
  • Memory optimization method, device, system and computer-readable storage medium
  • Memory optimization method, device, system and computer-readable storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0034] It should be understood that the specific embodiments described here are only used to explain the present invention, not to limit the present invention.

[0035] The main solution of the embodiment of the present invention is: after the root view controller is initialized, the entry class is mounted to the root view controller; a static weak reference pointer is declared to point to the instance object of the entry class, and through the Static weak reference pointer to obtain the instance object; mount the instance object to the entry class, generate the shared information of the instance object; use the shared information to make the submodule of the root view controller call the instance object, and after the call is completed, close the root view controller and destroy the entry class and the shared information.

[0036] Due to the existing technology in the business module development process, the life cycle of the business module is too long to cause memory leaks,...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a memory optimization method, comprising: after the root view controller is initialized, mounting the entry class to the root view controller; declaring a static weak reference pointer pointing to the instance object of the entry class, and passing The static weak reference pointer obtains the instance object; mounts the instance object to the entry class to generate shared information of the instance object; uses the shared information to make the submodule of the root view controller call The instance object, and after the call is completed, close the root view controller and destroy the entry class and the shared information. The invention also discloses a memory optimization device, system and computer-readable storage medium. The invention realizes the beneficial effect of business flow life cycle management by customizing the startup and shutdown of the business flow life cycle.

Description

technical field [0001] The invention relates to the field of program development, in particular to a memory optimization method, device and computer-readable storage medium. Background technique [0002] In iOS client development, with the continuous growth of the number of users and business volume, the app architecture is also constantly upgraded, and it is increasingly trending towards service componentization and business modularization. However, the so-called business modules are relatively independent in terms of code encapsulation and code file management, but they are not truly independent in terms of memory management. There is still an interdependent relationship between the memory instances of each business module. The module life cycle is too long, which is prone to memory leaks. Because most of the object instances in the business module are hosted on the caller, or on an internal static strong reference object instance, or even on a singleton object. In this ...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): G06F9/50G06F8/34
CPCG06F8/34G06F9/5022
Inventor 甄健鹏
Owner GUANGZHOU PINWEI SOFTWARE
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products