KR20180097674A - Memory reclaim method and apparatus - Google Patents

Memory reclaim method and apparatus Download PDF

Info

Publication number
KR20180097674A
KR20180097674A KR1020187020861A KR20187020861A KR20180097674A KR 20180097674 A KR20180097674 A KR 20180097674A KR 1020187020861 A KR1020187020861 A KR 1020187020861A KR 20187020861 A KR20187020861 A KR 20187020861A KR 20180097674 A KR20180097674 A KR 20180097674A
Authority
KR
South Korea
Prior art keywords
memory
application
reclaim
memory reclaim
terminal
Prior art date
Application number
KR1020187020861A
Other languages
Korean (ko)
Inventor
빈티안 왕
시시 치우
Original Assignee
후아웨이 테크놀러지 컴퍼니 리미티드
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 후아웨이 테크놀러지 컴퍼니 리미티드 filed Critical 후아웨이 테크놀러지 컴퍼니 리미티드
Publication of KR20180097674A publication Critical patent/KR20180097674A/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • G06F12/0253Garbage collection, i.e. reclamation of unreferenced memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1016Performance improvement
    • G06F2212/1024Latency reduction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1041Resource optimization
    • G06F2212/1044Space efficiency improvement
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/72Details relating to flash memory management
    • G06F2212/7205Cleaning, compaction, garbage collection, erase control

Abstract

본 출원은 컴퓨터 기술 분야에 관한 것으로, 구체적으로는, 메모리 리클레임 방법 및 장치에 관한 것으로서, 적절한 시기에 메모리 리클레임을 수행하지 않음으로써 발생하기 쉬운 어플리케이션 설치의 문제를 해결하기 위한 것이다. 본 출원에서 제공되는 메모리 리클레임 방법은, 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하는 단계; 및 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계를 포함한다. The present invention relates to the field of computer technology, and more particularly, to a method and apparatus for memory reclaim, which solves the problem of application installation that is likely to occur by not performing memory reclaim at an appropriate time. The memory reclaim method provided in the present application includes: monitoring user operation and usage information and memory occupancy information of an application installed in a terminal; And a user operation and use information of an application currently being executed in the terminal if the memory reclaim condition is determined to be satisfied according to at least one of user operation and usage information or memory occupancy information of the application installed in the terminal, Determining an application to be memory reclaimed from currently running applications in the terminal according to the memory occupancy information, and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode.

Description

메모리 리클레임 방법 및 장치Memory reclaim method and apparatus

본 출원은 2015년 12월 31일에 중국특허청에 출원된 중국특허출원 제201511032537.7호(명칭: "메모리 리클레임 방법 및 장치")에 대한 우선권을 주장하며, 이 문헌은 전체가 참조로서 여기에 포함된다.This application claims priority to Chinese patent application No. 201511032537.7 (titled "Memory reclaim method and apparatus") filed on December 31, 2015, the entire contents of which are incorporated herein by reference in their entirety do.

본 출원은 컴퓨터 기술에 관한 것으로서, 구체적으로는 메모리 리클레임 방법 및 장치에 관한 것이다. The present application relates to computer technology, and more particularly, to a memory reclaim method and apparatus.

제조 비용을 고려하여, 통상 단말 장치의 메모리 용량은 상대적으로 작고, 대부분의 경우, 1-2G이다. 현재, 커널은, 가능한 최대로, 메모리를 신청하기 위한 어플리케이션 프로그램의 요건을 충족한다. 그 결과, 모바일폰과 같은 단말 제품에서, 통상은 충분한 메모리(예컨대, 순간적으로 300MB 내지 500MB를 요구하는 어플리케이션)를 신청하지 못하기 때문에, 상대적으로 큰 메모리를 소비하는 카메라와 같은 어플리케이션이 지연되거나, 심지어 시작 또는 실행 과정에서 그 어플리케이션이 반복적으로 꺼지고 다시 시작한다. In consideration of the manufacturing cost, the memory capacity of the terminal device is usually relatively small, and in most cases, it is 1-2G. Currently, the kernel meets the requirements of an application program to apply for memory as much as possible. As a result, in a terminal product such as a mobile phone, an application such as a camera that consumes a relatively large memory is delayed because the application can not apply for an adequate memory (for example, an application requiring 300 MB to 500 MB momentarily) Even during startup or execution, the application is repeatedly turned off and restarted.

리눅스 시스템의 메모리 리클레임 정책은, 메모리가 불충분할 때 메모리 리클레임을 트리거한다. 예컨대, 어플리케이션이 시작되거나 또는 포어그라운드 인터페이스(foreground interface)로 전환될 때, 사용자 모드의 어플리케이션 프로세스는 커널 모드에게 메모리를 신청하고, 그 어플리케이션이 점유하고자 하는 메모리가 시스템 여유 메모리보다 큰 경우 메모리 리클레임이 트리거된다. 구체적으로, LRU(Least Recently Used) 알고리즘을 사용하여 최근에 가장 낮은 빈도로 사용되는 메모리가 리클레임을 위해 선택된다. 또한, 메모리 리클레임은 메모리 내 압축(in-memory compression), 동일 페이지 머징(same page merging), 메모리 세분화(memory defragment) 등을 이용하여 수행될 수 있다. 안드로이드 시스템은 커널 모드에서 여유 메모리 레벨을 설정함으로써 커널 모드에서 메모리 리클레임을 트리거한다. 예컨대, 메모리가 n1 MB보다 적으면, 우선순위가 가장 낮은 어플리케이션 프로세스가 종료되고, 메모리가 그래도 n2(n1<n2) MB보다 적으면, 우선순위가 한 단계 더 높은 어플리케이션 프로세스가 해제된다.The Linux system's memory reclaim policy triggers a memory reclaim when there is insufficient memory. For example, when an application is started or switched to a foreground interface, the application process in the user mode submits the memory to the kernel mode, and if the memory that the application wants to occupy is larger than the system free memory, Is triggered. Specifically, the memory that is used at the lowest frequency recently using the Least Recently Used (LRU) algorithm is selected for reclaim. Memory reclaim may also be performed using in-memory compression, same page merging, memory defragmentation, and the like. The Android system triggers a memory reclaim in kernel mode by setting the free memory level in kernel mode. For example, if the memory is less than n 1 MB, the application process with the lowest priority is terminated, and if the memory is still less than n 2 (n 1 <n 2 ) MB, do.

이상의 두 가지 메모리 리클레임 정책에 따르면, 메모리 리클레임은, 커널 모드에서, 사용 가능한 여유 메모리가 상대적으로 작다는 것을 인식한 때에만 트리거된다. 그러므로, 다음과 같은 일이 발생할 수 있다, 즉, 시스템 내에서 이용률이 상대적으로 낮은 메모리가 적절한 시기에 해제될 수 없다. 메모리 리클레임이, 여유 메모리가 불충분하다는 것을 인식한 후에 트리거되는 경우, 다음과 같은 일이 발생할 수 있다. 즉, 필요한 메모리를 제때에 신청하지 못한 현재 실행 중인 어플리케이션이 지연된다.According to the above two memory reclaim policies, memory reclaim is only triggered in kernel mode when it is recognized that the available free memory is relatively small. Therefore, the following may occur, that is, a memory with a relatively low utilization rate in the system can not be released at an appropriate time. If the memory reclaim is triggered after recognizing that the free memory is insufficient, the following may occur: That is, the currently running application that has failed to timely request the required memory is delayed.

본 출원은, 제때에 수행되지 않는 메모리 리클레임에 의해 발생하기 쉬운 어플리케이션 지연(stalling)의 문제를 어느 정도 해결하기 위한, 메모리 리클레임 방법 및 장치를 제공한다.The present application provides a memory reclaim method and apparatus for resolving a problem of application stalling which is likely to be caused by a memory reclaim that is not performed in time.

본 출원은 메모리 리클레임 방법을 제공하고, 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하는 단계; 및 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계를 사용자 모드에서 실행한다.The present application provides a memory reclaim method, comprising: monitoring user operation and usage information and memory occupancy information of an application installed in a terminal; And a user operation and use information of an application currently being executed in the terminal if the memory reclaim condition is determined to be satisfied according to at least one of user operation and usage information or memory occupancy information of the application installed in the terminal, Determining an application to be memory reclaimed among currently running applications in the terminal according to the memory occupancy information and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode, .

본 출원에서, 메모리 리클레임은 사용자 모드에서 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 상태 및 메모리 점유 상태를 모니터링함으로써 선행적으로 수행되며, 이로써, 어플리케이션이 사용자에 의해 자주 조작되고 사용되며 또 상대적으로 큰 메모리를 점유하는 때, 메모리 리클레임 빈도가 상승하게 되어, 메모리의 정상적 사용을 보장하게 된다.In the present application, memory reclaim is performed proactively by monitoring the user operation and usage status and memory occupancy status of the application installed in the terminal in the user mode, whereby the application is frequently operated and used by the user, When occupying a large memory, the frequency of memory reclaim increases, thereby ensuring normal use of the memory.

일 구현예에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계; 및 현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In one embodiment, determining that a memory reclaim condition is currently satisfied, in accordance with at least one of user operation and usage information and memory occupancy information of an application installed in the terminal is determined based on at least one of a user operation Determining a memory reclaim time interval according to usage information and memory occupancy information; And determining that the memory reclaim condition is currently satisfied when the current time has reached a memory reclaim time indicated by the memory reclaim time interval.

이 구현예에서는, 먼저 메모리 리클레임 시간 간격이 사용자에 의한 어플리케이션 사용의 정기성(regularity)에 따라 결정되고, 그런 다음 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 따라 선행적으로 메모리 리클레임을 수행한다. 이러한 방식에서는, 계획된 리클레임이 메모리에 대해 수행되므로, 단말 내의 가용 여유 메모리가 상대적으로 바람직한 레벨로 유지될 수 있다.In this implementation, the memory reclaim time interval is first determined according to the regularity of application usage by the user, and then the memory reclaim time interval, which is indicated by the memory reclaim time interval, . In this way, since the planned reclaim is performed on the memory, the available free memory in the terminal can be maintained at a relatively desirable level.

상술한 구현예에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계의 선택 가능한 방법은, 상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하는 단계; 및 상기 적어도 하나의 미리 설정된 시간 세그먼트 각각에 대해, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하는 단계를 포함한다.In the above-described embodiment, a selectable method of determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal includes selecting at least one Individually determining user operation and use information and memory occupancy information in each of the predetermined time segments; And for each of the at least one predetermined time segment, a memory reclaim time in each time segment, in accordance with user operation and usage information and memory occupancy information in the respective time segment of an application installed in the terminal, And determining the interval individually.

사용자에 의한 어플리케이션의 조작 및 사용의 빈도는 상이한 시간 세그먼트에 따라 상이하다. 그러므로, 이 방식에서는, 상이한 시간 세그먼트에서는 상이한 메모리 리클레임 시간 간격이 사용될 수 있다. 이것은 또한, 메모리 리클레임 타임라인을 향상시키고, 또한 불필요한 메모리 리클레임 과정의 잦은 실행에 의한 시스템 자원 낭비를 피할 수 있다.The frequency of operation and use of the application by the user differs depending on the different time segments. Thus, in this manner, different memory reclaim time intervals may be used in different time segments. This also improves the memory reclaim timeline and avoids wasting system resources due to frequent execution of unnecessary memory reclaim processes.

또 다른 구현예에서, 상기 단말에 설치된 어플리케이션의 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In yet another embodiment, determining that a memory reclaim condition is currently satisfied, in accordance with memory occupancy information of an application installed in the terminal, may include determining that the system free memory is less than a predetermined first threshold, And determining that the condition is currently satisfied.

이 방식에서는, 메모리 부족을 어느 정도 피할 수 있다.In this way, memory shortage can be avoided to some extent.

또 다른 구현예에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 어플리케이션이 시작되거나 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하는 단계; 및 메모리 리클레임을 수행해야 하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In yet another embodiment, determining that a memory reclaim condition is currently satisfied, in accordance with user operation and usage information and memory occupancy information of an application installed in the terminal, means that the application is started or switched to the foreground interface Determining whether to perform a memory reclaim according to the memory occupancy information of the application and the size of the system free memory; And if it is necessary to perform a memory reclaim, determining that the memory reclaim condition is currently satisfied.

새롭게 시작된 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션은 통상 사용자가 사용하려는 어플리케이션이고, 이 방식에서는, 새롭게 시작된 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션의 정상적인 실행이 보장되며, 이로써 시스템 퍼포먼스를 향상시키고 사용자 경험을 향상시킨다.The newly started application or the application that has been switched to the foreground interface is an application that the user normally wants to use. In this way, normal execution of the newly started application or the application converted to the foreground interface is guaranteed, .

또 다른 구현예에서, 상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In yet another embodiment, determining that the memory reclaim condition is currently satisfied in accordance with user operation and usage information of an application installed in the terminal may include determining whether the number of currently running applications in the background is greater than a predetermined And if it exceeds the allowed amount, determining that the memory reclaim condition is currently satisfied.

또한, 여기서, 백그라운드에서 실행될 수 있는 어플리케이션의 허용 수량은 현재 여유 메모리의 크기에 따라 시간 간격에 설정될 수 있다. 백그라운드에서 실행되는 어플리케이션은 통상 사용자에 의해 현재 사용되는 어플리케이션이 아니기 때문에, 불필요한 과도한 메모리 점유를 이러한 어플리케이션의 수량을 제한함으로써 피할 수 있다.Here, the allowed number of applications that can be executed in the background can be set in the time interval according to the size of the current free memory. Applications running in the background are typically not currently used by users, so unnecessary excessive memory occupation can be avoided by limiting the quantity of these applications.

상술한 구현예에서, 상기 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계의 선택 가능한 방식은, 메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및 메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계를 포함한다.In the above-described implementation, a selectable method of determining the application to be memory-reclaimed and performing a memory reclaim by invoking a memory reclaim interface provided by kernel mode is to select a memory reclaim Selecting an application that is not currently operated or used by a user as an application currently running on the terminal according to a pre-stored priority order of the application, and if the current time is a high-probability use time segment of the selected application , Wherein the high probability usage time segment of the application is determined based on user operation and usage information of the application and if the current time is not within the high probability usage time segment of the selected application Determining that the selected application is an application to be memory reclaimed and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode; And repeating the steps until the memory reclaim termination condition is satisfied.

이 방식에서, 우선순위가 상대적으로 낮은 어플리케이션의 메모리(이 어플리케이션은 통상 사용자에 의해 자주 사용되는 어플리케이션이 아니다)가 우선적으로 리클레임 대상으로 선택된다. 현재 시간은 그 어플리케이션의 고확율 실행 시간 세그먼트 내에 있지 않으며, 이로써 시스템 퍼포먼스를 향상시키고 사용자 경험을 향상시킬 수 있다.In this way, the memory of the application with a relatively low priority (this application is usually not an application frequently used by the user) is preferentially selected for reclaim. The current time is not in the application's high-probability runtime segment, which can improve system performance and improve the user experience.

상술한 구현예에서, 상기 메모리 리클레임 종료 조건은 다음의 조건:In the above-described embodiment, the memory reclaim termination condition is satisfied under the following conditions:

상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;When the size of the system free memory is larger than a predetermined second threshold value;

현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;When the memory requested by the currently started application is smaller than the system free memory;

포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및The memory required by the application switched to the foreground interface is smaller than the system free memory; And

백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background

중 하나 이상을 포함한다.&Lt; / RTI &gt;

또한, 메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서가 다음의 단계:In addition, the priority order of applications that need memory reclaim is the following:

어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And

각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -Determining a memory re-claim priority order of an application in each group according to a use frequency range corresponding to each group; the applications in the same group have the same priority order;

에 따라 설정된다..

또 다른 구현예에서, 상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라, 상기 메모리 리클레임 조건이 충족된 것으로 결정되면, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계는, 상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하는 단계를 포함한다.In another embodiment, if it is determined that the memory reclaim condition is satisfied according to user operation and usage information of an application installed in the terminal, a memory reclaim interface provided by the kernel mode is called to request a memory reclaim Wherein the determining step determines that the memory reclaim condition is currently satisfied if it is detected that the period in which the application at the terminal remains in the background exceeds a predetermined period, And reclaiming the memory of the application whose period of stay in the background exceeds the predetermined period.

여기서, 백그라운드에의 체류 기간이 상대적으로 긴 어플리케이션은 통상 현재 구간의 시간 동안 사용자에 의해 조작되지 않는 어플리케이션이고, 어플리케이션의 메모리가 해제됨으로써 메모리가 더 필요한 어플리케이션에 제공되며, 이로써 메모리의 효과적인 이용률을 개선시킬 수 있다.Here, an application in which a residence time in the background is relatively long is an application that is not normally operated by the user during the current period of time, and the memory of the application is released, thereby providing an application requiring more memory, thereby improving the effective utilization rate of the memory .

본 출원은 메모리 리클레임 장치를 제공하며, 이 장치는, The present application provides a memory reclaim device,

사용자 모드에서, 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하도록 구성된 결정 모듈; 및A determination module configured to monitor user operation and use information and memory occupancy information of an application installed in the terminal in a user mode; And

상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하도록 구성된 메모리 리클레임 모듈If the memory reclaim condition is determined to be satisfied at present according to at least one of the user operation and use information or memory occupancy information of the application installed in the terminal, user operation and use information of an application currently being executed in the terminal, A memory reclaim module configured to determine an application to be memory reclaimed from currently running applications in the terminal according to the memory occupancy information and to perform a memory reclaim by calling a memory reclaim interface provided by the kernel mode,

을 포함한다..

본 출원에서, 메모리 리클레임은 사용자 모드에서 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 상태 및 메모리 점유 상태를 모니터링함으로써 선행적으로 수행되며, 이로써, 어플리케이션이 사용자에 의해 자주 조작되고 사용되며 또 상대적으로 큰 메모리를 점유하는 때, 메모리 리클레임 빈도가 상승하게 되어, 메모리의 정상적 사용을 보장하게 된다.In the present application, memory reclaim is performed proactively by monitoring the user operation and usage status and memory occupancy status of the application installed in the terminal in the user mode, whereby the application is frequently operated and used by the user, When occupying a large memory, the frequency of memory reclaim increases, thereby ensuring normal use of the memory.

일 구현예에서, 상기 메모리 리클레임 모듈은 구체적으로,In one implementation, the memory reclaim module is, in particular,

상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하고, 현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.Determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal, and when the current time reaches a memory reclaim time indicated by the memory reclaim time interval, It is configured to determine that the memory reclaim condition is currently satisfied.

이 구현예에서는, 먼저 메모리 리클레임 시간 간격이 사용자에 의한 어플리케이션 사용의 정기성(regularity)에 따라 결정되고, 그런 다음 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 따라 선행적으로 메모리 리클레임을 수행한다. 이러한 방식에서는, 계획된 리클레임이 메모리에 대해 수행되므로, 단말 내의 가용 여유 메모리가 상대적으로 바람직한 레벨로 유지될 수 있다.In this implementation, the memory reclaim time interval is first determined according to the regularity of application usage by the user, and then the memory reclaim time interval, which is indicated by the memory reclaim time interval, . In this way, since the planned reclaim is performed on the memory, the available free memory in the terminal can be maintained at a relatively desirable level.

상술한 구현예에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 선택 가능한 방법은, 상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하는 단계; 및 상기 적어도 하나의 미리 설정된 시간 세그먼트 각각에 대해, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하는 단계를 포함한다.In the above-described embodiment, a selectable method for determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal includes at least one preset Determining, at each of the time segments, user operation and usage information and memory occupancy information separately; And for each of the at least one predetermined time segment, a memory reclaim time in each time segment, in accordance with user operation and usage information and memory occupancy information in the respective time segment of an application installed in the terminal, And determining the interval individually.

사용장 의한 어플리케이션의 조작 및 사용의 빈도는 상이한 시간 세그먼트에 따라 상이하다. 그러므로, 이 방식에서는, 상이한 시간 세그먼트에서는 상이한 메모리 리클레임 시간 간격이 사용될 수 있다. 이것은 또한, 메모리 리클레임 타임라인을 향상시키고, 또한 불필요한 메모리 리클레임 과정의 잦은 실행에 의한 시스템 자원 낭비를 피할 수 있다.The frequency of operation and use of applications that are in use depends on different time segments. Thus, in this manner, different memory reclaim time intervals may be used in different time segments. This also improves the memory reclaim timeline and avoids wasting system resources due to frequent execution of unnecessary memory reclaim processes.

또 다른 구현예에서, 메모리 리클레임 모듈은 구체적으로, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.In another embodiment, the memory reclaim module is configured to determine that the memory reclaim condition is currently satisfied, in particular if it is determined that the system free memory is less than a predetermined first threshold.

이 방식에서, 메모리 부족을 피할 수 있다.In this way, memory shortages can be avoided.

또 다른 구현예에서, 상기 메모리 리클레임 모듈은 구체적으로, In yet another embodiment, the memory reclaim module is, in particular,

어플리케이션이 시작되거나 또는 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하고, 메모리 리클레임을 수행해야 하는 경우, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.When it is detected that the application is started or switched to the foreground interface, it is determined whether to perform the memory reclaim according to the memory occupancy information of the application and the size of the system free memory. If the memory reclaim is to be performed, It is configured to determine that the memory reclaim condition is currently satisfied.

새롭게 시작된 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션은 통상 사용자가 사용하려는 어플리케이션이고, 이 방식에서는, 새롭게 시작된 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션의 정상적인 실행이 보장되며, 이로써 시스템 퍼포먼스를 향상시키고 사용자 경험을 향상시킨다.The newly started application or the application that has been switched to the foreground interface is an application that the user normally wants to use. In this way, normal execution of the newly started application or the application converted to the foreground interface is guaranteed, .

또 다른 구현예에서, 상기 메모리 리클레임 모듈은 구체적으로, 백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.In another embodiment, the memory reclaim module specifically determines that the memory reclaim condition is currently satisfied if the number of applications currently running in the background exceeds a predetermined allowable number of applications that can be executed in the background .

또한, 여기서, 백그라운드에서 실행될 수 있는 어플리케이션의 허용 수량은 현재 여유 메모리의 크기에 따라 시간 간격에 설정될 수 있다. 백그라운드에서 실행되는 어플리케이션은 통상 사용자에 의해 현재 사용되는 어플리케이션이 아니기 때문에, 불필요한 과도한 메모리 점유를 이러한 어플리케이션의 수량을 제한함으로써 피할 수 있다.Here, the allowed number of applications that can be executed in the background can be set in the time interval according to the size of the current free memory. Applications running in the background are typically not currently used by users, so unnecessary excessive memory occupation can be avoided by limiting the quantity of these applications.

상술한 구현예에서, 상기 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 선택 가능한 방식은, 메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및 메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계를 포함한다.In the above-described implementation, a selectable method for determining an application to be memory reclaimed and performing a memory reclaim by invoking a memory reclaim interface provided by kernel mode is to select an application to be memory reclaimed Selecting an application that is not operated or used by a user as an application currently running in the terminal according to a pre-stored priority order, and if the current time is within a high-probability use time segment of the selected application Wherein the high probability usage time segment of the application is determined based on user operation and usage information of the application and if the current time is not in the high probability usage time segment of the selected application, Selected applications comprising: determining that the application to the reclaim memory, and perform memory reclaim by calling reclaim memory interface provided by the kernel-mode; And repeating the steps until the memory reclaim termination condition is satisfied.

이 방식에서, 우선순위가 상대적으로 낮은 어플리케이션의 메모리(이 어플리케이션은 통상 사용자에 의해 자주 사용되는 어플리케이션이 아니다)가 우선적으로 리클레임 대상으로 선택된다. 현재 시간은 그 어플리케이션의 고확율 실행 시간 세그먼트 내에 있지 않으며, 이로써 시스템 퍼포먼스를 향상시키고 사용자 경험을 향상시킬 수 있다.In this way, the memory of the application with a relatively low priority (this application is usually not an application frequently used by the user) is preferentially selected for reclaim. The current time is not in the application's high-probability runtime segment, which can improve system performance and improve the user experience.

상술한 구현예에서, 상기 메모리 리클레임 종료 조건은 다음의 조건:In the above-described embodiment, the memory reclaim termination condition is satisfied under the following conditions:

상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;When the size of the system free memory is larger than a predetermined second threshold value;

현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;When the memory requested by the currently started application is smaller than the system free memory;

포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및The memory required by the application switched to the foreground interface is smaller than the system free memory; And

백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background

중 하나 이상을 포함한다.&Lt; / RTI &gt;

또한, 메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서가 다음의 단계:In addition, the priority order of applications that need memory reclaim is the following:

어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And

각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -Determining a memory re-claim priority order of an application in each group according to a use frequency range corresponding to each group; the applications in the same group have the same priority order;

에 따라 설정된다..

또, 상기 메모리 리클레임 모듈은 구체적으로, In addition, the memory reclaim module is, specifically,

어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및 각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -에 따라 메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서를 설정하도록 구성된다.Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And determining a memory re-claim priority order of the application in each group according to the use frequency range corresponding to each group, the application in the same group having the same priority order And is configured to set a ranking order.

또 다른 구현예에서, 상기 메모리 리클레임 모듈은 구체적으로, 상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하도록 구성된다.In another embodiment, the memory reclaim module determines that the memory reclaim condition is currently satisfied when it is detected that the period of time the application in the terminal remains in the background exceeds a predetermined period, The memory reclaim interface provided by the kernel mode is called so that the memory of the application whose period of stay in the background exceeds the predetermined period is reclaimed.

본 출원은 사용자 장비를 제공하고, 이 사용자 장비는, 프로세서, 메모리 및 버스를 포함한다. 이 메모리는 실행 명령을 저장하고 또 내부 메모리 장치 및 외부 메모리 장치를 포함한다. 내부 메모리 장치는 또한 내부 메모리라고도 하며, 프로세서의 동작 데이터 및 하드 디스크와 같은 외부 메모리와 교환되는 데이터를 일시 저장하도록 구성된다. 프로세서는 내부 메모리 장치를 이용하여 외부 메모리와 데이터를 교환하고, 사용자 장비가 실행되는 때, 프로세서 및 메모리는 버스를 이용하여 서로 통신함으로써, 프로세서가 이하의 명령을 사용자 모드에서 실행한다:The present application provides user equipment, which includes a processor, memory and a bus. This memory stores execution commands and also includes an internal memory device and an external memory device. The internal memory device is also referred to as an internal memory, and is configured to temporarily store operation data of the processor and data exchanged with an external memory such as a hard disk. The processor exchanges data with the external memory using the internal memory device, and when the user equipment is executed, the processor and the memory communicate with each other using the bus so that the processor executes the following commands in user mode:

단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하는 단계; 및 Monitoring user operation and usage information and memory occupancy information of an application installed in the terminal; And

상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계.If the memory reclaim condition is determined to be satisfied at present according to at least one of the user operation and use information or memory occupancy information of the application installed in the terminal, user operation and use information of an application currently being executed in the terminal, Determining an application to be memory reclaimed among the applications currently being executed in the terminal according to the memory occupancy information, and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode.

본 출원에서, 메모리 리클레임은 사용자 모드에서 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 상태 및 메모리 점유 상태를 모니터링함으로써 선행적으로 수행되며, 이로써, 어플리케이션이 사용자에 의해 자주 조작되고 사용되며 또 상대적으로 큰 메모리를 점유하는 때, 메모리 리클레임 빈도가 상승하게 되어, 메모리의 정상적 사용을 보장하게 된다.In the present application, memory reclaim is performed proactively by monitoring the user operation and usage status and memory occupancy status of the application installed in the terminal in the user mode, whereby the application is frequently operated and used by the user, When occupying a large memory, the frequency of memory reclaim increases, thereby ensuring normal use of the memory.

일 구현예에서, 프로세스에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계; 및 현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In one implementation, determining that a memory reclaim condition is currently satisfied, in accordance with at least one of user operation and usage information and memory occupancy information of an application installed in the terminal in an instruction executed by the process, Determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal; And determining that the memory reclaim condition is currently satisfied when the current time has reached a memory reclaim time indicated by the memory reclaim time interval.

이 구현예에서는, 먼저 메모리 리클레임 시간 간격이 사용자에 의한 어플리케이션 사용의 정기성(regularity)에 따라 결정되고, 그런 다음 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 따라 선행적으로 메모리 리클레임을 수행한다. 이러한 방식에서는, 계획된 리클레임이 메모리에 대해 수행되므로, 단말 내의 가용 여유 메모리가 상대적으로 바람직한 레벨로 유지될 수 있다.In this implementation, the memory reclaim time interval is first determined according to the regularity of application usage by the user, and then the memory reclaim time interval, which is indicated by the memory reclaim time interval, . In this way, since the planned reclaim is performed on the memory, the available free memory in the terminal can be maintained at a relatively desirable level.

상술한 구현예에서, 프로세서에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계의 선택 가능한 방법은, 상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하는 단계; 및 상기 적어도 하나의 미리 설정된 시간 세그먼트 각각에 대해, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하는 단계를 포함한다.In the above-described embodiment, in the instruction executed by the processor, the selectable method of determining the memory reclaim time interval according to the user operation and use information of the application installed in the terminal and the memory occupancy information, Individually determining user operation and usage information and memory occupancy information in each of at least one predetermined time segment of an application installed in the application; And for each of the at least one predetermined time segment, a memory reclaim time in each time segment, in accordance with user operation and usage information and memory occupancy information in the respective time segment of an application installed in the terminal, And determining the interval individually.

사용장 의한 어플리케이션의 조작 및 사용의 빈도는 상이한 시간 세그먼트에 따라 상이하다. 그러므로, 이 방식에서는, 상이한 시간 세그먼트에서는 상이한 메모리 리클레임 시간 간격이 사용될 수 있다. 이것은 또한, 메모리 리클레임 타임라인을 향상시키고, 또한 불필요한 메모리 리클레임 과정의 잦은 실행에 의한 시스템 자원 낭비를 피할 수 있다.The frequency of operation and use of applications that are in use depends on different time segments. Thus, in this manner, different memory reclaim time intervals may be used in different time segments. This also improves the memory reclaim timeline and avoids wasting system resources due to frequent execution of unnecessary memory reclaim processes.

또 다른 구현예에서, 프로세서에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In another embodiment, in the instructions executed by the processor, determining that a memory reclaim condition is currently satisfied, in accordance with memory occupancy information of an application installed in the terminal, means that the system free memory is less than a predetermined first threshold Determining that the memory reclaim condition is currently satisfied.

이 방식에서는, 메모리 부족을 어느 정도 피할 수 있다.In this way, memory shortage can be avoided to some extent.

또 다른 구현예에서, 프로세서에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 어플리케이션이 시작되거나 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하는 단계; 및 메모리 리클레임을 수행해야 하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In yet another embodiment, determining that a memory reclaim condition is currently satisfied, in accordance with user operation and usage information and memory occupancy information of an application installed in the terminal, in an instruction executed by the processor, Determining whether to perform a memory reclaim according to the memory occupancy information of the application and the size of the system free memory when the switching to the foreground interface is detected; And if it is necessary to perform a memory reclaim, determining that the memory reclaim condition is currently satisfied.

새롭게 시작된 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션은 통상 사용자가 사용하려는 어플리케이션이고, 이 방식에서는, 새롭게 시작된 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션의 정상적인 실행이 보장되며, 이로써 시스템 퍼포먼스를 향상시키고 사용자 경험을 향상시킨다.The newly started application or the application that has been switched to the foreground interface is an application that the user normally wants to use. In this way, normal execution of the newly started application or the application converted to the foreground interface is guaranteed, .

또 다른 구현예에서, 프로세서에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.In another embodiment, determining that the memory reclaim condition is currently satisfied, in accordance with user operation and usage information of an application installed in the terminal, in an instruction executed by the processor means that the number of currently executing applications in the background is Determining that the memory reclaim condition is currently satisfied if the predetermined allowable quantity of applications that can be executed in the background is exceeded.

또한, 여기서, 백그라운드에서 실행될 수 있는 어플리케이션의 허용 수량은 현재 여유 메모리의 크기에 따라 시간 간격에 설정될 수 있다. 백그라운드에서 실행되는 어플리케이션은 통상 사용자에 의해 현재 사용되는 어플리케이션이 아니기 때문에, 불필요한 과도한 메모리 점유를 이러한 어플리케이션의 수량을 제한함으로써 피할 수 있다.Here, the allowed number of applications that can be executed in the background can be set in the time interval according to the size of the current free memory. Applications running in the background are typically not currently used by users, so unnecessary excessive memory occupation can be avoided by limiting the quantity of these applications.

상술한 구현예에서, 프로세서에 의해 실행되는 명령에서, 상기 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계의 선택 가능한 방식은, 메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및 메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계를 포함한다.In the above-described implementation, in an instruction executed by a processor, a selectable method of determining an application to be subjected to the memory reclaim and performing a memory reclaim by invoking a memory reclaim interface provided by the kernel mode Selects an application that is not operated or used by a user as an application that is currently being executed in the terminal according to a pre-stored priority order of applications to be memory-reclaimed, and the current time is the high- Probability use time segment, wherein the high-probability lapse time segment of the application is determined based on user operation and usage information of the application, and wherein the current time is a high probability of the selected application Determining that the selected application is a memory reclaim application if it is not in the use time segment and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode; And repeating the steps until the memory reclaim termination condition is satisfied.

이 방식에서, 우선순위가 상대적으로 낮은 어플리케이션의 메모리(이 어플리케이션은 통상 사용자에 의해 자주 사용되는 어플리케이션이 아니다)가 우선적으로 리클레임 대상으로 선택된다. 현재 시간은 그 어플리케이션의 고확율 실행 시간 세그먼트 내에 있지 않으며, 이로써 시스템 퍼포먼스를 향상시키고 사용자 경험을 향상시킬 수 있다.In this way, the memory of the application with a relatively low priority (this application is usually not an application frequently used by the user) is preferentially selected for reclaim. The current time is not in the application's high-probability runtime segment, which can improve system performance and improve the user experience.

상술한 구현예에서, 상기 메모리 리클레임 종료 조건은 다음의 조건:In the above-described embodiment, the memory reclaim termination condition is satisfied under the following conditions:

상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;When the size of the system free memory is larger than a predetermined second threshold value;

현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;When the memory requested by the currently started application is smaller than the system free memory;

포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및The memory required by the application switched to the foreground interface is smaller than the system free memory; And

백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background

중 하나 이상을 포함한다.&Lt; / RTI &gt;

또한, 프로세서에 의해 실행되는 명령에서, 메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서가 다음의 단계:In addition, in an instruction executed by the processor, the order of priority of applications that need to reclaim memory is the following:

어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And

각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -Determining a memory re-claim priority order of an application in each group according to a use frequency range corresponding to each group; the applications in the same group have the same priority order;

에 따라 설정된다..

또 다른 구현예에서, 프로세서에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라, 상기 메모리 리클레임 조건이 충족된 것으로 결정되면, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계는, 상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하는 단계를 포함한다.In another embodiment, if it is determined in the instruction executed by the processor that the memory reclaim condition is satisfied in accordance with the user operation and usage information of the application installed in the terminal, the memory reclaim provided by the kernel mode Wherein the step of determining whether the memory reclaim condition satisfies the memory reclaim condition is satisfied when the period in which the application in the terminal exceeds the predetermined period of time is determined to be in the background, Reclaiming a memory of an application whose period of stay in the background exceeds a predetermined period by calling a memory reclaim interface provided by the memory reclaim interface.

여기서, 백그라운드에의 체류 기간이 상대적으로 긴 어플리케이션은 통상 현재 구간의 시간 동안 사용자에 의해 조작되지 않는 어플리케이션이고, 어플리케이션의 메모리가 해제됨으로써 메모리가 더 필요한 어플리케이션에 제공되며, 이로써 메모리의 효과적인 이용률을 개선시킬 수 있다.Here, an application in which a residence time in the background is relatively long is an application that is not normally operated by the user during the current period of time, and the memory of the application is released, thereby providing an application requiring more memory, thereby improving the effective utilization rate of the memory .

도 1은 본 출원에 따른 메모리 리클레임의 개략 모식도이다.
도 2는 본 출원의 실시예 1에 따른 메모리 리클레임 방법의 흐름도이다.
도 3은 본 출원의 실시예 2에 따른 메모리 리클레임 방법의 흐름도이다.
도 4는 본 출원의 실시예 3에 따른 메모리 리클레임 방법의 흐름도이다.
도 5는 본 출원의 실시예에 따른 메모리 리클레임 장치(50)의 개략 구성도이다.
도 6은 본 출원의 실시예에 따른 사용자 장비(60)의 개략 구성도이다.
도 7은 본 출원에 따른 단말 장치(700)의 개략 구성도이다.
도 8은 본 출원의 실시예에 따른 단말(800)의 개략 구성도이다.
1 is a schematic diagram of a memory reclaim according to the present application.
2 is a flowchart of a memory reclaim method according to the first embodiment of the present application.
3 is a flowchart of a memory reclaim method according to the second embodiment of the present application.
4 is a flowchart of a memory reclaim method according to the third embodiment of the present application.
5 is a schematic configuration diagram of a memory reclaim apparatus 50 according to an embodiment of the present application.
6 is a schematic block diagram of a user equipment 60 according to an embodiment of the present application.
7 is a schematic configuration diagram of the terminal device 700 according to the present application.
8 is a schematic configuration diagram of a terminal 800 according to an embodiment of the present application.

도 1을 참조하면, 도 1은 본 출원에 따른 메모리 리클레임의 개략 모식도이다. 본 출원에서, 메모리 리클레임은, 커널 모드에 의해 제공된 메모리 리클레임 인터페이스를 사용하여 그리고 메모리 리클레임 정책을 사용자 모드에서 실행함으로써 수행된다. 구체적으로, 메모리 리클레임은 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링함으로써 트리거된다. 메모리 리클레임 조건이 충족된 후, 메모리 리클레임을 해야 할 어플리케이션이, 단말에서 현재 실행 중인 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라, 단말에서 현재 실행 중인 어플리케이션으로부터 선택되고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 사용자 모드로 호출함으로써 메모리 리클레임이 수행된다. 본 출원에서는, 사용자 모드에서, 어플리케이션의 메모리 점유 정보, 및 사용자 조작 및 사용 정보를 모니터링하는 것에 의해 선행적으로 수행됨으로써, 어플리케이션이 사용자에 의해 자주 조작되고 사용되며 상대적으로 큰 메모리를 점유하는 경우, 메모리 리클레임 빈도가 상승하고 적시의 메모리 리클레임을 보장한다.Referring to Figure 1, Figure 1 is a schematic diagram of a memory reclaim according to the present application. In the present application, the memory reclaim is performed by using the memory reclaim interface provided by the kernel mode and by executing the memory reclaim policy in the user mode. Specifically, the memory reclaim is triggered by monitoring user operation and usage information of the application installed in the terminal, and memory occupancy information. After the memory reclaim condition is satisfied, an application to be subjected to memory reclaim is selected from an application currently executing in the terminal according to user operation and usage information and memory occupancy information of an application currently running in the terminal, The memory reclaim is performed by invoking the memory reclaim interface provided by the user in user mode. In the present application, when the application is frequently operated and used by the user and occupies a relatively large memory, by performing in advance in the user mode by monitoring the memory occupation information of the application and the user operation and use information, Memory reclaim frequency increases and guarantees timely memory reclaim.

이하에서는 본 출원의 첨부 도면을 참조하여 본 출원의 실시예들을 더 상세히 설명한다.Embodiments of the present application will now be described in more detail with reference to the accompanying drawings of the present application.

실시예 1Example 1

도 2를 참조하면, 도 2는 본 출원의 실시예 1에 따른 메모리 리클레임 방법의 흐름도이고, 이 방법은 사용자 모드에서 다음 단계를 실행한다.Referring to Fig. 2, Fig. 2 is a flow chart of a memory reclaim method according to embodiment 1 of the present application, which performs the following steps in a user mode.

S201: 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링한다.S201: User operation and usage information of the application installed in the terminal and memory occupancy information are monitored.

여기서, 메모리 점유 정보는, 어플리케이션이 실행된 때 점유되는 메모리의 크기를 포함하고, 어플리케이션의 사용자 조작 및 사용 정보는, 사용자에 의한 어플리케이션의 사용 빈도, 사용 시간 세그먼트, 사용 기간 등을 포함한다.Here, the memory occupancy information includes the size of the memory occupied when the application is executed, and the user operation and use information of the application includes the frequency of use of the application by the user, the use time segment, the use period and the like.

구체적인 구현예에서, 단말 시스템 내에서의 각 어플리케이션의 실행 상태 및 그 어플리케이션이 실행되는 때 차지하는 메모리의 크기는, 사용자 모드에서 모니터링 프로세스를 이용하여 실시간으로 모니터링될 수 있다. 사용자에 의한 어플리케이션의 사용 빈도, 사용 시간 세그먼트, 사용 기간 등은 모니터링에 의해 획득된 어플리케이션의 실행 상태를 이용하여 결정될 수 있다. 여기서, 사용자가 어플리케이션을 사용하는 사용 시간 세그먼트는 복수의 미리 설정된 시간 세그먼트 중 사용자가 그 어플리케이션을 사용한 시간 세그먼트이거나, 또는 사용자가 어플리케이션을 조작하기 시작한 순간으로부터 사용자가 어플리케이션 조작을 마친 순간까지의 실제 시간 세그먼트일 수 있다.In a specific implementation, the execution state of each application in the terminal system and the amount of memory occupied when the application is executed can be monitored in real time using the monitoring process in the user mode. The frequency of use of the application by the user, the usage time segment, the usage period, and the like can be determined using the execution state of the application obtained by the monitoring. Here, the usage time segment in which the user uses the application is a time segment in which the user uses the application among a plurality of preset time segments, or an actual time from the moment when the user starts operating the application to the moment when the user completes the application operation Segment.

여기서, 단말 시스템 상의 각 어플리케이션의 실행 상태를 모티터링하는 것은, 어플리케이션 시작 상태, 어플리케이션 종료 상태, 어플리케이션을 백그라운드에서 포어그라운드 인터페이스로 전환하는 상태, 포어그라운드 인터페이스에서 백그라운드로 전환하는 상태 등을 포함할 수 있다. 모니터링 프로세스는, 구체적으로, 질의(query)를 이용하여, 프록 파일 시스템(proc file system)에 의해 제공되는 질의 인터페이스를 이용하여 어플리케이션의 상술한 실행 상태를 획득할 수 있다.Here, monitoring the execution status of each application on the terminal system may include an application start status, an application end status, a status in which the application is switched from the background to the foreground interface, a status in which the foreground interface is switched in the background have. Specifically, the monitoring process can use the query to obtain the above-described execution state of the application using the query interface provided by the proc file system.

구체적인 구현예에서, 상이한 어플리케이션에 대해, 어플리케이션의 사용자 조작 및 사용 정보에 대한 통계를 수집하는 방식이 상이할 수 있다. 예컨대, 사용자에 의해 포어그라운드 인터페이스에서 조작되어야 하는 애플리케이션(예컨대, 위채(WeChat) 또는 캘린더(Calendar))에 대해, 어플리케이션이 시작하거나 포어그라운드 인터페이스로 전환되는 시간을 사용자가 그 어플리케이션을 조작하기 시작한 시간으로 사용할 수 있고, 어플리케이션이 종료되거나 실행을 위한 백그라운드로 전환되는 시간을 사용자가 그 어플리케이션의 조작을 마친 시간으로 사용할 수 있다. 포어그라운드 인터페이스에서 사용자가 항상 조작해야 하는 것이 아닌 애플리케이션(예컨대, 다운 로딩 소프트웨 대해, 어플리케이션이 시작되는 시간을 사용자가 어플리케이션을 조작하기 시작한 시간으로 사용할 수 있고, 어플리케이션이 종료되는 시간을 사용자가 그 어플리케이션의 조작을 마친 시간으로 사용할 수 있다. 사용자가 어플리케이션을 사용하는 사용 빈도, 사용 시간 세그먼트, 사용 기간 등은, 통계치 수집에 의해 획득되는, 사용자가 어플리케이션을 조작하기 시작한 시간과 사용자가 어플리케이션 조작을 종료한 시간에 따라 결정될 수 있다.In a specific implementation, for different applications, the manner of collecting statistics on user operations and usage information of the application may be different. For example, for applications (e.g., WeChat or Calendar) that need to be manipulated at the foreground interface by the user, the time at which the application starts or switches to the foreground interface is the time And the time when the application is terminated or switched to the background for execution can be used as a time when the user has finished operating the application. For an application (e.g., downloading software) in the foreground interface that the user does not always have to manipulate, the time at which the application starts can be used as the time when the user starts to operate the application, The usage frequency, the usage time segment, the usage period, etc., in which the user uses the application, can be calculated based on the time at which the user starts operating the application and the time at which the user ends the application operation It can be decided according to one hour.

S202: 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족되었는지를 결정하고, 메모리 리클레임 조건이 현재 충족되었으면 단계 S203으로 하거나, 또는 메모리 리클레임 조건이 현재 충족되지 않았으면 단계 S201로 돌아간다.S202: It is determined whether or not the memory reclaim condition is currently satisfied according to at least one of the user operation and usage information and the memory occupancy information of the application installed in the terminal. If the memory reclaim condition is currently satisfied, If the memory reclaim condition is not satisfied at present, the process returns to step S201.

구체적인 구현예에서, 사용자 모드에서 메모리 리클레임을 트리거하는 조건은 실제 요건에 따라 설정될 수 있다. 예컨대, 메모리 리클레임 시간 간격은, 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라 결정될 수 있고, 메모리 리클레임은, 미리 설정된 메모리 리크레임 시간 간격에 따라, 계획된 메모리 리클레임을 실행하도록 트리거되고, 이로써 단말 내에서 가용한 여유 메모리가 상대적으로 양호한 레벨로 유지된다. 여기서, 하나 이상의 미리 설정된 메모리 리클레임 시간 간격이 있을 수 있다. 예컨대, 사용자가 하루 전체에서 어플리케이션을 사용한 사용 빈도 및 메모리 점유 모두가 상대적으로 안정적일 때는, 하나의 메모리 리클레임 시간 간격만이 설정될 수 있다. 다르게는, 사용자가 하루 동안 오직 하나의 시간 세그먼트에서 어플리케이션을 집중적으로 사용했고, 어플리케이션을 사용하는 빈도가 안정적이라면, 메모리 리클레임 시간 간격은 이 시간 세그먼트에서만 설정될 수 있고, 다른 시간 세그먼트에서는 메모리 리클레임이 수행되지 않는다. 사용자가 어플리케이션을 사용하는 빈도가 하루 중 상이한 시간 세그먼트에서 크게 변하는 경우, 시스템 여유 메모리가 임계치보다 작은 때 메모리 리클레임이 트리거되거나(메모리 리클레임은 단말에 설치된 어플리케이션의 메모리 점유 정보에 따라 트리거된다); 어플리케이션이 시작되거나 또는 포어그라운드 인터페이스로 전환되는 것이 검출된 때, 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라 메모리 리클레임이 트리거되거나(메모리 리클레임은 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라 트리거된다); 또는 단말의 어플리케이션이 백그라운드에 체류하는 기간이 소정의 기간을 초과한 것을 검출한 때, 메모리 리클레임이 트리거된다(메모리 리클레임은, 어플리케이션의 사용자 조작 및 사용 정보에 따라 트리거된다).In a specific implementation, the conditions that trigger the memory reclaim in the user mode may be set according to actual requirements. For example, the memory reclaim time interval may be determined according to the user operation and usage information and memory occupancy information of the application installed in the terminal, and the memory reclaim may execute the planned memory reclaim according to the preset memory recycle time interval So that the free memory available in the terminal is maintained at a relatively good level. Here, there may be one or more preset memory reclaim time intervals. For example, when the user is relatively stable in both the frequency of use of the application and the occupancy of the memory in the whole day, only one memory reclaim time interval can be set. Alternatively, if the user has intensively used the application in only one time segment for a day and the frequency of using the application is stable, then the memory reclaim time interval may be set only in this time segment, No claims are made. If the frequency with which the user uses the application varies greatly in different time segments of the day, a memory reclaim is triggered when the system free memory is less than the threshold (the memory reclaim is triggered according to the memory occupancy information of the application installed in the terminal) ; When an application is started or when switching to the foreground interface is detected, a memory reclaim is triggered depending on the memory occupancy information of the application and the size of the free memory of the system (the memory reclaim may be triggered by the user operation and usage information And memory occupancy information); Or when the period of time in which the application of the terminal remains in the background exceeds a predetermined period, a memory reclaim is triggered (the memory reclaim is triggered according to the user operation and usage information of the application).

S203: 단말에서 현재 실행 중에 어플리케이션의 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 단말에서 현재 실행 중인 어플리케이션 중에서, 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하는 것에 의해 메모리 리클레임을 수행한다.S203: Determines an application to be subjected to memory reclaim among applications currently being executed in the terminal, based on the user operation and usage information of the application and the memory occupancy information during execution of the terminal at the terminal, Perform memory reclaim by calling the interface.

여기서, 단계 S201 및 S202에서의 단말에 설치된 어플리케이션은 단계 S203에서의 단말에서 현재 실행 중인 어플리케이션을 포함한다. 단계 S203에서의 단말에서 현재 실행 중인 어플리케이션에 더하여, 단말에 설치된 어플리케이션은 현재 종료 상태인 어플리케이션을 더 포함한다.Here, the application installed in the terminal in steps S201 and S202 includes the application currently being executed in the terminal in step S203. In addition to the application currently being executed in the terminal in step S203, the application installed in the terminal further includes an application that is currently in a terminated state.

구체적인 구현예에서, 커널 모드에서의 메모리 리클레임 프로그램은, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 이용하여 사용자 모드에서 메모리 리클레임을 실행하기 위해 호출된다. 메모리 리클레임 인터페이스는 linux procfs 파일 시스템 또는 linux sysfs 파일 시스템과 같은 시스템에 기초하여 구현된다.In a specific implementation, a memory reclaim program in kernel mode is called to execute a memory reclaim in user mode using a memory reclaim interface provided by kernel mode. The memory reclaim interface is implemented based on systems such as the linux procfs file system or the linux sysfs file system.

리눅스 시스템에서, 커널 모드에서의 기존의 메모리 리클레임 매니지먼트는 LRU 알고리즘에 기초하여 구현된다. 기존의 메모리 리클레임 매니지먼트에서는, 어플리케이션에 의해 점유되는 메모리가 2개의 메인 형태: 어나니머스 페이지(anonymous page)(다이내믹 메모리 할당(malloc) 기능에 의해 할당된 메모리와 같은), 및 파일 페이지(fine page)(파일의 판독 및 기록 중에 할당된 메모리와 같은)로 나누어진다. LRU 알고리즘에 따라 최근에 자주 사용되지 않은 메모리는 링크드 리스트(linked list)에 들어가고, 이 링크드 리스트는 리클레임이 수행될 때마다 줄어들어 메모리 페이지(이것은 주로 페이지 캐시(page cache)임)의 일부를 리클레임한다. 커널 모드에서 메모리 리클레임에 사용되는 기본 함수는 try_to_free_pages()이다. 본 출원에서, 함수의 인터페이스는 호출을 위해 사용자 모드에 노출되어 있다. 사용자 모드에서는, 이 출원에서 제공하는 메모리 리클레임 정책에 기초하여 그리고 함수의 인터페이스를 호출하여 구현된다.In Linux systems, existing memory reclaim management in kernel mode is implemented based on the LRU algorithm. In conventional memory reclaim management, the memory occupied by the application is divided into two main types: an anonymous page (such as memory allocated by the dynamic memory allocation (malloc) function), and a file page page (such as memory allocated during file read and write). According to the LRU algorithm, recently unused memory is put into a linked list, which is reduced each time a reclaim is performed, and a portion of the memory page (which is usually the page cache) Claim. The default function used for memory reclaim in kernel mode is try_to_free_pages (). In the present application, the interface of the function is exposed to the user mode for invocation. In user mode, it is implemented based on the memory reclaim policy provided in this application and by calling the interface of the function.

실시예 2Example 2

이하에서는 본 출원의 바람직한 구현예를 설명하고, 이는 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 대한 통계치를 수집함으로써 메모리 리클레임 시간 간격을 결정하는 단계, 및 결정된 메모리 리클레임 시간 간격에 기초하여 메모리 리클레임을 수행하는 단계를 포함한다.Hereinafter, a preferred embodiment of the present application will be described, which includes a step of determining a memory reclaim time interval by collecting statistics on user operation and usage information and memory occupancy information of an application installed in the terminal, And performing a memory reclaim based on the memory reclaim.

도 3을 참조하면, 도 3은 본 출원의 실시예 2에 따른 메모리 리클레임 방법의 흐름도이고, 이 방법은 다음 단계를 사용자 모드에서 실행한다.Referring to FIG. 3, FIG. 3 is a flowchart of a memory reclaim method according to Embodiment 2 of the present application, which executes the next step in a user mode.

S301: 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보를 모니터링한다.S301: User operation and usage information and memory occupancy information of an application installed in the terminal are monitored.

구체적인 구현예에서, 사용자가 어플리케이션을 사용하는 사용 빈도 및 사용 시간 세그먼트와 같은, 어플리케이션의 사용자 조작 및 사용 정보, 그리고 어플리케이션이 실행되는 때 점유되는 메모리의 크기와 같은 메모리 점유 정보에 관한 통계치가 실시간으로 사용자 모드에서 단말 시스템의 각 어플리케이션의 실행 상태를 모니터링함으로써 수집된다.In a specific implementation, statistics on memory occupancy information, such as user usage and usage information of the application, such as frequency of use and usage time segments for which the user is using the application, and the size of memory occupied when the application is executed, And is collected by monitoring the execution status of each application of the terminal system in the user mode.

S302: 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정한다.S302: The memory reclaim time interval is determined according to the user operation and usage information and memory occupancy information of the application installed in the terminal.

여기서, 메모리 리클레임 시간 간격은 단계 S301에서 통계치 수집에 의해 획득된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라 결정될 수 있다. 하나 이상의 메모리 리클레임 시간 간격이 있을 수 있다. 예컨대, 하루 중 사용자가 어플리케이션을 사용하는 사용 빈도 및 메모리 점유가 상대적으로 일정한 경우, 오직 하나의 메모리 리클레임 시간 간격이 설정될 수 있다. 사용자가 어플리케이션을 사용하는 사용 빈도가 하루 중 상이한 시간 세그먼트에서 상이한 경우, 하루 중 상이한 시간 세그먼트에서 상이한 메모리 리클레임 시간 간격이 사용될 수 있다. 예컨대, 어플리케이션이 자주 사용되고 상대적으로 큰 메모리가 점유되는 시간 세그먼트에서 더 자주 메모리 리클레임이 수행될 수 있다. 반대로, 어플리케이션이 자주 사용되지 않고 상대적으로 작은 메모리가 점유되는 시간 세그먼트에서는 메모리 리클레임을 덜 자주 수행할 수 있다.Here, the memory reclaim time interval may be determined according to the user operation and usage information and memory occupancy information of the application obtained by the statistical collection in step S301. There may be more than one memory reclaim time interval. For example, only one memory reclaim time interval may be set if the frequency of use and memory occupancy by a user during a day is relatively constant. If the frequency of use of the application by the user is different in different time segments of the day, different memory reclaim time intervals may be used in different time segments of the day. For example, a memory reclaim may be performed more frequently in a time segment where an application is frequently used and a relatively large amount of memory is occupied. Conversely, memory reclaims can be performed less frequently in time segments where applications are not used often and relatively small amounts of memory are occupied.

구체적인 구현예에서, 복수의 시간 세그먼트가 경험에 따라 미리 설정될 수 있다. 미리 설정된 시간 세그먼트에서, 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보, 및 메모리 점유 정보가 결정된다. 각각의 미리 설정된 시간 세그먼트에서 메모리 리클레임 시간 간격은, 미리 설정된 시간 세그먼트에서의, 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라 결정된다.In a specific implementation, a plurality of time segments may be preset according to experience. In the preset time segment, the user operation and usage information of the application installed in the terminal and the memory occupancy information are determined. The memory reclaim time interval in each predetermined time segment is determined according to the user operation and usage information and memory occupancy information of the application installed in the terminal in the predetermined time segment.

예컨대, 하루를 단위로 사용하고, 여러 시간 세그먼트로서 9:00-17:00, 17:00-23:00 및 23:00-9:00이 미리 설정된다. 어플리케이션의, 여러 미리 설정된 시간 세그먼트에서의, 사용자 조작 및 사용 정보 및 메모리 점유 정보에 대한 통계치가 각각 수집된다. 예컨대, 시간 세그먼트 17:00-23:00에서, 사용자는 어플리케이션을 더 자주 사용하고, 그 어플리케이션에 의해 점유된 메모리의 크기 또한 가장 크며, 이 시간 세그먼트에서의 메모리 리클레임 시간 간격은 0.5시간으로 설정될 수 있다. 시간 세그먼트 9:00-17:00에서, 사용자가 어플리케이션을 사용하는 빈도는 중간 정도이고, 점유된 메모리의 크기 또한 중간 정도이며, 이 시간 세그먼트에서의 메모리 리클레임 시간 간격은 1시간으로 설정될 수 있다. 시간 세그먼트 23:00-9:00에서, 사용자는 어플리케이션을 가장 덜 사용하고, 점유된 메모리의 크기 또한 가장 작으며, 이 시간 세그먼트에서의 메모리 리클레임 시간 간격은 3시간으로 설정될 수 있다. 다른 예에서, 일주일 중 업무일과 비업무일에서의 어플리케이션 사용 통계치 간의 차이를 더 고려하여, 업무일과 비업무일에 대해 각각 상이한 메모리 리클레임 시간 간격을 설정한다. 예컨대, 토요일과 일요일에 사용자가 어플리케이션을 사용하는 빈도가 업무일에 그 어플리케이션을 사용하는 빈도보다 현저히 더 높다. 이상의 메모리 리클레임 시간 간격은 물론 월요일-금요일에 사용될 수 있고, 토요일과 일요일에 메모리 리클레임 빈도는 증가한다. 예컨대, 시간 세그먼트 9:00-17:00, 17:00-23:00 및 23:00-9:00에서의 상술한 메모리 리클레임 시간 간격은 각각 토요일 및 일요일에 절반으로 된다. 즉, 시간 세그먼트 17:00-23:00에서의 메모리 리클레임 시간 간격은 0.25시간으로 설정되고, 시간 세그먼트 9:00-17:00에서의 메모리 리클레임 시간 간격은 0.5시간으로 설정되며, 시간 세그먼트 23:00-9:00에서의 메모리 리클레임 시간 간격은 1.5시간으로 설정된다.For example, a day is used as a unit, and 9: 00-17: 00, 17: 00-23: 00 and 23: 00-9: 00 are set in advance as various time segments. Statistical values of user operation and usage information and memory occupancy information of the application in various preset time segments are respectively collected. For example, in the time segment 17: 00-23: 00, the user uses the application more frequently, the memory occupied by the application is also the largest, and the memory reclaim time interval in this time segment is set to 0.5 hours . At time segment 9: 00-17: 00, the frequency with which the user uses the application is medium, the size of the memory occupied is also medium, and the memory reclaim time interval in this time segment can be set to one hour have. At time segment 23: 00-9: 00, the user has the least use of the application, the occupied memory size is also the smallest, and the memory reclaim time interval in this time segment can be set to three hours. In another example, different memory reclaim time intervals are set for business and non-business days, respectively, taking into account differences between application usage statistics at work and non-business days of the week. For example, the frequency with which a user uses an application on Saturday and Sunday is significantly higher than the frequency with which the application is used on a business day. The above memory reclaim time interval can of course be used from Monday to Friday, and the memory reclaim frequency increases on Saturday and Sunday. For example, the above-mentioned memory reclaim time intervals at time segments 9: 00-17: 00, 17: 00-23: 00, and 23: 00-9: 00 are halved on Saturdays and Sundays, respectively. That is, the memory reclaim time interval at time segment 17: 00-23: 00 is set to 0.25 hours, the memory reclaim time interval at time segment 9: 00-17: 00 is set to 0.5 hour, The memory reclaim time interval at 23: 00-9: 00 is set to 1.5 hours.

S303: 메모리 리클레임 시간 간격에 따라, 현재 메모리 리클레임을 수행할 필요가 있다고 결정되면, 단말에서 현재 실행 중인 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라, 단말에서 현재 실행 중인 어플리케이션 중에서, 메모리 리클레임을 해야 할 어플리케이션을 결정한다. 여기서, 사용자가 정상적으로 어플리케이션을 사용하고 있다는 것을 확실히 하기 위해, 사용자에 의해 현재 사용되는 어플리케이션에 대해서는 메모리 리클레임을 고려하지 않는다. 사용자가 현재 사용하는 어플리케이션은 포어그라운드 어플리케이션을 포함할 수 있고, 또는 파일 다운로딩과 같은 백그라운드에서 실행되는 어플리케이션을 포함할 수도 있다.S303: If it is determined that it is necessary to perform the current memory reclaim according to the memory reclaim time interval, in accordance with the user operation and use information and memory occupancy information of the currently executed application in the terminal, Decide which applications need to reclaim memory. Here, in order to make sure that the user normally uses the application, the memory reclaim is not considered for the application currently used by the user. The user's current application may include a foreground application, or may include an application running in the background, such as a file download.

S304: 커널 모드가 제공하는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행한다.S304: The memory reclaim interface provided by kernel mode is called to perform memory reclaim.

구체적인 구현예에서, 결정된 메모리 리클레임 시간 간격에 따라 메모리 리클레임 시간에 도달한 것으로 결정되면, 현재 시간이, 통계치 수집에 의해 획득된, 사용자가 어플리케이션을 사용할 가능성이 상대적으로 높은 시간 범위 내에 있지 않다면, 단말에서 현재 실행 중인 어플리케이션으로서 사용자가 사용하거나 조작하지 않는 어플리케이션의 메모리가 리클레임된다. 이러한 방식으로, 메모리 리클레임 종료 조건이 충족될 때까지 메모리 리클레임 대상 어플리케이션이 성공적으로 선택된다.In a specific implementation, if it is determined that the memory reclaim time has been reached in accordance with the determined memory reclaim time interval, if the current time is not within a time range in which the user is likely to use the application, , The memory of the application that is not currently used or operated by the user is reclaimed. In this way, the memory reclaim target application is successfully selected until the memory reclaim end condition is satisfied.

일 구현예에서, 메모리 리클레임을 현재 수행할 필요가 있다고 결정된 후, 현재 단말에서 실행 중이며 또한 사용자에 의해 조작되지 않는 어플리케이션이 메모리 리클레임을 해야 할 어플리케이션들의 미리 저장된 우선순위 순서에 따라 선택될 수 있다. 현재 시간이 선택된 어플리케이션의 사용 가능성이 높은 시간 세그먼트(즉, 어플리케이션의 사용자 조작 및 사용 확률이 상대적으로 높은 시간 세그먼트) 내에 있는지는, 어플리케이션의 사용자 조작 및 사용 정보(예컨대, 사용자가 어플리케이션을 12:00~13:00에 5일 연속으로 사용하면, 12:00~13:00는 해당 어플리케이션의 고확률 실행 시간 세그먼트이다)에 기초하여 결정된다. 현재 시간이 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 선택된 어플리케이션이 메모리 리클레임을 할 어플리케이션인 것으로 결정된다. 상술한 단계들은 메모리 리클레임 종료 조건이 충족될 때까지 반복된다. 여기서, 메모리 리클레임 종료 조건은 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 것을 포함할 수 있다.In one implementation, after it is determined that a memory reclaim is currently needed to be performed, an application that is currently running on the terminal and is not manipulated by the user may be selected in accordance with a pre-stored priority order of applications that are to be memory reclaimed have. Whether the current time is within a time segment with a high availability of the selected application (i.e., a time segment in which the user operation and probability of use of the application is relatively high) is determined based on user operation and usage information of the application (e.g., 13:00 for five consecutive days, and 12:00 to 13:00 is the high probability runtime segment of the application). If the current time is not within the high utilization time segment of the selected application, it is determined that the selected application is the application that will make the memory reclaim. The above steps are repeated until the memory reclaim end condition is satisfied. Here, the memory reclaim termination condition may include that the size of the system free memory is larger than a predetermined second threshold value.

우선순위 순서는 상이한 어플리케이션 그룹 간의 우선순위 순서일 수 있다. 구체적으로, 단말에 설치된 어플리케이션들은 어플리케이션들의 사용 빈도에 따라 그룹화될 수 있고, 동일 그룹의 어플리케이션들은 동일한 사용 빈도 범위를 가진다. 각 그룹의 어플리케이션들의 메모리 리클레임 우선순위 순서는, 각 그룹에 대응하는 사용 빈도 범위에 따라 결정되고, 동일 그룹의 어플리케이션들은 동일한 우선순위 순서를 가진다. 예컨대, UI(User Interface)와 같은 몇몇 어플리케이션들은 단말 내에서 오퍼레이팅 시스템의 핵심 요소와 관련될 수 있고, 이런 유형의 어플리케이션은 그룹 1에 분류될 수 있으며, 그룹 1은 매우 중요한 어플리케이션을 나타낸다. 위챗 및 카메라와 같이 사용자가 자주 사용하는 몇몇 어플리케이션에 대해, 이러한 유형의 어플리케이션은 그룹 2에 분류될 수 있는데, 그룹 2는 대체로 중요한 어플리케이션을 나타낸다. 계산기 및 주식과 같은 자주 사용되지 않는 몇몇 어플리케이션에 대해, 이러한 유형의 어플리케이션은 그룹 3으로 분류될 수 있고, 그룹 3은 중요하지 않은 어플리케이션을 나타낸다. 그룹 3의 메모리 리클레임 우선순위 > 그룹 2의 메모리 리클레임 우선순위 > 그룹 1의 메모리 리클레임 우선순위와 같이 설정된다. 메모리 리클레임 동안, 그룹 3의 어플리케이션의 메모리 리클레임이 가장 우선시되고, 그룹 2의 어플리케이션의 메모리 리클레임이 두 번째로 우선시되며, 그룹 1의 어플리케이션의 메모리는 리클레임되지 않는다.The priority order may be a priority order among different application groups. Specifically, the applications installed in the terminal can be grouped according to the usage frequency of the applications, and the applications in the same group have the same use frequency range. The memory reclaim priority order of the applications of each group is determined according to the use frequency range corresponding to each group, and the applications of the same group have the same priority order. For example, some applications, such as a user interface (UI), may be associated with the core elements of the operating system within the terminal, and this type of application may be classified in group 1, and group 1 represents a very important application. For some applications that users frequently use, such as camcorders and cameras, this type of application can be categorized into Group 2, where Group 2 represents a largely critical application. For some infrequently used applications, such as calculators and stocks, this type of application can be classified as Group 3, while Group 3 is shown as non-critical. The memory reclaim priority of group 3> the memory reclaim priority of group 2> the memory reclaim priority of group 1. During the memory reclaim, the memory reclaim of the application of the group 3 is given the highest priority, the memory reclaim of the application of the group 2 is given the second priority, and the memory of the application of the group 1 is not reclaimed.

실시예 3Example 3

적시에 적절한 메모리 리클레임을 보장하기 위해 메모리 리클레임 정책을 더욱 최적화하기 위해, 본 출원의 실시예는 추가로 복수의 메모리 리클레임 조건을 이용하여 메모리 리클레임을 수행하는 실시예를 제공한다.To further optimize the memory reclaim policy to ensure timely and appropriate memory reclaim, embodiments of the present application additionally provide embodiments that perform memory reclaim using a plurality of memory reclaim conditions.

도 4를 참조하면, 도 4는 사용자 모드에서 다음 단계를 수행하는 방법으로서, 본 출원의 실시예 3에 따른 메모리 리클레임 방법의 흐름도이다.Referring to FIG. 4, FIG. 4 is a flowchart of a memory reclaim method according to a third embodiment of the present application, as a method for performing the following steps in the user mode.

S401: 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보를 모니터링한다.S401: User operation and usage information and memory occupancy information of the application installed in the terminal are monitored.

S402: 단말에 설치된 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정한다.S402: The memory reclaim time interval is determined according to the user operation and usage information and memory occupancy information provided in the terminal.

S403: 다음의 조건 1 내지 4 중 어느 하나 또는 그 이상이 충족되는 때 S404의 메모리 리클레임 절차를 트리거하고, 조건 5가 충족되는 때에는 S405의 메모리 리클레임 절차를 트리거한다.S403: Trigger the memory reclaim procedure of S404 when any one or more of the following conditions 1 to 4 are satisfied, and trigger the memory reclaim procedure of S405 when the condition 5 is satisfied.

1. 메모리 리클레임 시간 간격에 따라, 현재 메모리 리클레임을 수행해야 하는 것으로 결정된다.1. Depending on the memory reclaim time interval, it is determined that the current memory reclaim must be performed.

구체적인 구현예에서, 현재 메모리 리클레임을 수행해야 하는지 여부는 시스템 여유 메모리를 참조하여 결정될 수 있다. 즉, 메모리 리클레임 시간 간격이 나타내는 메모리 리클레임 시간이 현재 도달한 때, 시스템 여유 메모리가 임계치(이 임계치는 이하에서 설명하는 소정의 제1 임계치, 소정의 제2 임계치 또는 다른 임계치일 수 있고, 상기 다른 임계치는 제1 임계치 및 제2 임계치 사이의 임계치일 수 있으며, 제1 임계치는 제2 임계치보다 작다)보다 작으면 수행될 수 있다. In a specific implementation, whether a current memory reclaim should be performed can be determined with reference to system free memory. That is, when the memory reclaim time, which is indicated by the memory reclaim time interval, currently reaches, the system free memory is the threshold (this threshold may be a predetermined first threshold, a predetermined second threshold, or another threshold, The other threshold may be a threshold between the first threshold and the second threshold, and the first threshold is less than the second threshold).

2. 시스템 여유 메모리가 소정의 제1 임계치보다 작은 것으로 결정된다.2. It is determined that the system free memory is smaller than the predetermined first threshold value.

3. 어플리케이션이 시작되거나 또는 포어그라운드 인터페이스로 전환되는 것이 검출된 때, 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 현재 메모리 리클레임을 수행해야 하는 것으로 결정된다.3. When it is detected that the application is started or switched to the foreground interface, it is determined that the current memory reclaim should be performed according to the memory occupancy information of the application and the size of the system free memory.

여기서, 새롭게 시작되거나 포어그라운드 인터페이스로 전환된 어플리케이션이 요구한 메모리의 크기가 시스템 여유 메모리보다 큰 경우, 메모리 리클레임이 트리거된다.Here, if the size of the memory requested by the application newly started or switched to the foreground interface is larger than the system free memory, the memory reclaim is triggered.

4. 백그라운드에서 실행 중인 어플리케이션의 수 M이 현재 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 개수 N보다 크다.4. The number of running applications M in the background is greater than the predetermined allowable number N of applications that can currently be run in the background.

구체적인 구현예에서, 백그라운드에서 실행될 수 있는 어플리케이션의 허용 개수는 현재 시스템 여유 메모리의 크기에 따라 설정될 수 있다.In a specific implementation, the allowable number of applications that can be executed in the background may be set according to the size of the current system free memory.

5. 단말의 어플리케이션에 의해, 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출된다.5. It is detected by the application of the terminal that the period of stay in the background exceeds the predetermined period.

상술한 조건 2-5에 대해서는, 통상의 기술자라면 실제 요건에 따라 조건의 일부만을 선택할 수도 있다.With respect to the above-mentioned condition 2-5, only a part of the condition may be selected according to the actual requirement, if it is an ordinary technician.

S404: 단말에서 현재 실행 중인 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라, 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션 중에서, 메모리 리클레임을 할 어플리케이션을 결정하고, 커널 모드가 제공하는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행한다.S404: determines an application to be memory reclaimed from an application that is not currently operated or used by the user as an application currently being executed in the terminal, based on the user operation and usage information and memory occupancy information of the application currently being executed in the terminal, The memory reclaim interface provided by the mode is called to perform the memory reclaim.

구체적인 구현예에서, 단말 시스템이 시작된 후, 본 출원의 사용자 모드에서 메모리 클레임에 사용하기 위한 데몬(daemon)이 먼저 시작되고, 그런 다음 어플리케이션이 시작되며, 이하의 표 1에서와 같이, 어플리케이션 실행 데이터 표를 유지함으로써 단말에서 어플리케이션의 메모리 점유 상태를 기록하고 고확률 실행 시간 세그먼트에 대한 통계를 수집한다.In a specific implementation, after a terminal system is started, a daemon for use in a memory claim in a user mode of the present application is first started, then an application is started, and as shown in Table 1 below, By keeping the table, the terminal records the memory occupancy status of the application and collects statistics on the high probability execution time segments.

어플리케이션application 점유된 메모리Occupied memory 고확률 실행 시간 세그먼트High Probability Run Time Segment App 1App 1 x1KBx1KB T1-T2T1-T2 App 2App 2 x2KBx2KB T3-T4T3-T4 App 3App 3 x3KBx3KB T5-T6T5-T6 App 4App 4 x4KBx4KB T7-T8T7-T8 ...... ...... ......

메모리 리클레임을 수행해야 하는 경우, 단말에서 현재 실행 중인 어플리케이션이 메모리 리클레임을 할 어플리케이션의 미리 저장된 우선순위 순서에 따라 선택될 수 있다. 표 1을 참조하면, 현재 시간이 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있는지 결정한다. 현재 시간이 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 선택된 어플리케이션이 메모리 리클레임을 할 어플리케이션으로서 사용되고, 커널 모드에 의해 제공되고 메모리 리클레임에 사용되는 메모리 리클레임 인터페이스를 호출하는 것에 의해 메모리 리클레임을 수행하고, 상술한 단계들은 메모리 리클레임 종료 조건이 충족될 때까지 반복된다. 여기서, 조건 1 내지 4 간의 차이에 기초하여, 상술한 메모리 리클레임 종료 조건은, 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우; 현재 시작된 어플리케이션이 요구하는 메모리가 시스템 여유 메모리보다 작은 경우; 포어그라운드 인터페이스로 전환된 어플리케이션에 의해 요구되는 메모리가 시스템 여유 메모리보다 작은 경우, 또는 백그라운드에서 실행 중인 어플리케이션의 수가 백그라운드에서 실행 가능한 어플리케이션의 소정의 허용 개수와 같거나 그보다 작은 경우, 중 하나 이상을 포함할 수 있다. 예컨대, 조건 1 및 2에 대해, 메모리 리클레임 종료 조건은 시스템 여유 메모리의 크기가 소정의 제2 임계치(소정의 제2 임계치는 소정의 제1 임계치보다 더 크다)보다 더 큰 경우일 수 있고; 조건 3에 대해, 메모리 리클레임 종료 조건은 현재 시작된 어플리케이션에 의해 요구되는 메모리가 시스템 여유 메모리보다 작은 경우일 수 있으며; 조건 4에 대해, 메모리 리클레임 종료 조건은 백그라운드에서 실행 중인 어플리케이션의 수가 백그라운드에서 실행 가능한 어플리케이션의 소정의 허용 개수와 같은 경우일 수 있다. 즉, 단계 S303에서, 메모리 리클레임을 해야 할 M-N개의 어플리케이션이 백그라운드에서 실행 중인 어플리케이션으로부터 선택된다.When a memory reclaim is to be performed, an application currently being executed in the terminal may be selected according to a pre-stored priority order of an application to be memory reclaimed. Referring to Table 1, it is determined whether the current time is within the high-probability time-of-use segment of the selected application. If the current time is not within the high availability time segment of the selected application, then the selected application is used as the application to make memory reclaim, and by calling the memory reclaim interface provided by kernel mode and used for memory reclaim, Claims are made, and the above steps are repeated until a memory reclaim termination condition is met. Here, based on the difference between the conditions 1 to 4, the aforementioned memory reclaim termination condition is satisfied when the size of the system free memory is larger than the predetermined second threshold value; The memory requested by the currently started application is smaller than the system free memory; When the memory required by the application switched to the foreground interface is smaller than the system free memory or when the number of applications running in the background is less than or equal to a predetermined allowable number of applications executable in the background can do. For example, for conditions 1 and 2, the memory reclaim termination condition may be the case where the size of the system free memory is greater than a predetermined second threshold (the predetermined second threshold is greater than a predetermined first threshold); For condition 3, the memory reclaim termination condition may be the case where the memory required by the currently started application is less than the system free memory; For condition 4, the memory reclaim termination condition may be the case where the number of applications running in the background is equal to a predetermined allowable number of applications executable in the background. That is, in step S303, M-N applications to be memory reclaimed are selected from applications running in the background.

S405: 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과하는 어플리케이션의 메모리를 리클레임한다.S405: By calling the memory reclaim interface provided by the kernel mode, the memory of the application whose period of stay in the background exceeds the predetermined period is reclaimed.

동일한 기술적 사상에 기초하여, 본 출원은 메모리 리클레임 방법에 대응하는 메모리 리클레임 장치 및 사용자 장비를 제공한다. 문제를 해결하기 위한 이 장치 및 사용자 장비의 원리는 본 출원에서의 메모리 리클레임 방법과 유사하기 때문에, 이 장치 및 사용자 장비의 구현예에 대해, 방법의 구현예를 참고할 수 있다. 반복되는 부분은 다시 설명하지 않는다.Based on the same technical idea, the present application provides a memory reclaim device and user equipment corresponding to a memory reclaim method. Since the principles of this device and user equipment for solving the problem are similar to the memory reclaim method in the present application, reference may be made to implementation of the method for implementation of this device and user equipment. Repeated parts are not explained again.

실시예 4Example 4

도 5를 참조하면, 도 5는 본 출원의 실시예에 따른 메모리 리클레임 장치(50)의 개략 구성도이고, 메모리 리클레임 장치(50)는:5, a memory re-claim device 50 is a schematic configuration diagram of a memory re-claim device 50 according to an embodiment of the present application. The memory re-

사용자 모드에서, 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하도록 구성된 결정 모듈(51); 및A determination module (51) configured to monitor user operation and usage information and memory occupancy information of an application installed in the terminal in a user mode; And

상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하도록 구성된 메모리 리클레임 모듈(52)If the memory reclaim condition is determined to be satisfied at present according to at least one of the user operation and use information or memory occupancy information of the application installed in the terminal, user operation and use information of an application currently being executed in the terminal, A memory reclaim module configured to determine an application to be memory reclaimed among currently running applications in the terminal according to the memory occupancy information and to perform a memory reclaim by calling a memory reclaim interface provided by the kernel mode 52)

을 포함한다..

본 출원에서, 메모리 리클레임은, 사용자 모드에서, 단말에 설치된 어플리케이션의 사용자 조작 및 사용 상태 및 메모리 점유 상태를 모니터링함으로써 선제적으로 수행되고, 이로써 어플리케이션이 사용자에 의해 자주 조작되고 사용되며 큰 메모리를 점유하는 경우, 메모리 리클레임 빈도가 증가하여 메모리의 정상적 사용을 보장한다.In the present application, the memory reclaim is preemptively performed by monitoring the user operation and the usage state and the memory occupation state of the application installed in the terminal in the user mode, whereby the application is frequently operated and used by the user, If occupied, the frequency of memory reclaim increases, ensuring normal use of the memory.

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로,Alternatively, the memory reclaim module 52 may be,

상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하고, 현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.Determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal, and when the current time reaches a memory reclaim time indicated by the memory reclaim time interval, It is configured to determine that the memory reclaim condition is currently satisfied.

본 구현예에서, 메모리 리클레임 모듈(52)은 먼저, 사용자의 어플리케이션 사용의 정기성에 따라 메모리 리클레임 시간 간격을 결정하고, 그런 다음 메모리 리클레임 시간 간격이 나타내는 메모리 리클레임 시간에 따라 메모리 리클레임을 적극적으로 수행한다. 이 방식으로, 계획된 리클레임이 메모리에 대해 수행되고, 이로서 단말 내의 가용한 여유 메모리가 상대적으로 적절한 레벨로 유지될 수 있다.In this implementation, the memory reclaim module 52 first determines a memory reclaim time interval in accordance with the regularity of the user's application usage, and then determines the memory reclaim time interval according to the memory reclaim time interval indicated by the memory reclaim time interval . In this way, a planned reclaim is performed on the memory, thereby allowing the available free memory in the terminal to be maintained at a relatively appropriate level.

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로, 다음의 단계:Optionally, the memory reclaim module 52 specifically includes the following steps:

상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하는 단계; 및Individually determining user operation and usage information and memory occupancy information in each of at least one predetermined time segment of an application installed in the terminal; And

상기 적어도 하나의 미리 설정된 시간 세그먼트 각각 동안, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하는 단계A memory reclaim time interval within each time segment is determined according to user operation and usage information and memory occupancy information in each time segment of an application installed in the terminal during each of the at least one predetermined time segment Steps to be individually determined

에 따라 메모리 리클레임 시간 간격을 결정하도록 구성된다.To determine a memory reclaim time interval according to the memory reclaim time interval.

사용자가 어플리케이션을 조작하고 사용하는 빈도는, 상이한 시간 세그먼트에서 서로 다르다. 그러므로, 이 방식에서, 상이한 시간 세그먼트에서는 상이한 메모리 리클레임 시간 간격이 사용될 수 있다. 이것은 메모리 리클레임 적시성을 더욱 향상시키고, 또한 불필요한 메모리 리클레임 절차의 잦은 실행으로 인해 야기되는 시스템 자원 낭비를 피할 수 있다.The frequency with which a user manipulates and uses an application is different in different time segments. Thus, in this manner, different memory reclaim time intervals may be used in different time segments. This further improves the timeliness of memory reclaim and also avoids wasting system resources caused by frequent execution of unnecessary memory reclaim procedures.

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.Optionally, the memory reclaim module 52 is specifically configured to determine that the memory reclaim condition is currently satisfied if it is determined that the system free memory is less than a predetermined first threshold.

이 방식에서는, 메모리 불충분을 어느 정도 피할 수 있다.In this way, memory insufficiency can be avoided to some extent.

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로, Alternatively, the memory reclaim module 52 may be,

어플리케이션이 시작되거나 또는 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하고, When it is detected that the application is started or switched to the foreground interface, it is determined whether to perform the memory reclaim according to the memory occupancy information of the application and the size of the system free memory,

메모리 리클레임을 수행해야 하는 경우, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.When a memory reclaim is to be performed, it is configured to determine that the memory reclaim condition is currently satisfied.

새롭게 시작한 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션은 통상 사용자가 막 사용하려는 어플리케이션이고, 이 방식에서, 새롭게 시작한 어플리케이션 또는 포어그라운드 인터페이스로 전환된 어플리케이션의 정상적인 실행이 보장되며, 이로써 시스템 퍼포먼스를 향상시키고 사용자 경험을 개선시킬 수 있다.The newly started application or the application switched to the foreground interface is usually an application that the user is about to use. In this way, normal execution of the newly started application or the application switched to the foreground interface is guaranteed, Experience can be improved.

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로,Alternatively, the memory reclaim module 52 may be,

백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.If the number of currently running applications in the background exceeds a predetermined allowable number of applications that can be executed in the background, it is determined that the memory reclaim condition is currently satisfied.

또한, 여기서, 백그라운드에서 실행이 허가된 어플리케이션의 수는 현재 여유 메모리의 크기에 따라 시간 간격에 대해 설정될 수 있다. 백그라운드에서 실행 중인 어플리케이션은 통상 사용자가 현재 사용하는 어플리케이션이 아니기 때문에, 이들 어플리케이션의 수를 제한함으로써 메모리의 과도한 불필요한 점유를 피할 수 있다.Here, the number of applications permitted to be executed in the background can be set for the time interval according to the size of the current free memory. Because applications running in the background are not typically the applications the user is currently using, limiting the number of these applications can avoid excessive memory occupation.

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로, Alternatively, the memory reclaim module 52 may be,

메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및Selects an application that is not operated or used by a user as an application currently being executed in the terminal according to a pre-stored priority order of the application to be memory reclaimed, and determines that the current time is a high-probability usage time segment probability use time segment of the selected application, wherein the high-probability usage time segment of the application is determined based on user operation and usage information of the application, and wherein the current time is within a high- Determining that the selected application is an application to be memory reclaimed and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode; And

메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계Repeating the step until the memory reclaim termination condition is satisfied

에 따라 메모리 리클레임을 수행하도록 구성된다.To perform a memory reclaim.

이 방식에서, 우선순위가 상대적으로 낮은 어플리케이션의 메모리(이 어플리케이션은 통상 사용자가 자주 사용하는 어플리케이션이 아니다)는 리클레임 대상으로서 우선적으로 선택된다. 여기서 현재 시간은 해당 어플리케이션의 고확률 실행 시간 세그먼트 내에 있지 않으며, 이로써 시스템 퍼포먼스는 향상되고 사용자 경험은 개선된다.In this way, a memory of an application with a relatively low priority (this application is usually not an application that a user frequently uses) is preferentially selected as a reclaim target. Where the current time is not within the high-probability runtime segment of the application, thereby improving system performance and improving the user experience.

선택적으로, 메모리 리클레임 종료 조건은 다음의 조건:Optionally, the memory reclaim termination condition is the following:

상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;When the size of the system free memory is larger than a predetermined second threshold value;

현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;When the memory requested by the currently started application is smaller than the system free memory;

포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및The memory required by the application switched to the foreground interface is smaller than the system free memory; And

백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background

중 하나 이상을 포함한다.&Lt; / RTI &gt;

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로, Alternatively, the memory reclaim module 52 may be,

어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And

각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -Determining a memory re-claim priority order of an application in each group according to a use frequency range corresponding to each group; the applications in the same group have the same priority order;

에 따라 메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서를 설정하도록 구성된다.And to set a priority order of the applications that are required to make a memory reclaim according to the priority order.

선택적으로, 메모리 리클레임 모듈(52)은 구체적으로,Alternatively, the memory reclaim module 52 may be,

상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하도록 구성된다.Determining that the memory reclaim condition is currently satisfied if it is detected that the application in the terminal is in the background for a predetermined period of time, calling the memory reclaim interface provided by the kernel mode, And resumes a memory of an application in which a period of stay in a predetermined period exceeds a predetermined period.

여기서, 백그라운드에 체류하는 기간이 상대적으로 긴 어플리케이션은 통상 현 기간 동안 사용자가 조작하지 않은 어플리케이션이고, 이 어플리케이션의 메모리는 해제되어 메모리를 더욱 필요로 하는 어플리케이션에 제공되며, 이로서 메모리의 효과적인 이용율을 향상시킬 수 있다.Here, an application in which a period of staying in the background is relatively long is an application which is not normally operated by a user during the current period, and the memory of this application is released and provided to an application that needs more memory, thereby improving the effective utilization rate of the memory .

실시예 5Example 5

도 6을 참조하면, 도 6은 본 출원의 실시예에 따른 사용자 장비(60)의 개략 구성도이고, 사용자 장비(60)는 프로세서(61), 메모리(62) 및 버스(63)를 포함한다. 메모리(62)는 실행 명령을 저장하도록 구성되고, 내부 메모리 장치(621) 및 외부 메모리 장치(622)를 포함한다. 여기서, 내부 메모리 장치(621)는 내부 메모리라고도 하고, 프로세서(61)의 동작 데이터 및 하드 디스크와 같은 외부 메모리(622)와 교환되는 데이터를 일시 저장하도록 구성된다. 프로세서(61)는 내부 메모리 장치(621)를 이용하여 외부 메모리(622)와 데이터를 교환하고, 사용자 장비(60)가 실행되는 때, 프로세서(61) 및 메모리(62)는 버스(63)를 이용하여 서로 통신함으로써, 프로세서(61)가 이하의 명령을 사용자 모드에서 실행한다:6 is a schematic diagram of a user equipment 60 according to an embodiment of the present application and the user equipment 60 includes a processor 61, a memory 62 and a bus 63 . The memory 62 is configured to store an execution command and includes an internal memory device 621 and an external memory device 622. [ Here, the internal memory device 621 is also referred to as an internal memory, and is configured to temporarily store operation data of the processor 61 and data exchanged with the external memory 622 such as a hard disk. The processor 61 exchanges data with the external memory 622 using the internal memory device 621 and the processor 61 and the memory 62 communicate with the bus 63 when the user equipment 60 is executed. , The processor 61 executes the following commands in the user mode:

단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하는 단계; 및 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계.Monitoring user operation and usage information and memory occupancy information of an application installed in the terminal; And a user operation and use information of an application currently being executed in the terminal if the memory reclaim condition is determined to be satisfied according to at least one of user operation and usage information or memory occupancy information of the application installed in the terminal, Determining an application to be memory reclaimed from currently running applications in the terminal according to memory occupancy information, and executing a memory reclaim by calling a memory reclaim interface provided by the kernel mode.

선택적으로, 프로세스(61)에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계; 및 현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.Optionally, in the instruction executed by the process 61, it is determined that the memory reclaim condition is currently satisfied, in accordance with at least one of the user operation and use information and the memory occupancy information of the application installed in the terminal, Determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal; And determining that the memory reclaim condition is currently satisfied when the current time has reached a memory reclaim time indicated by the memory reclaim time interval.

선택적으로, 프로세서(61)에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계의 선택 가능한 방법은, 상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하는 단계; 및 상기 적어도 하나의 미리 설정된 시간 세그먼트 각각에 대해, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하는 단계를 포함한다.Optionally, in a command executed by the processor 61, a selectable method of determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal, Individually determining user operation and usage information and memory occupancy information in each of at least one predetermined time segment of an application installed in the application; And for each of the at least one predetermined time segment, a memory reclaim time in each time segment, in accordance with user operation and usage information and memory occupancy information in the respective time segment of an application installed in the terminal, And determining the interval individually.

선택적으로, 프로세서(61)에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.Optionally, in the instructions executed by the processor 61, determining that the memory reclaim condition is currently satisfied, according to the memory occupancy information of the application installed in the terminal, means that the system free memory is less than the predetermined first threshold Determining that the memory reclaim condition is currently satisfied.

선택적으로, 프로세서(61)에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 어플리케이션이 시작되거나 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하는 단계; 및 메모리 리클레임을 수행해야 하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.Optionally, in the instruction executed by the processor 61, it is determined that the memory reclaim condition is currently satisfied, in accordance with the user operation and use information and the memory occupancy information of the application installed in the terminal, Determining whether to perform a memory reclaim according to the memory occupancy information of the application and the size of the system free memory when the switching to the foreground interface is detected; And if it is necessary to perform a memory reclaim, determining that the memory reclaim condition is currently satisfied.

선택적으로, 프로세서(61)에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은, 백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함한다.Optionally, in the instruction executed by the processor 61, it is determined that the memory reclaim condition is currently satisfied in accordance with the user operation and usage information of the application installed in the terminal, Determining that the memory reclaim condition is currently satisfied if the predetermined allowable quantity of applications that can be executed in the background is exceeded.

또한, 여기서, 백그라운드에서 실행될 수 있는 어플리케이션의 허용 수량은 현재 여유 메모리의 크기에 따라 시간 간격에 설정될 수 있다. 백그라운드에서 실행되는 어플리케이션은 통상 사용자에 의해 현재 사용되는 어플리케이션이 아니기 때문에, 불필요한 과도한 메모리 점유를 이러한 어플리케이션의 수량을 제한함으로써 피할 수 있다.Here, the allowed number of applications that can be executed in the background can be set in the time interval according to the size of the current free memory. Applications running in the background are typically not currently used by users, so unnecessary excessive memory occupation can be avoided by limiting the quantity of these applications.

선택적으로, 프로세서(61)에 의해 실행되는 명령에서, 상기 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계의 선택 가능한 방식은, 메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및 메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계를 포함한다.Optionally, in an instruction executed by the processor 61, a selectable method of determining an application to be subjected to the memory reclaim and performing a memory reclaim by invoking a memory reclaim interface provided by the kernel mode Selects an application that is not operated or used by a user as an application that is currently being executed in the terminal according to a pre-stored priority order of applications to be memory-reclaimed, and the current time is the high- Probability use time segment, wherein the high-probability usage time segment of the application is determined based on user operation and usage information of the application, and wherein the current time is a high probability usage of the selected application Determining that the selected application is a memory reclaim application if it is not in the time segment and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode; And repeating the steps until the memory reclaim termination condition is satisfied.

선택적으로, 상기 메모리 리클레임 종료 조건은 다음의 조건:Optionally, the memory reclaim termination condition is one of the following conditions:

상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;When the size of the system free memory is larger than a predetermined second threshold value;

현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;When the memory requested by the currently started application is smaller than the system free memory;

포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및The memory required by the application switched to the foreground interface is smaller than the system free memory; And

백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background

중 하나 이상을 포함한다.&Lt; / RTI &gt;

선택적으로, 프로세서에 의해 실행되는 명령에서, 메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서가 다음의 단계:Optionally, in an instruction executed by the processor, the order of priority of an application that needs to make a memory reclaim is the next step:

어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And

각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -Determining a memory re-claim priority order of an application in each group according to a use frequency range corresponding to each group; the applications in the same group have the same priority order;

에 따라 설정된다..

선택적으로, 프로세서에 의해 실행되는 명령에서, 상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라, 상기 메모리 리클레임 조건이 충족된 것으로 결정되면, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계는, 상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하는 단계를 포함한다.Optionally, in a command executed by the processor, when it is determined that the memory reclaim condition is satisfied, according to the user operation and usage information of the application installed in the terminal, the memory reclaim interface provided by the kernel mode is called Wherein the memory reclaiming step determines that the memory reclaim condition is currently satisfied when it is detected that the period in which the application at the terminal remains in the background exceeds a predetermined period of time, And reclaiming a memory of an application whose period of stay in the background exceeds a predetermined period by calling the memory reclaim interface.

실시예 6Example 6

도 7은 본 출원에 따른 단말 장치(700)의 구조를 개시하고, 이 단말 장치(700)는, 적어도 하나의 프로세서(701), 적어도 하나의 네트워크 인터페이스(704) 또는 다른 사용자 인터페이스(703), 메모리(705), 및 적어도 하나의 통신 버스(702)를 포함한다. 통신 버스(702)는 구성요소들 간의 연결 및 통신을 구현하도록 구성된다. 여기서, 메모리(705)는 내부 메모리 장치 및 외부 메모리 장치를 포함한다. 내부 메모리 장치는 내부 메모리라고도 하며, 프로세서(701)의 동작 데이터, 및 하드 디스크와 같은 외부 메모리와 교환된 데이터를 일시적으로 저장한다. 프로세서(701)는 내부 메모리 장치를 이용하여 외부 메모리와 데이터를 교환한다.7 illustrates a structure of a terminal device 700 according to the present application and includes at least one processor 701, at least one network interface 704 or other user interface 703, A memory 705, and at least one communication bus 702. [ Communication bus 702 is configured to implement connection and communication between components. Here, the memory 705 includes an internal memory device and an external memory device. The internal memory device is also referred to as an internal memory, and temporarily stores operation data of the processor 701 and data exchanged with an external memory such as a hard disk. The processor 701 exchanges data with an external memory using an internal memory device.

메모리(705)는 다음 요소들, 실행 가능한 모듈 또는 데이터 결과 또는 그 부분들, 또는 확장된 집합을 저장한다.Memory 705 stores the following elements, executable modules or data results or portions thereof, or an extended set.

오퍼레이팅 시스템(7051)은 여러 시스템 프로그램을 포함하고, 두 개의 실행레벨을 가질 수 있는데, 그것은 커널 모드(7051a) 및 사용자 모드(7051b)이다. 프로세스가 시스템 호출을 수행하고 실행을 위해 커널 코드를 실행하는 경우, 그 프로세스는 커널 실행 모드에 있으며, 이것은 줄여서 커널 모드라고도 한다. 프로세스가 커널 모드에 있으면, 실행 상태의 커널 코드는 현재 프로세스의 커널 스택을 사용하고, 각 프로세스는 각자의 커널 스택을 가진다. 프로세스가 사용자의 커널 코드를 실행하는 경우, 이 프로세스는 사용자 실행 모드에 있고, 이것은 줄여서 사용자 모드라고도 한다. 이 경우, 프로세서(701)는 사용자 코드에서 동작하는데, 이것의 접근 레벨(privilege level)은 가장 낮다.The operating system 7051 includes several system programs and may have two execution levels, kernel mode 7051a and user mode 7051b. When a process executes a system call and executes kernel code for execution, the process is in kernel run mode, which is also referred to as kernel mode. When a process is in kernel mode, the running kernel code uses the current process's kernel stack, and each process has its own kernel stack. When a process executes your kernel code, this process is in user-executable mode, which is also referred to as user-mode. In this case, the processor 701 operates in user code, whose privilege level is lowest.

어플리케이션 프로그램 모듈(7052)은 여러 어플리케이션 프로그램(줄여서 어플리케이션)을 포함한다.The application program module 7052 includes a plurality of application programs (applications for short).

단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하는 단계; 및 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계.Monitoring user operation and usage information and memory occupancy information of an application installed in the terminal; And a user operation and use information of an application currently being executed in the terminal if the memory reclaim condition is determined to be satisfied according to at least one of user operation and usage information or memory occupancy information of the application installed in the terminal, Determining an application to be memory reclaimed from currently running applications in the terminal according to memory occupancy information, and executing a memory reclaim by calling a memory reclaim interface provided by the kernel mode.

선택적으로, 일실시예에서, 프로세서(701)는 추가로, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하고, 현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.Optionally, in one embodiment, the processor 701 further determines a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal, And to determine that the memory reclaim condition is currently satisfied when the memory reclaim time indicated by the claim time interval is reached.

또, 프로세서(701)는 또한, 상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하고, 상기 적어도 하나의 미리 설정된 시간 세그먼트 각각 동안, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하도록 구성된다.The processor 701 may also separately determine user operation and usage information and memory occupancy information in each of at least one predetermined time segment of an application installed in the terminal and determine whether the at least one predetermined time segment During each of the time segments, a memory reclaim time interval in each time segment according to user operation and usage information and memory occupancy information of each time segment of the application installed in the terminal.

선택적으로, 또 다른 실시예에서, 프로세서(701)는 추가로, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.Optionally, in another embodiment, processor 701 is further configured to determine that the memory reclaim condition is currently satisfied if it is determined that the system free memory is less than a predetermined first threshold.

선택적으로, 또 다른 실시예에서, 프로세서(701)는 또한, 어플리케이션이 시작되거나 또는 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하고, 메모리 리클레임을 수행해야 하는 경우, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.Optionally, in yet another embodiment, processor 701 may also be configured to, if detected to be an application initiated or switched to a foreground interface, generate a memory reclaim according to the memory occupancy information of the application and the size of the system free memory And to determine that the memory reclaim condition is currently satisfied if the memory reclaim is to be performed.

선택적으로, 또 다른 실시예에서, 프로세서(701)는 또한, 백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된다.Alternatively, in another embodiment, the processor 701 may also determine that a memory reclaim condition is currently satisfied if the number of applications currently running in the background exceeds a predetermined allowable number of applications that can be executed in the background .

또한, 여기서, 백그라운드에서 실행이 허가된 어플리케이션의 수는 현재 여유 메모리의 크기에 따라 시간 간격에 대해 설정될 수 있다. 백그라운드에서 실행 중인 어플리케이션은 통상 사용자가 현재 사용하는 어플리케이션이 아니기 때문에, 이들 어플리케이션의 수를 제한함으로써 메모리의 과도한 불필요한 점유를 피할 수 있다.Here, the number of applications permitted to be executed in the background can be set for the time interval according to the size of the current free memory. Because applications running in the background are not typically the applications the user is currently using, limiting the number of these applications can avoid excessive memory occupation.

선택적으로, 또 다른 실시예에서, 프로세서(701)는 또한, 메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및 메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계에 따라, 메모리 리클레임을 수행할 어플리케이션을 결정하고 메모리 리클레임을 수행하도록 구성된다.Optionally, in yet another embodiment, processor 701 may also include an application that is not currently operated or used by the user as an application currently running on the terminal, in accordance with a pre-stored priority order of the application to be memory reclaimed And determines if the current time is within a high-probability use time segment of the selected application, wherein the high-probability usage time segment of the application is based on user operation and usage information of the application Determining that the selected application is an application to be memory reclaimed if the current time is not within a high probability usage time segment of the selected application, By calling a scan performing a reclaim memory; And repeating the steps until the memory reclaim termination condition is met, to determine an application to perform a memory reclaim and to perform a memory reclaim.

메모리 리클레임 종료 조건은 다음의 조건:Memory reclaim termination conditions are as follows:

상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;When the size of the system free memory is larger than a predetermined second threshold value;

현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;When the memory requested by the currently started application is smaller than the system free memory;

포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및The memory required by the application switched to the foreground interface is smaller than the system free memory; And

백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background

중 하나 이상을 포함한다.&Lt; / RTI &gt;

또한, 프로세서(701)는, 어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하고 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하도록 구성된다. 여기서, 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가진다.In addition, the processor 701 groups the applications installed in the terminal according to the frequency of use of the applications, and the applications in the same group have the same use frequency range; And determine a memory re-claim priority order of the application in each group according to a frequency range of use corresponding to each group. Here, applications in the same group have the same priority order.

선택적으로, 또 다른 실시예에서, 프로세서(701)는 또한, 상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하도록 구성된다.Alternatively, in another embodiment, the processor 701 may further determine that the memory reclaim condition is currently satisfied if it is detected that the period of time the application at the terminal has stayed in the background exceeds a predetermined period, The memory reclaim interface provided by the kernel mode is called so that the memory of the application whose period of stay in the background exceeds the predetermined period is reclaimed.

추가로, 단말 장치(700)는 도 2 내지 도 4에서의 방법 및 실시예를 수행할 수 있고, 본 출원의 본 실시예에서 이들에 대한 상세한 설명을 다시 설명하지 않는다.In addition, the terminal device 700 may perform the method and the embodiment in Figs. 2 to 4, and a detailed description thereof will not be described again in the present embodiment of the present application.

앞서 설명한 해결 수단을 이용하여, 어플리케이션이 사용자에 의해 자주 조작되고 사용되며 상대적으로 큰 메모리를 점유할 때 메모리 리클레임 빈도가 증가하여 메모리의 정상적 사용을 보장한다는 것을 이해할 것이다.It will be appreciated that, using the solutions described above, the frequency of memory reclaim increases when an application is frequently manipulated and used by a user and occupies a relatively large memory, thereby ensuring normal use of the memory.

실시예 7Example 7

본 출원의 실시예는 단말(800) 및 메모리 리클레임 방법에 관한 것이고, 단말(800)은 모바일 폰, 태블릿, PDA(Personal Digital Assistant), POS(Point of Sales), 또는 차량 탑재 컴퓨터일 수 있다.The embodiment of the present application relates to a terminal 800 and a memory reclaim method and the terminal 800 can be a mobile phone, a tablet, a PDA (Personal Digital Assistant), a POS (Point of Sales) .

도 8은 본 출원의 실시예에 따른 단말(800)의 개략 구성도이다.8 is a schematic configuration diagram of a terminal 800 according to an embodiment of the present application.

도 8을 참조하면, 본 출원의 본 실시예에서의 단말(800)은, 프로세서(810), 메모리(820), 입력 유닛(830), 전원(850), 무선 주파수(RF) 회로(860), 오디오 주파수 회로(870), 및 와이파이(WiFi) 모듈(880)을 포함한다.8, a terminal 800 in this embodiment of the present application includes a processor 810, a memory 820, an input unit 830, a power supply 850, a radio frequency (RF) circuit 860, An audio frequency circuit 870, and a WiFi module 880.

메모리(820)는 내부 메모리 장치(821) 및 외부 메모리(822)를 포함한다. 내부 메모리 장치(821)는 프로세서(810)의 동작 데이터 및 하드 디스크와 같은 외부 메모리(822)와 교환되는 데이터를 일시적으로 저장하도록 구성된다. 프로세서(810)는 내부 메모리 장치(810)를 이용하여 외부 메모리(822)와 데이터를 교환한다. 내부 메모리 장치(821)는 비휘발성 랜덤 액세스 메모리(NVRAM), 다이내믹 랜덤 액세스 메모리(DRAM), 스태틱 랜덤 액세스 메모리(SRAM), 또는 플래시 메모리 중 하나일 수 있고, 외부 메모리(822)는 하드 디스크, 광 디스크, USB 플래시 드라이브, 플로피 디스크, 또는 테이프 드라이브일 수 있다.The memory 820 includes an internal memory device 821 and an external memory 822. The internal memory device 821 is configured to temporarily store operational data of the processor 810 and data exchanged with an external memory 822, such as a hard disk. The processor 810 exchanges data with the external memory 822 using the internal memory device 810. The internal memory device 821 may be one of a non-volatile random access memory (NVRAM), a dynamic random access memory (DRAM), a static random access memory (SRAM), or a flash memory and the external memory 822 may be a hard disk, Optical disk, USB flash drive, floppy disk, or tape drive.

프로세서(810)는, 사용자 모드에서 메모리 내의 명령을 실행하여, 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하고, 상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행한다. 메모리 리클레임은 소정의 메모리 리클레임 시간 간격에 의해 트리거될 수 있는데, 구체적으로는, 프로세서(810)가 적어도 하나의 미리 설정된 시간 간격에서 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보 및 메모리 점유 정보를 개별로 결정하고, 적어도 하나의 미리 설정된 시간 세그먼트의 각 시간 세그먼트에 대해, 단말에 설치된 어플리케이션의, 그 시간 세그먼트에서의 사용자 조작 및 사용 정보 및 메모리 점유 정보에 따라, 해당 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정한다. 선택적으로, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 메모리 리클레임이 또한 트리거될 수 있다. 메모리 리클레임은 또한, 어플리케이션이 시작되거나 또는 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 트리거될 수 있다. 메모리 리클레임 조건은 또한 백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 트리거될 수 있다. 또한, 여기서 백그라운드에서 실행이 허가된 어플리케이션의 수는 현재 여유 메모리의 크기에 따라 시간 간격에 대해 설정될 수 있다. 백그라운드에서 실행 중인 어플리케이션은 통상 사용자가 현재 사용하는 어플리케이션이 아니기 때문에, 이들 어플리케이션의 수를 제한함으로써 메모리의 과도한 불필요한 점유를 피할 수 있다.The processor 810 executes a command in the memory in the user mode to monitor user operation and usage information and memory occupancy information of the application installed in the terminal and displays user operation and usage information of the application installed in the terminal, If it is determined that the memory reclaim condition is satisfied at present according to at least one of the occupancy information, the information about the currently operating application currently running on the terminal, according to the user operation and usage information, Determines which applications need to be memory reclaimed, and invokes the memory reclaim interface provided by kernel mode to perform memory reclaim. The memory re-claim may be triggered by a predetermined memory reclaim time interval, specifically, the processor 810 may store the user operation and usage information and memory occupancy information of the application installed in the terminal at at least one predetermined time interval And for each time segment of the at least one predetermined time segment, determining, for each time segment of the at least one predetermined time segment, a memory reclaim in the time segment in accordance with user operation and usage information and memory occupancy information of the application installed in the terminal, The time intervals are determined individually. Optionally, if it is determined that the system free memory is less than a predetermined first threshold, a memory reclaim can also be triggered. The memory reclaim can also be triggered, depending on the memory occupancy information of the application and the size of the system free memory, if the application is started or switched to the foreground interface is detected. The memory reclaim condition may also be triggered if the number of currently running applications in the background exceeds a predetermined allowable number of applications that can be executed in the background. Also, the number of applications permitted to run in the background here can be set for the time interval according to the size of the current free memory. Because applications running in the background are not typically the applications the user is currently using, limiting the number of these applications can avoid excessive memory occupation.

선택적으로, 상술한 트리거 조건에 기초하여, 프로세서(810)가 메모리 클레임을 수행하는 프로세스는, 메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및 메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계일 수 있다. 또한, 메모리 리클레임 종료 조건은 다음의 조건: 상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우; 현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및 백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우 중 하나 이상을 포함할 수 있다. 또한, 단말에 설치된 어플리케이션은 어플리케이션의 사용 빈도에 따라 그룹화되는데, 여기서 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가진다. 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서는 각 그룹에 대응하는 사용 빈도 범위에 따라 결정되고, 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가진다.Alternatively, based on the trigger condition described above, the process by which the processor 810 performs the memory claim may include, in accordance with a pre-stored priority order of the application to be memory reclaimed, Selecting an application that is not manipulated or used by the application and determining if the current time is within a high-probability use time segment of the selected application, wherein the high- Determining whether the selected application is an application to be memory reclaimed if the current time is not within a high probability usage time segment of the selected application; Performing a memory reclaim by calling a memory reclaim interface provided by the memory reclaim interface; And repeating the above steps until the memory reclaim end condition is satisfied. Further, the memory reclaim termination condition is satisfied when the size of the system free memory is larger than a predetermined second threshold value; When the memory requested by the currently started application is smaller than the system free memory; The memory required by the application switched to the foreground interface is smaller than the system free memory; And a case where the number of applications running in the background is equal to or less than a predetermined allowable number of applications that can be executed in the background. In addition, the applications installed in the terminal are grouped according to the frequency of use of the applications, wherein the applications in the same group have the same frequency of use. In each group, the application's memory reclaim priority order is determined according to the use frequency range corresponding to each group, and applications in the same group have the same priority order.

추가로, 프로세서(810)는, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 실행한다.In addition, the processor 810 invokes the memory reclaim interface provided by kernel mode to execute the memory reclaim if it is determined that the memory reclaim condition is currently satisfied.

입력 유닛(830)은 입력 숫자 또는 문자 정보를 수신하고, 단말(800)의 사용자 설정 및 기능 제어에 관한 신호 입력을 생성한다. 구체적으로, 본 출원의 본 실시예에서, 입력 유닛(830)은 터치 패널(831)을 포함할 수 있다. 터치 패널(831)은 또한, 터치 스크린이라도 하며, 사용자에 의해 터치 패널의 위 또는 그 근처에서 행해지는 터치 조작(사용자가 터치 패널(831)의 위 또는 그 근처에 스타일러스와 같은 적절한 액세서리나 물건 또는 손가락을 가지고 행하는 조작과 같은)을 수집하고, 미리 설정된 프로그램에 따라 대응하는 연결 장치를 구동한다. 선택적으로, 터치 패널(831)은 두 개의 부분을 포함하는데, 그 두 개의 부분은 터치 검출 장치 및 터치 제어기이다. 터치 검출 장치는 사용자의 터치 움직임을 검출하고, 터치 조작에 의해 야기되는 신호를 검출하며, 터치 제어기에 그 신호를 보낸다. 터치 제어기는 터치 검출 장치로부터 터치 정보를 수신하고, 그 터치 정보를 터치 좌표로 변환하며, 그 터치 좌표를 프로세서(810)에 전송하고, 프로세서(810)에 의해 전송된 명령을 수신하거나 그 명령을 실행한다. 또한, 터치 패널(831)은, 저항형, 용량형, 적외선형, 및 표면 음파형과 같은 여러 형태로 구현될 수 있다. 터치 패널(831)에 더하여, 입력 유닛(830)은 하나 이상의 다른 입력 장치(832)를 포함할 수도 있는데, 이 하나 이상의 다른 입력 장치(832)는, 한정되는 것은 아니지만, 물리적 키보드, 기능키(볼륨키 및 온/오프키 등), 트랙볼, 마우스, 조이스틱 등을 포함할 수 있다.The input unit 830 receives input number or character information and generates a signal input relating to user setting and function control of the terminal 800. [ Specifically, in this embodiment of the present application, the input unit 830 may include a touch panel 831. [ The touch panel 831 may also be a touch screen, and may be a touch operation performed by a user on or near the touch panel, such as a stylus, on or near the touch panel 831, Such as operations performed with a finger, are collected, and the corresponding connection device is driven according to a preset program. Alternatively, the touch panel 831 includes two parts, the touch detection device and the touch controller. The touch detection device detects the touch movement of the user, detects a signal caused by the touch operation, and sends the signal to the touch controller. The touch controller receives the touch information from the touch detection device, converts the touch information to touch coordinates, transmits the touch coordinates to the processor 810, receives the command transmitted by the processor 810, . The touch panel 831 may be implemented in various forms such as a resistance type, a capacitive type, an infrared type, and a surface acoustic wave type. In addition to the touch panel 831, the input unit 830 may include one or more other input devices 832, which may include, but are not limited to, a physical keyboard, a function key Volume keys and on / off keys, etc.), trackballs, mice, joysticks, and the like.

단말(800)은 또한, 표시 유닛(840)을 더 포함할 수 있는데, 표시 유닛(840)은 단말(800)의 여러 메뉴 인터페이스뿐 아니라 사용자를 위해 제공되는 정보나 사용자가 입력한 정보를 표시하도록 구성된다, 표시 유닛(840)은 표시 패널(841)을 포함할 수 있다. 선택적으로, LCD, OLED 등의 형태가 표시 패널(841)을 구성하기 위해 사용될 수 있다.The terminal 800 may further include a display unit 840 that displays various menu interfaces of the terminal 800 as well as information provided for the user or information entered by the user The display unit 840 may include a display panel 841. [ Alternatively, an LCD, an OLED, or the like may be used to form the display panel 841.

본 출원의 본 실시예에서, 터치 패널(831)은 표시 패널(841)을 덮어서 터치 표시 스크린을 구성할 수 있다. 터치 표시 스크린 위 또는 근처에서 터치 조작을 검출한 때, 터치 표시 스크린은 터치 조작을 프로세서(810)에 전송하여 터치 이벤트의 유형을 결정하고, 그런 다음 프로세서(810)는 대응하는 시각적 출력을 그 터치 이벤트의 유형에 따라 터치 표시 스크린상에 출력한다.In this embodiment of the present application, the touch panel 831 covers the display panel 841 to configure a touch display screen. Upon detecting a touch operation on or near the touch display screen, the touch display screen transmits a touch operation to the processor 810 to determine the type of touch event, and then the processor 810 transmits the corresponding visual output to the touch It is output on the touch display screen according to the event type.

본 출원의 본 실시예에서, 터치 표시 스크린은 어플리케이션 인터페이스 표시 영역과 공통 제어 표시 영역을 포함한다. 어플리케이션 인터페이스 표시 영역과 공통 제어 표시 영역의 배치 방식은 제한되어 있지 않고, 이들 두 개의 표시 영역을, 상하 배치 또는 좌우 배치로 하여 구별할 수 있도록 하는 배치 방법일 수 있다. 어플리케이션 인터페이스 표시 영역은 어플리케이션 프로그램 인터페이스를 표시하기 위해 사용될 수 있다. 각 인터페이스는 적어도 하나의 어플리케이션 프로그램의, 아이콘 또는 홈 스크린 위젯 또는 두 개 모두와 같은, 인터페이스 요소를 포함할 수 있다. 어플리케이션 인터페이스 표시 영역은 또한, 콘텐츠가 없는 비어 있는 인터페이스일 수 있다. 공통 제어 표시 영역은, 설정 버튼, 인터페이스 수, 스크롤 바, 전화번호부 아이콘 등과 같은 상대적으로 높은 사용도의 어플리케이션 프로그램 아이콘에 대한 제어를 표시하기 위해 사용될 수 있다.In this embodiment of the present application, the touch display screen includes an application interface display area and a common control display area. The arrangement manner of the application interface display area and the common control display area is not limited and the two display areas can be arranged in a top-down arrangement or a left-right arrangement. The application interface display area can be used to display an application program interface. Each interface may include an interface element, such as an icon or a home screen widget or both, of at least one application program. The application interface display area may also be an empty interface with no content. The common control display area can be used to display control for a relatively high-use application program icon, such as a set button, a number of interfaces, a scroll bar, a phonebook icon, and the like.

프로세서(810)는 단말(800)의 제어 센터이고, 다양한 인터페이스와 선을 사용하여 전체 모바일 폰의 각 부를 연결한다. 내부 메모리 장치(821)에 저장된 소프트웨어 프로그램 또는 모듈을 실행하고 외부 메모리(822)에 저장된 데이터를 호출함으로써, 프로세서(810)는 단말(800)의 여러 가지 기능을 실행하고, 데이터를 처리하여, 단말(800)에 대한 전체적인 모니터링을 수행한다.The processor 810 is a control center of the terminal 800 and connects various parts of the entire mobile phone using various interfaces and lines. The processor 810 executes various functions of the terminal 800 and processes the data by executing the software program or module stored in the internal memory device 821 and calling the data stored in the external memory 822, Gt; 800 &lt; / RTI &gt;

통상의 기술자라면 본 출원의 실시예들이 방법, 시스템 또는 컴퓨터 프로그램 제품으로 제공될 수 있음을 이해할 것이다. 그러므로, 본 출원은 하드웨어만의 실시예, 소프트웨어만의 실시예, 또는 소프트웨어와 하드웨어의 조합의 실시예의 형태를 이용할 수 있다. 게다가, 본 출원은 컴퓨터에서 사용 가능한 프로그램 코드를 포함하는 하나 이상의 컴퓨터에서 사용 가능한 저장 매체(디스크 메모리, CD-ROM, 광 메모리 등을 포함하지만 한정되는 것은 아님)에 구현된다.It will be appreciated by those of ordinary skill in the art that the embodiments of the present application may be provided as a method, system, or computer program product. Thus, the present application may utilize only hardware-specific embodiments, software-only embodiments, or combinations of software and hardware embodiments. In addition, the present application is embodied in a storage medium (including, but not limited to, disk memory, CD-ROM, optical memory, etc.) usable in one or more computers containing program code usable in a computer.

본 출원에서는, 본 출원의 실시예에 따른 방법, 장치(시스테) 및 컴퓨터 프로그램 제품에 대해 흐름도 및/또는 블록도를 참조하여 설명하였다. 컴퓨터 프로그램 명령을 이용하여 흐름도 및/또는 블록도 내의 각 프로세서 및/또는 블록, 그리고 흐름도 및/또는 블록도 내의 프로세스 및/또는 블록의 조합을 구현할 수 있다. 이들 컴퓨터 프로그램 명령은 범용 컴퓨터, 전용 컴퓨터, 임베디드 프로세서, 또는 다른 어떤 프로그래머블 데이터 처리 장치의 프로세서가 머신을 생성하고, 이로써 컴퓨터 또는 다른 어떤 프로그래머블 데이터 처리 장치의 프로세서가 흐름도 내의 하나 이상의 프로세서 및/또는 블록도 내의 하나 이상의 블록에서의 구체적인 기능을 구현하기 위한 장치를 생성할 수 있도록 한다.The present application has been described with reference to flowcharts and / or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the present application. Computer program instructions may be used to implement each processor and / or block within the flowchart and / or block diagrams, and combinations of processes and / or blocks within the flowcharts and / or block diagrams. These computer program instructions may be executed by a processor of a general purpose computer, a special purpose computer, an embedded processor, or any other programmable data processing apparatus to create a machine, such that a computer or other programmable data processing apparatus may be used by one or more processors and / Thereby enabling to create devices for implementing specific functions in one or more blocks within the diagram.

이들 컴퓨터 프로그램 명령은 또한, 컴퓨터 또는 다른 어떤 프로그래머블 데이터 처리 장치로 하여금 특정한 방식으로 동작하도록 지시하는 컴퓨터 판독 가능한 메모리에 저장될 수 있는데, 이로써 컴퓨터 판독 가능한 메모리에 저장된 명령은 명령 장치를 포함하는 인공물을 생성한다. 명령 장치는 흐름도 내의 하나 이상의 프로세스 및/또는 블록도 내의 하나 이상의 블록 내의 특정 기능을 구현한다.These computer program instructions may also be stored in a computer-readable memory that directs a computer or other programmable data processing apparatus to operate in a particular manner so that the instructions stored in the computer-readable memory may cause an artifact . An instruction device implements a particular function within one or more blocks within one or more processes and / or block diagrams in the flowchart.

이러한 컴퓨터 프로그램 명령은 또한 컴퓨터 또는 다른 프로그래머블 데이터 처리 장치에 로딩될 수도 있으며, 이로써 일련의 동작 및 단계가 그 컴퓨터 또는 다른 프로그래머블 데이터 처리 장치에서 수행되어 컴퓨터에 의해 구현되는 프로세싱을 생성한다. 그러므로, 컴퓨터 또는 다른 프로그래머블 데이터 처리 장치에서 실행되는 명령은 흐름도 내의 하나 이상의 프로세스 및/또는 블록도 내의 하나 이상의 블록 내의 특정 기능을 구현하기 위한 단계들을 제공한다.Such computer program instructions may also be loaded into a computer or other programmable data processing apparatus whereby a series of operations and steps are performed on the computer or other programmable data processing apparatus to produce processing implemented by the computer. Thus, instructions executed on a computer or other programmable data processing apparatus provide steps for implementing particular functions within one or more blocks within one or more processes and / or block diagrams in the flowchart.

본 출원의 몇몇 바람직한 실시예를 설명하였지만, 통상의 기술자라면, 그들이 기본적인 개념을 습득하면 이들 실시예들을 변형하고 변경할 수 있다. 그러므로, 그러한 바람직한 실시예 및 모든 변경 및 변형이 본 출원의 보호범위 내에 있는지에 대해 이하의 청구범위의 해석에 의해야 한다.While a few preferred embodiments of the present application have been described, it will be appreciated by those of ordinary skill in the art that modifications and variations may be made thereto as long as they acquire basic concepts. Therefore, it should be understood that such preferred embodiments and all changes and modifications are within the scope of protection of the present application by interpretation of the following claims.

분명한 것은, 통상의 기술자라면 본 출원의 기술적 사상이나 보호범위를 벗어나지 않고 본 출원에 대해 다양한 변형과 수정을 가할 수 있다. 이 경우, 본 출원은, 그러한 것들이 본 출원의 청구범위에 의해 정의되는 보호범위 및 그 균등의 범위에 포함된다면, 본 출원의 변형 및 수정을 포함하는 것으로 이해되어야 한다.Obviously, many modifications and variations of the present invention can be made by those skilled in the art without departing from the spirit and scope of the invention. In this case, the present application should be understood as including modifications and variations of the present application, as long as they fall within the scope of protection defined by the claims of the present application and equivalents thereof.

Claims (20)

메모리 리클레임 방법(memory reclaim method)으로서,
단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하는 단계; 및
상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면,
상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계
를 사용자 모드에서 실행하는
메모리 리클레임 방법.
As a memory reclaim method,
Monitoring user operation and usage information and memory occupancy information of an application installed in the terminal; And
If it is determined that the memory reclaim condition is currently satisfied in accordance with at least one of the user operation and use information or memory occupancy information of the application installed in the terminal,
Determining an application to be subjected to a memory reclaim among applications currently being executed in the terminal according to user operation and use information and memory occupancy information of an application currently being executed in the terminal and generating a memory reclaim Steps to invoke an interface to perform a memory reclaim
To run in user mode
Memory reclaim method.
제1항에 있어서,
상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은,
상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계; 및
현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계
를 포함하는, 메모리 리클레임 방법.
The method according to claim 1,
Determining that the memory reclaim condition is currently satisfied in accordance with at least one of the user operation and usage information and the memory occupancy information of the application installed in the terminal,
Determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal; And
Determining that the memory reclaim condition is currently satisfied when the current time has reached a memory reclaim time indicated by the memory reclaim time interval
The method comprising the steps of:
제2항에 있어서,
상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하는 단계는,
상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하는 단계; 및
상기 적어도 하나의 미리 설정된 시간 세그먼트 각각에 대해, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하는 단계
를 포함하는, 메모리 리클레임 방법.
3. The method of claim 2,
The step of determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal,
Individually determining user operation and usage information and memory occupancy information in each of at least one predetermined time segment of an application installed in the terminal; And
For each of the at least one predetermined time segment, a memory reclaim time interval in each time segment, in accordance with user operation and usage information and memory occupancy information in each time segment of an application installed in the terminal &Lt; / RTI &gt;
The method comprising the steps of:
제1항에 있어서,
상기 단말에 설치된 어플리케이션의 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은,
시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함하는,
메모리 리클레임 방법.
The method according to claim 1,
Determining that the memory reclaim condition is currently satisfied based on the memory occupancy information of the application installed in the terminal,
Determining that the memory reclaim condition is currently satisfied if it is determined that the system free memory is less than a predetermined first threshold,
Memory reclaim method.
제1항에 있어서,
상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은,
어플리케이션이 시작되거나 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하는 단계; 및
메모리 리클레임을 수행해야 하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계
를 포함하는, 메모리 리클레임 방법.
The method according to claim 1,
Determining that the memory reclaim condition is currently satisfied based on the user operation and use information and the memory occupancy information of the application installed in the terminal,
Determining whether to perform a memory reclaim according to the memory occupancy information of the application and the size of the system free memory when the application is started or switching to the foreground interface is detected; And
If it is necessary to perform a memory reclaim, the step of determining that the memory reclaim condition is currently satisfied
The method comprising the steps of:
제1항에 있어서,
상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 것은,
백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하는 단계를 포함하는,
메모리 리클레임 방법.
The method according to claim 1,
Determining that the memory reclaim condition is currently satisfied in accordance with user operation and usage information of an application installed in the terminal,
Determining that a memory reclaim condition is currently satisfied if the number of applications currently running in the background exceeds a predetermined allowable number of applications that can be executed in the background,
Memory reclaim method.
제2항 내지 제6항 중 어느 한 항에 있어서,
상기 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계는,
메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및
메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계
를 포함하는,
메모리 리클레임 방법.
7. The method according to any one of claims 2 to 6,
Determining an application to which the memory reclaim is to be made, and invoking a memory reclaim interface provided by the kernel mode to perform a memory reclaim,
Selects an application that is not operated or used by a user as an application currently being executed in the terminal according to a pre-stored priority order of the application to be memory reclaimed, and determines that the current time is a high-probability usage time segment probability use time segment of the selected application, wherein the high-probability usage time segment of the application is determined based on user operation and usage information of the application, and wherein the current time is within a high- Determining that the selected application is an application to be memory reclaimed and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode; And
Repeating the step until the memory reclaim termination condition is satisfied
/ RTI &gt;
Memory reclaim method.
제7항에 있어서,
상기 메모리 리클레임 종료 조건은 다음의 조건:
상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;
현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;
포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및
백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우
중 하나 이상을 포함하는,
메모리 리클레임 방법.
8. The method of claim 7,
The memory reclaim ending condition is the following condition:
When the size of the system free memory is larger than a predetermined second threshold value;
When the memory requested by the currently started application is smaller than the system free memory;
The memory required by the application switched to the foreground interface is smaller than the system free memory; And
If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background
&Lt; / RTI &gt;
Memory reclaim method.
제7항 또는 제8항에 있어서,
메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서가 다음의 단계:
어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및
각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -
에 따라 설정되는,
메모리 리클레임 방법.
9. The method according to claim 7 or 8,
The order of priority for applications that need to reclaim memory is as follows:
Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And
Determining a memory re-claim priority order of an application in each group according to a use frequency range corresponding to each group; the applications in the same group have the same priority order;
Lt; / RTI &gt;
Memory reclaim method.
제1항에 있어서,
상기 단말에 설치된 어플리케이션의 사용자 조작 및 사용 정보에 따라, 상기 메모리 리클레임 조건이 충족된 것으로 결정되면, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하는 단계는,
상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하는 단계를 포함하는,
메모리 리클레임 방법.
The method according to claim 1,
Wherein the step of calling a memory reclaim interface provided by the kernel mode to perform a memory reclaim when the memory reclaim condition is determined to be satisfied according to user operation and usage information of an application installed in the terminal,
Determining that the memory reclaim condition is currently satisfied if it is detected that the application in the terminal is in the background for a predetermined period of time, calling the memory reclaim interface provided by the kernel mode, Comprising: reclaiming a memory of an application whose period of stay in a predetermined period exceeds a predetermined period;
Memory reclaim method.
메모리 리클레임 장치로서,
사용자 모드에서, 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 모니터링하도록 구성된 결정 모듈; 및
상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보 또는 메모리 점유 정보 중 적어도 하나에 따라, 메모리 리클레임 조건이 현재 충족된 것으로 결정되면, 상기 단말에서 현재 실행 중인 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 단말에서 현재 실행 중인 어플리케이션 중 메모리 리클레임을 해야 할 어플리케이션을 결정하고, 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출하여 메모리 리클레임을 수행하도록 구성된 메모리 리클레임 모듈
을 포함하는 메모리 리클레임 장치.
A memory reclaim device,
A determination module configured to monitor user operation and use information and memory occupancy information of an application installed in the terminal in a user mode; And
If the memory reclaim condition is determined to be satisfied at present according to at least one of the user operation and use information or memory occupancy information of the application installed in the terminal, user operation and use information of an application currently being executed in the terminal, A memory reclaim module configured to determine an application to be memory reclaimed from currently running applications in the terminal according to the memory occupancy information and to perform a memory reclaim by calling a memory reclaim interface provided by the kernel mode,
And the memory requesting device.
제11항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로,
상기 단말에 설치된 어플리케이션의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라 메모리 리클레임 시간 간격을 결정하고, 현재 시간이 상기 메모리 리클레임 시간 간격에 의해 지시되는 메모리 리클레임 시간에 도달한 때 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된,
메모리 리클레임 장치.
12. The method of claim 11,
Specifically, the memory reclaim module includes:
Determining a memory reclaim time interval according to user operation and usage information and memory occupancy information of an application installed in the terminal, and when the current time reaches a memory reclaim time indicated by the memory reclaim time interval, Configured to determine that a memory reclaim condition is currently satisfied,
Memory reclaim device.
제12항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로, 다음의 단계:
상기 단말에 설치된 어플리케이션의, 적어도 하나의 미리 설정된 시간 세그먼트 각각에서, 사용자 조작 및 사용 정보, 및 메모리 점유 정보를 개별로 결정하는 단계; 및
상기 적어도 하나의 미리 설정된 시간 세그먼트 각각 동안, 상기 단말에 설치된 어플리케이션의, 상기 각 시간 세그먼트에서의, 사용자 조작 및 사용 정보, 및 메모리 점유 정보에 따라, 상기 각 시간 세그먼트 내에서 메모리 리클레임 시간 간격을 개별로 결정하는 단계
에 따라 메모리 리클레임 시간 간격을 결정하도록 구성된,
메모리 리클레임 장치.
13. The method of claim 12,
The memory reclaim module specifically includes the following steps:
Individually determining user operation and usage information and memory occupancy information in each of at least one predetermined time segment of an application installed in the terminal; And
A memory reclaim time interval within each time segment is determined according to user operation and usage information and memory occupancy information in each time segment of an application installed in the terminal during each of the at least one predetermined time segment Steps to be individually determined
And to determine a memory reclaim time interval in accordance with the &lt; RTI ID = 0.0 &gt;
Memory reclaim device.
제11항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로, 시스템 여유 메모리가 소정의 제1 임계치보다 적다고 결정되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된, 메모리 리클레임 장치.
12. The method of claim 11,
The memory reclaim module is configured to conclude that the memory reclaim condition is currently satisfied if it is determined that the system free memory is less than a predetermined first threshold.
제11항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로,
어플리케이션이 시작되거나 또는 포어그라운드 인터페이스로 전환되는 것이 검출되면, 상기 어플리케이션의 메모리 점유 정보 및 시스템 여유 메모리의 크기에 따라, 메모리 리클레임을 수행해야 할지를 결정하고,
메모리 리클레임을 수행해야 하는 경우, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된,
메모리 리클레임 장치.
12. The method of claim 11,
Specifically, the memory reclaim module includes:
When it is detected that the application is started or switched to the foreground interface, it is determined whether to perform the memory reclaim according to the memory occupancy information of the application and the size of the system free memory,
And to determine that the memory reclaim condition is currently satisfied if the memory reclaim is to be performed,
Memory reclaim device.
제11항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로,
백그라운드에서 현재 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정 허용 수량을 초과하는 경우, 메모리 리클레임 조건이 현재 충족된 것으로 결정하도록 구성된,
메모리 리클레임 장치.
12. The method of claim 11,
Specifically, the memory reclaim module includes:
Configured to determine that a memory reclaim condition is currently satisfied if the number of currently running applications in the background exceeds a predetermined allowed number of applications that can be executed in the background,
Memory reclaim device.
제12항 내지 제16항 중 어느 한 항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로,
메모리 리클레임을 해야 할 어플리케이션의 미리 저장된 우선순위 순서에 따라, 상기 단말에서 현재 실행 중인 어플리케이션으로서 사용자에 의해 조작 또는 사용되지 않는 어플리케이션을 선택하고, 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트(high-probability use time segment) 내에 있는지를 결정하고, 여기서 상기 어플리케이션의 고확률 사용 시간 세그먼트는 상기 어플리케이션의 사용자 조작 및 사용 정보에 기초하여 결정되며, 상기 현재 시간이 상기 선택된 어플리케이션의 고확률 사용 시간 세그먼트 내에 있지 않으면, 상기 선택된 어플리케이션은 메모리 리클레임을 해야 할 어플리케이션인 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써 메모리 리클레임을 수행하는 단계; 및
메모리 리클레임 종료 조건이 충족될 때까지 상기 단계를 반복하는 단계
에 따라 메모리 리클레임을 수행하도록 구성된,
메모리 리클레임 장치.
17. The method according to any one of claims 12 to 16,
Specifically, the memory reclaim module includes:
Selects an application that is not operated or used by a user as an application currently being executed in the terminal according to a pre-stored priority order of the application to be memory reclaimed, and determines that the current time is a high-probability usage time segment probability use time segment of the selected application, wherein the high-probability usage time segment of the application is determined based on user operation and usage information of the application, and wherein the current time is within a high- Determining that the selected application is an application to be memory reclaimed and performing a memory reclaim by calling a memory reclaim interface provided by the kernel mode; And
Repeating the step until the memory reclaim termination condition is satisfied
Configured to perform memory reclamation according to the &lt; RTI ID = 0.0 &gt;
Memory reclaim device.
제17항에 있어서,
상기 메모리 리클레임 종료 조건은 다음의 조건:
상기 시스템 여유 메모리의 크기가 소정의 제2 임계치보다 더 큰 경우;
현재 시작된 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우;
포어그라운드 인터페이스로 전환되는 어플리케이션에 의해 요구되는 메모리가 상기 시스템 여유 메모리보다 더 작은 경우; 및
백그라운드에서 실행 중인 어플리케이션의 수량이 백그라운드에서 실행될 수 있는 어플리케이션의 소정의 허용 수량과 같거나 그보다 작은 경우
중 하나 이상을 포함하는,
메모리 리클레임 장치.
18. The method of claim 17,
The memory reclaim ending condition is the following condition:
When the size of the system free memory is larger than a predetermined second threshold value;
When the memory requested by the currently started application is smaller than the system free memory;
The memory required by the application switched to the foreground interface is smaller than the system free memory; And
If the number of applications running in the background is less than or equal to the predetermined allowed number of applications that can run in the background
&Lt; / RTI &gt;
Memory reclaim device.
제17항 또는 제18항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로,
어플리케이션의 사용 빈도에 따라 단말에 설치된 어플리케이션을 그룹화하는 단계 - 동일 그룹 내의 어플리케이션은 동일한 사용 빈도 범위를 가짐 -; 및
각 그룹에 대응하는 사용 빈도 범위에 따라 각 그룹에서 어플리케이션의 메모리 리클레임 우선순위 순서를 결정하는 단계 - 동일 그룹 내의 어플리케이션은 동일 우선순위 순서를 가짐 -
에 따라 메모리 리클레임을 해야 하는 어플리케이션의 우선순위 순서를 설정하도록 구성된,
메모리 리클레임 장치.
The method according to claim 17 or 18,
Specifically, the memory reclaim module includes:
Grouping the applications installed in the terminal according to the usage frequency of the application, the applications in the same group having the same frequency of use range; And
Determining a memory re-claim priority order of an application in each group according to a use frequency range corresponding to each group; the applications in the same group have the same priority order;
Configured to set a priority order of applications that need to be memory reclaimed according to the priority of the application,
Memory reclaim device.
제11항에 있어서,
상기 메모리 리클레임 모듈은 구체적으로,
상기 단말에서의 어플리케이션이 백그라운드에 체류하는 기간이 소정 기간을 초과하는 것이 검출되면, 상기 메모리 리클레임 조건이 현재 충족된 것으로 결정하고, 상기 커널 모드에 의해 제공되는 메모리 리클레임 인터페이스를 호출함으로써, 백그라운드에 체류하는 기간이 소정 기간을 초과한 어플리케이션의 메모리를 리클레임하도록 구성된,
메모리 리클레임 장치.
12. The method of claim 11,
Specifically, the memory reclaim module includes:
Determining that the memory reclaim condition is currently satisfied if the period in which the application at the terminal is staying in the background exceeds a predetermined period of time and calling the memory reclaim interface provided by the kernel mode, The memory of the application having a period of stay in a predetermined period exceeding a predetermined period,
Memory reclaim device.
KR1020187020861A 2015-12-31 2016-12-22 Memory reclaim method and apparatus KR20180097674A (en)

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
CN201511032537.7 2015-12-31
CN201511032537.7A CN105701025B (en) 2015-12-31 2015-12-31 A kind of method for recovering internal storage and device
PCT/CN2016/111557 WO2017114288A1 (en) 2015-12-31 2016-12-22 Memory collection method and device

Related Child Applications (1)

Application Number Title Priority Date Filing Date
KR1020207027212A Division KR102206364B1 (en) 2015-12-31 2016-12-22 Memory collection method and device

Publications (1)

Publication Number Publication Date
KR20180097674A true KR20180097674A (en) 2018-08-31

Family

ID=56226841

Family Applications (2)

Application Number Title Priority Date Filing Date
KR1020187020861A KR20180097674A (en) 2015-12-31 2016-12-22 Memory reclaim method and apparatus
KR1020207027212A KR102206364B1 (en) 2015-12-31 2016-12-22 Memory collection method and device

Family Applications After (1)

Application Number Title Priority Date Filing Date
KR1020207027212A KR102206364B1 (en) 2015-12-31 2016-12-22 Memory collection method and device

Country Status (5)

Country Link
US (1) US11023372B2 (en)
EP (1) EP3388946B1 (en)
KR (2) KR20180097674A (en)
CN (1) CN105701025B (en)
WO (1) WO2017114288A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022059978A1 (en) * 2020-09-21 2022-03-24 삼성전자(주) Electronic device and control method thereof

Families Citing this family (61)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105701025B (en) 2015-12-31 2019-07-23 华为技术有限公司 A kind of method for recovering internal storage and device
CN106201717A (en) * 2016-07-01 2016-12-07 珠海市魅族科技有限公司 A kind of method managing Installed System Memory and terminal
CN107766128B (en) 2016-08-17 2021-01-29 华为技术有限公司 Method and device for starting application
CN109213539B (en) * 2016-09-27 2021-10-26 华为技术有限公司 Memory recovery method and device
CN107885666B (en) 2016-09-28 2021-07-20 华为技术有限公司 Memory management method and device
CN106484472B (en) 2016-09-29 2021-06-15 华为技术有限公司 Memory recovery method and terminal
CN106502740B (en) * 2016-10-31 2019-08-06 北京小米移动软件有限公司 Using installation method and device
CN106844032A (en) * 2017-01-23 2017-06-13 努比亚技术有限公司 The storage processing method and device of a kind of terminal applies
CN106843450A (en) * 2017-01-23 2017-06-13 努比亚技术有限公司 The storage processing method and device of a kind of terminal applies
CN106803860B (en) * 2017-01-23 2020-12-29 努比亚技术有限公司 Storage processing method and device for terminal application
CN106951327B (en) * 2017-03-23 2018-11-30 维沃移动通信有限公司 The detection method and mobile terminal of a kind of application program to systematic influence
CN107168791A (en) * 2017-04-13 2017-09-15 北京安云世纪科技有限公司 Terminal Memory Optimize Method, device and mobile terminal under bright screen state
CN107249074A (en) * 2017-05-16 2017-10-13 努比亚技术有限公司 Application program quick start method, mobile terminal and computer-readable recording medium
CN109271247A (en) * 2017-07-12 2019-01-25 珠海市魅族科技有限公司 Memory Optimize Method, device, computer installation and storage medium
CN108228341B (en) * 2017-08-07 2021-03-02 珠海市魅族科技有限公司 Memory recovery method and device, terminal equipment and computer readable storage medium
CN107395744A (en) * 2017-08-18 2017-11-24 广东欧珀移动通信有限公司 Method of data synchronization, mobile terminal and storage medium
CN108228343B (en) * 2017-08-21 2020-11-17 珠海市魅族科技有限公司 Memory recovery method and device, computer device and computer readable storage medium
CN109600409B (en) * 2017-09-30 2022-08-19 华为终端有限公司 Resource management method and terminal for application
CN107704876B (en) * 2017-09-30 2020-09-08 Oppo广东移动通信有限公司 Application control method, device, storage medium and electronic equipment
CN109669733A (en) * 2017-10-12 2019-04-23 腾讯科技(深圳)有限公司 A kind of method and device of terminal device memory management
CN107844342B (en) * 2017-11-21 2021-07-09 Oppo广东移动通信有限公司 Control method and device for keeping application program alive, storage medium and mobile terminal
CN108052388A (en) * 2017-11-24 2018-05-18 武汉斗鱼网络科技有限公司 Method for recovering internal storage and device in a kind of Android
CN107807857B (en) * 2017-11-29 2021-05-21 努比亚技术有限公司 Method and device for cleaning running memory and computer storage medium
CN108279975B (en) * 2017-12-11 2022-01-14 努比亚技术有限公司 Memory control method, mobile terminal, data interaction method and server
CN109992402B (en) 2017-12-29 2021-07-09 Oppo广东移动通信有限公司 Memory processing method and device, electronic equipment and computer readable storage medium
CN109992393A (en) 2017-12-29 2019-07-09 广东欧珀移动通信有限公司 Application processing method and device, electronic equipment, computer readable storage medium
CN110018902B (en) * 2018-01-10 2023-01-31 Oppo广东移动通信有限公司 Memory processing method and device, electronic equipment and computer readable storage medium
CN110018900B (en) * 2018-01-10 2023-01-24 Oppo广东移动通信有限公司 Memory processing method and device, electronic equipment and computer readable storage medium
CN110018901B (en) * 2018-01-10 2021-08-03 Oppo广东移动通信有限公司 Memory recovery method and device, computer equipment and computer readable storage medium
CN110018899B (en) * 2018-01-10 2021-09-07 华为技术有限公司 Method and device for recycling memory
CN110032321B (en) * 2018-01-12 2024-02-20 Oppo广东移动通信有限公司 Application processing method and device, electronic equipment and computer readable storage medium
CN108600840B (en) * 2018-03-29 2020-07-10 深圳市九洲电器有限公司 Set top box power consumption control method and system
CN108563506A (en) * 2018-04-11 2018-09-21 青岛海信移动通信技术股份有限公司 The method for recovering internal storage and device of mobile terminal
CN110377527B (en) * 2018-04-13 2023-09-22 华为技术有限公司 Memory management method and related equipment
CN108932163A (en) * 2018-06-15 2018-12-04 奇酷互联网络科技(深圳)有限公司 EMS memory management process, device, readable storage medium storing program for executing and terminal
KR20200027204A (en) * 2018-09-04 2020-03-12 삼성전자주식회사 Electronic apparatus and method for controlling thereof
CN109857556B (en) * 2019-01-15 2021-01-08 Oppo广东移动通信有限公司 Memory recovery method and device, storage medium and electronic equipment
CN110096357A (en) * 2019-03-29 2019-08-06 北京奇安信科技有限公司 A kind of the memory source method for cleaning and device of distributed system
CN110083450A (en) * 2019-04-09 2019-08-02 Oppo广东移动通信有限公司 Method for recovering internal storage, device, electronic equipment and storage medium
US11327809B2 (en) 2019-06-19 2022-05-10 International Business Machines Corporation Virtual machine memory removal increment selection
CN112328316B (en) * 2019-08-02 2023-01-24 Tcl科技集团股份有限公司 APP optimization method, mobile terminal and storage medium
CN112445606A (en) * 2019-08-30 2021-03-05 华为技术有限公司 Memory recovery method and device
CN110673955B (en) * 2019-09-20 2022-07-12 北京字节跳动网络技术有限公司 Method, device, system, terminal and storage medium for optimizing memory
CN110727607B (en) * 2019-09-27 2022-08-12 Oppo广东移动通信有限公司 Memory recovery method and device and electronic equipment
CN110727606A (en) * 2019-09-27 2020-01-24 Oppo(重庆)智能科技有限公司 Memory recovery method and device and electronic equipment
CN110795239A (en) * 2019-10-15 2020-02-14 浙江口碑网络技术有限公司 Application memory leakage detection method and device
CN111045779B (en) * 2019-11-01 2024-03-01 福建天泉教育科技有限公司 System memory recovery configuration method and storage medium
CN111078406B (en) * 2019-12-10 2023-01-10 Oppo(重庆)智能科技有限公司 Memory management method and device, storage medium and electronic equipment
CN111258921B (en) * 2020-01-14 2024-01-26 Oppo广东移动通信有限公司 Garbage memory recycling method and device, electronic equipment and storage medium
CN111262737B (en) * 2020-01-16 2023-11-28 圆山电子科技(深圳)有限公司 Port configuration management method and device, storage medium and terminal
US11314662B2 (en) * 2020-03-05 2022-04-26 Fortinet, Inc. Providing a secure communication channel between kernel and user mode components
CN113590500A (en) * 2020-04-30 2021-11-02 华为技术有限公司 Memory management method and terminal equipment
CN111679914B (en) * 2020-06-12 2023-06-27 北京字节跳动网络技术有限公司 Memory management method, system, computer equipment and storage medium
CN111756922A (en) * 2020-06-15 2020-10-09 北京智明星通科技股份有限公司 Method and system for running mobile phone game and game terminal
CN111782294A (en) * 2020-06-28 2020-10-16 珠海豹趣科技有限公司 Application program running method and device, electronic equipment and storage medium
CN114443268A (en) * 2020-10-31 2022-05-06 华为终端有限公司 Memory management method and device, electronic equipment and computer readable storage medium
US11442832B2 (en) * 2020-11-24 2022-09-13 Hewlett Packard Enterprise Development Lp Managing synchronized reboot of a system
CN112817759B (en) * 2021-01-26 2023-06-16 广州欢网科技有限责任公司 TV video application memory occupation optimization method and device and television terminal
CN113886060B (en) * 2021-05-28 2022-09-23 荣耀终端有限公司 Method and device for compressing memory
WO2023048454A1 (en) * 2021-09-21 2023-03-30 Samsung Electronics Co., Ltd. Method and electronic device for managing memory
CN117130947A (en) * 2023-01-31 2023-11-28 荣耀终端有限公司 Memory management method and electronic equipment

Family Cites Families (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7412694B2 (en) * 2003-09-18 2008-08-12 International Business Machines Corporation Detecting program phases with periodic call-stack sampling during garbage collection
US20060074872A1 (en) * 2004-09-30 2006-04-06 International Business Machines Corporation Adaptive database buffer memory management using dynamic SQL statement cache statistics
CN1770125A (en) * 2004-11-04 2006-05-10 华为技术有限公司 Memory allocation method
CN101833512A (en) 2010-04-22 2010-09-15 中兴通讯股份有限公司 Method and device thereof for reclaiming memory
DE112011103979T5 (en) * 2010-11-30 2013-08-29 International Business Machines Corporation Computer program and system for a method of optimizing memory management of an application running on a virtual machine
CN102799471B (en) * 2012-05-25 2014-11-05 上海斐讯数据通信技术有限公司 Method and system for process recycling of operating system
CN103246568A (en) * 2013-04-16 2013-08-14 深圳桑菲消费通信有限公司 Mobile phone application priority setting method and device
CN104111873B (en) * 2013-04-22 2019-02-26 深圳富泰宏精密工业有限公司 Memory release method and system
CN103324500B (en) * 2013-05-06 2016-08-31 广州市动景计算机科技有限公司 A kind of method and device reclaiming internal memory
CN103544063B (en) * 2013-09-30 2017-02-08 三星电子(中国)研发中心 Method and device for removing processes applied to Android platform
US20150095603A1 (en) 2013-09-30 2015-04-02 Samsung Electronics Co., Ltd. Method and device for clearing process in electronic device
CN104050035B (en) * 2014-05-14 2018-05-25 小米科技有限责任公司 The processing method and processing device of application program
US9690685B2 (en) * 2014-05-30 2017-06-27 Apple Inc. Performance management based on resource consumption
US10642663B2 (en) * 2014-09-10 2020-05-05 Oracle International Corporation Coordinated garbage collection in distributed systems
CN104298612A (en) * 2014-09-30 2015-01-21 北京金山安全软件有限公司 Method and device for cleaning memory in mobile terminal and mobile terminal
US9940040B2 (en) * 2015-08-26 2018-04-10 Toshiba Memory Corporation Systems, solid-state mass storage devices, and methods for host-assisted garbage collection
CN105701025B (en) * 2015-12-31 2019-07-23 华为技术有限公司 A kind of method for recovering internal storage and device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022059978A1 (en) * 2020-09-21 2022-03-24 삼성전자(주) Electronic device and control method thereof

Also Published As

Publication number Publication date
US20180307600A1 (en) 2018-10-25
BR112018013524A2 (en) 2018-12-11
EP3388946B1 (en) 2022-04-06
KR102206364B1 (en) 2021-01-21
WO2017114288A1 (en) 2017-07-06
EP3388946A4 (en) 2018-12-26
KR20200111295A (en) 2020-09-28
CN105701025A (en) 2016-06-22
EP3388946A1 (en) 2018-10-17
US11023372B2 (en) 2021-06-01
CN105701025B (en) 2019-07-23

Similar Documents

Publication Publication Date Title
KR20180097674A (en) Memory reclaim method and apparatus
US6671802B1 (en) Performance optimization of computer system by dynamically and immediately updating a configuration setting based on detected change in preferred use
EP3506105B1 (en) Method and device for processing a memory and storage medium
CN102027453B (en) System and method for optimizing interrupt processing in virtualized environments
EP3508974A1 (en) Method and terminal for allocating system resource to application
CN105740078B (en) Memory management method, device and terminal
EP3495950A1 (en) Method and device for managing background applications of terminal
CN101794567A (en) Method and terminal for loading pictures
CN107807847B (en) Application process management method and terminal equipment
US11461179B2 (en) System recovery method and apparatus
CN114096953A (en) Memory management method and device, electronic equipment and computer readable medium
US10698837B2 (en) Memory processing method and device and storage medium
US20190243666A1 (en) Application startup control method and control device
US8499138B2 (en) Demand-based memory management of non-pagable data storage
CN115525631A (en) Database data migration method, device, equipment and storage medium
US20150127916A1 (en) Dynamic memory allocation
CN110955614B (en) Method and device for recovering file cache, storage medium and terminal
CN111444117B (en) Method and device for realizing fragmentation of storage space, storage medium and electronic equipment
CN112817835A (en) Performance data acquisition method and device, processor and electronic device
CN111475435A (en) Storage medium sharing method and device, electronic equipment and storage medium
EP4354293A1 (en) Detection method and apparatus, and electronic device
CN110032340A (en) A kind of data in magnetic disk management method and relevant apparatus
CN113032290A (en) Flash memory configuration method and device, electronic equipment and storage medium
CN108280113B (en) Service Worker control method and device and electronic terminal
CN110703943B (en) Electrostatic protection method and device for liquid crystal panel, electronic equipment and storage medium

Legal Events

Date Code Title Description
A201 Request for examination
AMND Amendment
E902 Notification of reason for refusal
AMND Amendment
E601 Decision to refuse application
X091 Application refused [patent]
E601 Decision to refuse application
E801 Decision on dismissal of amendment
A107 Divisional application of patent