Patent ID: 11907761
Assignee: SAMSUNG ELECTRONICS CO., LTD.
Field: Computer technology (Electrical engineering)
Classification: CPC G | IPC G

Claim 4:
5. An electronic apparatus comprising:
a storage;
a processor configured to execute a program including an operating system (OS) and an application program stored in the storage; and
a memory configured to load and store the program based on execution of the program,
wherein the processor is configured to control the OS to:
based on a user input, execute a process of the application program;
based on the execution of the process, perform an operation of creating a user stack corresponding to at least one task of the process and storing data of the created user stack in a predetermined area of the memory;
based on an event corresponding to the user input related to the process or a predetermined event related to the process being generated when the process is executed, stop change in the data of the user stack of the predetermined area;
discard an area in which data used in a procedure of initiating the process among the stored data of the user stack is stored, in the predetermined area, so that at least one of another process included in the application program or another application program uses the discarded area; and
based on a work corresponding to the event corresponding to the user input or the predetermined event being completed, continuously perform the operation,
wherein the user stack is created in units of tasks of the process based on the execution of the process, and the predetermined area of the memory is assigned to the created user stack, and
wherein the processor is further configured to control the OS to discard the area of the predetermined area of the memory, among areas of the memory assigned to user stacks corresponding to tasks of the process, during operation of the processor in a kernel mode.