Multi-core electronic device and group processing method thereof

By identifying the locations of driver cores, network cores, and application cores and processing packets in a distributed manner, the latency and throughput issues of packet processing in multi-core processors are resolved, achieving higher processing efficiency and throughput.

CN113632065BActive Publication Date: 2025-09-26SAMSUNG ELECTRONICS CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202080022621.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2019-03-22
Filing Date
2020-03-20
Publication Date
2025-09-26
Estimated Expiration
2040-03-20

AI Technical Summary

Technical Problem

Existing multi-core processors have problems with latency and throughput optimization in packet processing, especially in receive flow steering technology, where packets are concentrated in a single session, resulting in load imbalance and inability to fully utilize multi-core performance.

Method used

By identifying the location and performance of driver cores, network cores, and application cores, packets are processed in a distributed manner, and the location of network processing cores is determined to optimize batch processing and reduce unnecessary overhead.

Benefits of technology

Improved batch processing performance and efficiency for multi-core electronic devices, ensuring higher processing power and throughput.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113632065B_ABST
    Figure CN113632065B_ABST
Patent Text Reader

Abstract

A multi-core electronic device is provided. The multi-core electronic device includes a multi-core and a memory, wherein the multi-core includes a plurality of cores, each core being configured to process packets in a driver core layer, a network processing core layer, and an application core layer. The memory is configured to store execution instructions for causing a first core of the plurality of cores to, upon receiving a packet, identify the location of a driver core for delivering the packet to an operating system domain, the location of an application core for processing the packet in a user domain, and a processing volume; determine the location of a network processing core for processing the packet based on at least one of the location of the driver core, the location of the application core, and the processing volume of a session; and control the network processing core to perform network stack processing on the packet.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to a multi-core electronic device and a group processing method thereof. Background Art

[0002] 5G is the fifth-generation technology standard for low-latency and high-throughput communications. The communication systems used to provide 5G network services use highly complex hardware and software technologies to achieve high data rates.

[0003] For example, in order for an electronic device to support 5G network services, it is necessary to use multiple processors (e.g., multi-core processors) in terms of hardware, and it is necessary to use a technology for processing received packets simultaneously and in parallel on multiple cores in terms of software. The importance of software-based multi-core packet distribution processing technology lies in efficiently distributing received packets to cores. Examples of such packet distribution processing technologies may include receive packet steering (RPS) and receive flow steering (RFS) introduced in the Linux operating system (OS).

[0004] RPS is a technology for allowing network stack (e.g., Transmission Control Protocol / Internet Protocol (TCP / IP) layer) processing of packets by randomly assigning cores according to the packet's session. RFS is a technology for determining the core used for network stack processing of received packets by matching the application core used for the receiving session with the core used for network stack processing.

[0005] In addition, the electronic device may adopt a new application programming interface (API) (NAPI) technology to notify the kernel of the packet arrival status when the packet arrives at the network interface. NAPI is a technology for efficiently processing data in a batch manner when a predetermined number of packets are received and passing the batch of packets to an upper layer.

[0006] The above information is presented as background information only to assist in understanding the present disclosure. No determination has been made, and no assertion is made, as to whether any of the above content is applicable as prior art with respect to the present disclosure. Summary of the Invention

[0007] Technical issues

[0008] The receive packet steering (RPS) technology, which randomly selects a core for processing a packet without considering the state of the application and the core, may cause delays or fail to optimize the throughput of a multi-core processor. For example, if the capabilities of the driver task processing core and the network stack processing core do not meet the needs of the application, it is difficult to perform batch processing in the new application programming interface (API) (NAPI) and transmission control protocol (TCP) processing, which leads to low throughput and inefficient operation. In the case of the receive flow steering (RFS) technology, even when the packet is processed by the network core located at the same location as the application core, if the packet arrives in a single session or the packets are concentrated in a specific session, the load (or overhead) is imposed on the corresponding core, resulting in the inability to fully utilize the multi-core performance.

[0009] Various aspects of the present disclosure are to at least address the above-mentioned problems and / or disadvantages and to provide at least the advantages described below. Therefore, one aspect of the present disclosure is to provide a multi-core electronic device for batching packets in a distributed manner and processing the batched packets, and a core determination method and apparatus thereof, which can maximize the batch size of packets by considering the performance and interoperability of driver cores, network cores, and application cores, thereby reducing unnecessary overhead and ensuring higher performance.

[0010] Technical Solution

[0011] Additional aspects will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the presented embodiments.

[0012] According to one aspect of the present disclosure, a multi-core electronic device is provided. The multi-core electronic device includes a communication circuit, a multi-core, and a memory, wherein the multi-core includes a plurality of cores, wherein each core is configured to process packets in a driver core layer, a network processing core layer, and an application core layer, and the memory is configured to store instructions for a first core among the plurality of cores, the instructions being used to: when the communication circuit receives a packet, identify the location of a driver core for delivering the packet to an operating system domain, the location of an application core for processing the packet in a user domain, and the processing volume of a session corresponding to the packet, determine the location of a network processing core for processing the packet based on at least one of the location of the driver core, the location of the application core, and the processing volume of the session, and control the network processing core to perform network stack processing on the packet delivered to the operating system domain.

[0013] According to another aspect of the present disclosure, an electronic device is provided. The electronic device includes a communication circuit, a multi-core, a memory, and a processor, wherein the multi-core includes multiple cores, each core is configured to process packets in a driver core layer, a network processing core layer, and an application core layer, and the processor is configured to, when the communication circuit receives a packet, control the identification of the location of a driver core for delivering the packet from one of the multiple cores to an operating system domain, the location of an application core for processing the packet in a user, determine the location of a network processing core for processing the packet among the multiple cores based on at least one of the location of the driver core, the location of the application core, and the processing volume of a session, and control the use of the network processing core to perform network stack processing on the packet.

[0014] Beneficial effects of the present invention

[0015] According to various disclosed embodiments, the location of an application core for processing packets can be determined, and a network processing core for TCP / IP stack processing can be selected based on the location of a driver core and the location of an application core for processing received packets, as well as the packet processing volume per session. The proposed method is advantageous in improving batch processing performance and efficiency of multi-core electronic devices by using cores that exhibit capabilities in lower layers that are equal to or greater than those in higher layers.

[0016] Other aspects, advantages, and salient features of the disclosure will become apparent to those skilled in the art from the following detailed description, which, taken in conjunction with the annexed drawings, discloses various embodiments of the disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The above and other aspects, features and advantages of certain embodiments of the present disclosure will become more apparent from the following description taken in conjunction with the accompanying drawings, in which:

[0018] Figure 1 is a block diagram illustrating an electronic device in a network environment according to an embodiment of the present disclosure;

[0019] Figure 2 is a block diagram illustrating a configuration of a multi-core electronic device according to an embodiment of the present disclosure;

[0020] Figure 3a and Figure 3b is a diagram of network packet processing operations according to various embodiments of the present disclosure;

[0021] Figure 4 is a diagram of a network packet processing host according to an embodiment of the present disclosure;

[0022] Figure 5 is a diagram illustrating a packet processing operation of an electronic device according to an embodiment of the present disclosure;

[0023] Figure 6 is a diagram illustrating a packet processing operation of an electronic device according to an embodiment of the present disclosure;

[0024] Figure 7 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure;

[0025] Figure 8 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure;

[0026] Figure 9 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure;

[0027] Figure 10 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure;

[0028] Figure 11 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure;

[0029] Figure 12 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure; and

[0030] Figure 13a 、 Figure 13b and Figure 13c is a graph for illustrating effects according to various embodiments of the present disclosure.

[0031] Throughout the drawings, it should be noted that like reference numbers are used to depict the same or similar elements, features, and structures. DETAILED DESCRIPTION

[0032] The following description, with reference to the accompanying drawings, is provided to assist in a comprehensive understanding of the various embodiments of the present disclosure as defined by the claims and their equivalents. The description includes various specific details to assist in understanding, but these details are to be considered as exemplary only. Therefore, those skilled in the art will recognize that various changes and modifications may be made to the various embodiments described herein without departing from the scope and spirit of the present disclosure. In addition, descriptions of well-known functions and structures may be omitted for clarity and conciseness.

[0033] The terms and words used in the following description and claims are not limited to the bibliographical meanings, but are merely used by the inventor to enable a clear and consistent understanding of the present disclosure. Therefore, it will be apparent to those skilled in the art that the following description of various embodiments of the present disclosure is provided for illustration purposes only and not for the purpose of limiting the present disclosure as defined by the appended claims and their equivalents.

[0034] It should be understood that the singular forms "a," "an," and "the" include plural referents unless the context clearly dictates otherwise. Thus, for example, reference to "a component surface" includes reference to one or more of such surfaces.

[0035] Figure 1 is a block diagram illustrating an electronic device 101 in a network environment 100 according to various embodiments.

[0036] Reference Figure 1 , the electronic device 101 in the network environment 100 can communicate with the electronic device 102 via the first network 198 (e.g., a short-range wireless communication network), or communicate with the electronic device 104 or the server 108 via the second network 199 (e.g., a long-range wireless communication network). According to an embodiment, the electronic device 101 can communicate with the electronic device 104 via the server 108. According to an embodiment, the electronic device 101 may include a processor 120, a memory 130, an input device 150, a sound output device 155, a display device 160, an audio module 170, a sensor module 176, an interface 177, a haptic module 179, a camera module 180, a power management module 188, a battery 189, a communication module 190, a subscriber identification module (SIM) 196, or an antenna module 197. In some embodiments, at least one of the components (e.g., the display device 160 or the camera module 180) may be omitted from the electronic device 101, or one or more other components may be added to the electronic device 101. In some embodiments, some of the components may be implemented as a single integrated circuit. For example, the sensor module 176 (eg, a fingerprint sensor, an iris sensor, or an illumination sensor) may be implemented as embedded in the display device 160 (eg, a display).

[0037] The processor 120 may run, for example, software (e.g., program 140) to control at least one other component of the electronic device 101 connected to the processor 120 (e.g., a hardware component or a software component), and may perform various data processing or calculations. According to one embodiment, as at least part of the data processing or calculation, the processor 120 may load commands or data received from another component (e.g., sensor module 176 or communication module 190) into the volatile memory 132, process the commands or data stored in the volatile memory 132, and store the resulting data in the non-volatile memory 134. Depending on the embodiment, the processor 120 may include a main processor 121 (e.g., a central processing unit (CPU) or an application processor (AP)) and an auxiliary processor 123 (e.g., a graphics processing unit (GPU), an image signal processor (ISP), a sensor hub processor, or a communication processor (CP)) that is operationally independent of or combined with the main processor 121. Additionally or alternatively, the auxiliary processor 123 may be adapted to consume less power than the main processor 121, or adapted to be specifically used for a designated function. The auxiliary processor 123 may be implemented separately from the main processor 121 or as part of the main processor 121 .

[0038] When the main processor 121 is in an inactive (e.g., sleep) state, the auxiliary processor 123 may control at least some of the functions or states related to at least one component (e.g., the display device 160, the sensor module 176, or the communication module 190) among the components of the electronic device 101 (not the main processor 121), or when the main processor 121 is in an active state (e.g., running an application), the auxiliary processor 123 may control at least some of the functions or states related to at least one component (e.g., the display device 160, the sensor module 176, or the communication module 190) together with the main processor 121. Depending on the embodiment, the auxiliary processor 123 (e.g., an image signal processor or a communication processor) may be implemented as part of another component (e.g., the camera module 180 or the communication module 190) that is functionally related to the auxiliary processor 123.

[0039] The memory 130 may store various data used by at least one component of the electronic device 101 (e.g., the processor 120 or the sensor module 176). The various data may include, for example, software (e.g., the program 140) and input data or output data for commands related thereto. The memory 130 may include a volatile memory 132 or a non-volatile memory 134.

[0040] The program 140 may be stored as software in the memory 130 , and may include, for example, an operating system (OS) 142 , middleware 144 , or applications 146 .

[0041] The input device 150 may receive commands or data to be used by other components of the electronic device 101 (eg, the processor 120) from outside the electronic device 101 (eg, a user). The input device 150 may include, for example, a microphone, a mouse, or a keyboard.

[0042] The sound output device 155 can output sound signals to the outside of the electronic device 101. The sound output device 155 may include, for example, a speaker or a receiver. The speaker can be used for general purposes such as playing multimedia or records, and the receiver can be used for incoming calls. Depending on the embodiment, the receiver can be implemented separately from the speaker or as part of the speaker.

[0043] The display device 160 can visually provide information to the outside of the electronic device 101 (e.g., a user). The display device 160 may include, for example, a display, a holographic device, or a projector, and a control circuit for controlling a corresponding one of the display, the holographic device, and the projector. Depending on the embodiment, the display device 160 may include a touch circuit adapted to detect a touch or a sensor circuit adapted to measure the strength of the force caused by the touch (e.g., a pressure sensor).

[0044] The audio module 170 can convert sound into an electrical signal, and vice versa. According to an embodiment, the audio module 170 can obtain sound via the input device 150, or output sound via the sound output device 155 or an earphone of an external electronic device (e.g., electronic device 102) directly (e.g., wired) or wirelessly connected to the electronic device 101.

[0045] The sensor module 176 can detect an operating state (e.g., power or temperature) of the electronic device 101 or an environmental state (e.g., a user's state) outside the electronic device 101, and then generate an electrical signal or data value corresponding to the detected state. Depending on the embodiment, the sensor module 176 may include, for example, a gesture sensor, a gyro sensor, an atmospheric pressure sensor, a magnetic sensor, an acceleration sensor, a grip sensor, a proximity sensor, a color sensor, an infrared (IR) sensor, a biometric sensor, a temperature sensor, a humidity sensor, or an illumination sensor.

[0046] The interface 177 may support one or more specific protocols to be used to connect the electronic device 101 directly (e.g., wired) or wirelessly to an external electronic device (e.g., the electronic device 102). Depending on the embodiment, the interface 177 may include, for example, a High-Definition Multimedia Interface (HDMI), a Universal Serial Bus (USB) interface, a Secure Digital (SD) card interface, or an audio interface.

[0047] The connection end 178 may include a connector, wherein the electronic device 101 can be physically connected to an external electronic device (e.g., the electronic device 102) via the connector. Depending on the embodiment, the connection end 178 may include, for example, an HDMI connector, a USB connector, an SD card connector, or an audio connector (e.g., a headphone connector).

[0048] The haptic module 179 may convert the electrical signal into mechanical stimulation (eg, vibration or motion) or electrical stimulation that can be recognized by the user via his sense of touch or kinesthetic sense. According to an embodiment, the haptic module 179 may include, for example, a motor, a piezoelectric element, or an electrical stimulator.

[0049] The camera module 180 may capture still images or moving images. Depending on the embodiment, the camera module 180 may include one or more lenses, image sensors, image signal processors, or flashes.

[0050] The power management module 188 may manage power supply to the electronic device 101. According to an embodiment, the power management module 188 may be implemented as, for example, at least a part of a power management integrated circuit (PMIC).

[0051] The battery 189 may power at least one component of the electronic device 101. According to an embodiment, the battery 189 may include, for example, a non-rechargeable primary battery, a rechargeable secondary battery, or a fuel cell.

[0052] The communication module 190 may support establishing a direct (e.g., wired) communication channel or a wireless communication channel between the electronic device 101 and an external electronic device (e.g., electronic device 102, electronic device 104, or server 108), and perform communication via the established communication channel. The communication module 190 may include one or more communication processors capable of operating independently from the processor 120 (e.g., an application processor (AP)) and supporting direct (e.g., wired) communication or wireless communication. Depending on the embodiment, the communication module 190 may include a wireless communication module 192 (e.g., a cellular communication module, a short-range wireless communication module, or a global navigation satellite system (GNSS) communication module) or a wired communication module 194 (e.g., a local area network (LAN) communication module or a power line communication (PLC) module). A corresponding one of these communication modules can communicate with an external electronic device via a first network 198 (e.g., a short-range communication network such as Bluetooth, Wireless Fidelity (Wi-Fi) Direct, or Infrared Data Association (IrDA)) or a second network 199 (e.g., a long-range communication network such as a cellular network, the Internet, or a computer network (e.g., a LAN or a wide area network (WAN))). These various types of communication modules can be implemented as a single component (e.g., a single chip), or these various types of communication modules can be implemented as multiple components separated from each other (e.g., multiple chips). The wireless communication module 192 can identify and authenticate the electronic device 101 in a communication network (such as the first network 198 or the second network 199) using user information (e.g., an International Mobile Subscriber Identity (IMSI)) stored in the user identification module 196.

[0053] The antenna module 197 can transmit or receive signals or power to or from the outside of the electronic device 101 (e.g., an external electronic device). Depending on the embodiment, the antenna module 197 may include one or more antennas, and thus, for example, the communication module 190 (e.g., the wireless communication module 192) may select at least one antenna suitable for a communication scheme used in a communication network (such as the first network 198 or the second network 199). Signals or power can then be transmitted or received between the communication module 190 and the external electronic device via the selected at least one antenna.

[0054] At least some of the above components can be connected to each other via an inter-peripheral communication scheme (e.g., a bus, general-purpose input output (GPIO), serial peripheral interface (SPI), or mobile industry processor interface (MIPI)) and communicatively transmit signals (e.g., commands or data) therebetween.

[0055] According to various embodiments, the processor 120 of the electronic device 101 may include N cores. The N cores may include high-performance cores (e.g., large cores) that consume more power and have more processing capabilities, and low-performance cores (e.g., small cores) that consume less power and have less processing capabilities.

[0056] According to various embodiments, in the network environment 100, the electronic device 101 may receive packets from the network and process the received packets using multiple cores in a distributed manner. For example, the cores may be hierarchically organized to process packets at their own layers: a driver core for passing received packets to upper layers, a network processing core for network stack processing, and an application core for application processing in the user domain.

[0057] A multi-core electronic device 101 and a method for determining a location of a network processing core for network stack processing in consideration of a location of a driver core and locations of application cores in the electronic device 101 are described.

[0058] Figure 2 is a block diagram illustrating a configuration of a multi-core electronic device according to an embodiment of the present disclosure.

[0059] Reference Figure 2 , a multi-core electronic device 201 (eg, Figure 1 The electronic device 101 in FIG. 1 may include a multi-core 210 (eg, Figure 1 120), network driver 220, core management controller 230, and memory 240 (e.g., Figure 1 Memory 130 in).

[0060] According to an embodiment, multi-core 210 may be a processor including at least N cores 211, 212, 213, and 214. This description relates to, but is not limited to, a case where multi-core 210 includes first-type cores (e.g., high-performance cores, high-power cores, and large cores) and second-type cores (e.g., low-performance cores, low-power cores, and small cores). The number of first-type cores and second-type cores may be determined according to the specifications of the electronic device.

[0061] According to an embodiment, the N cores included in the multi-core 210 can be represented by core numbers (e.g., core 0, core 1, core 2, core 4, and core N). The cores included in the multi-core 210 can be classified into one of the first cluster and the second cluster according to their performance. The electronic device 201 can classify the core into one of the clusters according to the core number. For example, assuming 8 cores, cores 4 to 7 fall into the first cluster, and cores 0 to 3 fall into the second cluster. The electronic device 201 can identify whether the core belongs to the first cluster or the second cluster based on the core number.

[0062] According to an embodiment, the network driver 220 may include a network interface card (NIC) (not shown). The network driver 220 may be implemented as a software component for performing network communication with another device. According to an embodiment, the network driver 220 may be connected to a modem (e.g., a local area network (LAN) card) of a communication processor via a peripheral component interconnect (PCI) express interface. According to various embodiments, the NIC may include, but is not limited to, a LAN card. The electronic device 201 may be connected to the network via a wireless connection or a wired connection. The electronic device 101 may connect to the network using a media access control (MAC) address of the NIC or modem.

[0063] According to an embodiment, the network driver 220 (e.g., NIC) may include a receive (Rx) buffer (not shown) for queuing received packets and a transmit (Tx) buffer (not shown) for queuing packets processed by an application in a user domain for transmission.

[0064] According to an embodiment, the network driver 220 may receive a packet through network communication with another electronic device. According to an embodiment, the network driver 220 may be installed in the core and receive an interrupt signal for the incoming packet from the NIC (or a communication processor including a modem). The core may include an OS (e.g., Figure 1 For example, a core may receive multiple packets and may pass the multiple packets to different layer cores.

[0065] According to an embodiment, the core management controller 230 may be driven by at least one core among the plurality of cores of the multi-core 210, or as a Figure 1 Part of the processor 120 in.

[0066] According to an embodiment, the core management controller may be a hardware component configured to operate independently of the multi-core 210 .

[0067] According to another embodiment, the core management controller 230 may be a software program (e.g., Figure 1 For example, the core management controller 230 as a software component may be stored in the memory 240 in the form of commands (or instructions) that can be executed by the processor 120.

[0068] According to an embodiment, the core management controller 230 may detect execution of an application, allocate one core among a plurality of cores to the application, and control the multi-core 210 .

[0069] According to an embodiment, the core management controller 230 may monitor information about sessions of packets being transmitted via network communication to determine the location (i.e., identification) of the core used to process the packets. For example, the location of the core may include core number or cluster type information. According to an embodiment, the core management controller 230 may obtain at least one of the session ID of the packet, the identifier (e.g., number) of the driver core that passes the packet to the concurrent processing engine, the identifier of the application core (e.g., the application used to process the packet) associated with the session ID, and / or processing information for each session. For example, the concurrent processing engine may be a core that is running on an OS (e.g., Figure 1 A software component running on the OS 142 in the core) and is understood to be an engine for identifying packets received from the network using session IDs and processing the packets on the cores in a distributed manner.

[0070] According to an embodiment, the core management controller 230 may determine an identifier (eg, number) of a network processing core for performing network stack (eg, TCP / IP stack) processing on a packet based on information received from the concurrent processing engine.

[0071] According to an embodiment, the core management controller 230 may determine a cluster type of a network processing core for performing network stack (eg, TCP / IP stack) processing on a packet based on information received from a concurrent processing engine.

[0072] According to an embodiment, the core management controller 230 may monitor the location of an application core for processing data in a user domain to detect a change in the location of the application core, and change the location of the network processing core based on the change in the location of the application core.

[0073] According to an embodiment, the core management controller 230 may monitor the operating state of an application to determine the location of an application core and, if necessary, control the change of the location of the application core. For example, the location of the application core may include information indicating the core number or cluster type. For example, if a change is required from a high-performance core to a low-performance core in the application layer, the core management controller 230 may select one of the cores in the low-power cluster and designate the selected low-power core as the application core.

[0074] According to an embodiment, the core management controller 230 may check the operating time of the core processing the application and the number of packets being processed by the core based on the session ID, and if the operating time of a particular core is greater than a threshold, determine the location of the application core based on the core cluster to which the core processing the application belongs. For example, if the application core processing packets related to the audio playback application belongs to a high-performance cluster, the location of the application core corresponding to the audio playback application may be determined as a high-performance core.

[0075] According to an embodiment, the core management controller 230 may determine the location of the application core based on whether the application is running in the foreground or in the background.

[0076] According to an embodiment, the core management controller 230 may pre-specify core locations for a specific application, or specify the locations of application cores through machine learning.

[0077] According to an embodiment, the core management controller 230 may check the packet processing level (eg, low, medium, and high) to determine the network processing core for the relevant session.

[0078] According to an embodiment, the core management controller 230 may change the threshold value based on at least one of the location of the application core, the location of the driver core for delivering packets to the concurrent processing engine, and characteristic information of the application, and determine the network processing core by comparing the threshold value with the threshold value. The packet processing amount of the application may be the amount of packet data processed in units of time, and is expressed in units of bytes per second (BPS), bits per second (BPS), or packets per second (PPS).

[0079] According to an embodiment, the core management controller 230 may change a threshold value regarding a packet processing amount of an application according to a location of a main core executing the application.

[0080] According to an embodiment, the core management controller 230 may change a threshold value regarding the packet processing amount of an application according to whether the application is running in the foreground or in the background.

[0081] According to an embodiment, the core management controller 230 may change a threshold value regarding a packet processing amount of an application according to a location of an application core based on predetermined information or learned information.

[0082] Depending on the embodiment, the memory 240 may include at least one of the following: dynamic random access memory (DRAM), static random access memory (SRAM), synchronous dynamic random access memory (SDRAM), double data rate 2 (DDR2) RAM, Rambus dynamic random access memory (RDRAM), or other types of memory.

[0083] According to an embodiment, the memory 240 may temporarily store software (eg, programs ( Figure 1 and concurrent processing engines) and input and output data of instructions associated with the software.

[0084] According to an embodiment, the program may include an OS, middleware, and applications for controlling resources of the electronic device 201. The OS may control the management (e.g., allocation and deallocation) of one or more system resources (e.g., processes, memory, and power). The middleware may provide various functions so that the application uses functions and information provided in association with one or more system resources of the electronic device 201.

[0085] Figure 3a and Figure 3b is a diagram of network packet processing operations according to various embodiments of the present disclosure, and Figure 4 is a diagram of a network packet processing host according to an embodiment of the present disclosure. Figure 3a and Figure 3b The electronic device depicted in FIG. 1 may illustrate a configuration of a device for receiving a packet and processing the received packet.

[0086] Reference Figure 4 , electronic devices (e.g., Figure 2 The electronic device 201 in the embodiment includes a multi-core 410 (e.g., Figure 2 210 in the multi-core 210), and can be connected via the network driver 320 (e.g., Figure 2 The network driver 220 in receives packets and processes the received packets in the hardware domain, OS domain and user domain.

[0087] Reference Figure 3a , the electronic device may include a NIC 315 arranged in a hardware domain, a network driver 320 arranged in an OS domain, a concurrent processing engine 340, a core management controller 330 (eg, Figure 2 The kernel management controller 230 in the UEFI core management system 200 and the TCP / IP stack 350, and the application 360 arranged in the user domain. Here, the terms "OS domain" and "kernel domain" are used with the same or similar meanings.

[0088] Reference Figure 3b , the electronic device may include a NIC 315 and a concurrent processing engine A341 arranged in a hardware domain, a network driver 320, a concurrent processing engine 340, a core management controller 330 and a TCP / IP stack 350 arranged in an OS area, and an application 360 arranged in a user domain.

[0089] Reference Figure 3b , the concurrent processing engine can be implemented as a hardware component using multiple memories. Figure 3b In the embodiment of the present invention, the concurrent processing engine A341 queues the packets received by the NIC 315 to an internal memory buffer (e.g., a queue) and activates a memory buffer dedicated core (i.e., a first core, a second core, etc.). The activated core can control the operation of the network driver and operate the concurrent processing engine 340. Figure 3b In the embodiment of FIG. 3 , it is understood that there are multiple cores operating the network driver 320. In the following description, it is assumed that the NIC 315, the network driver 320, the concurrent processing engine 340, the core management controller 330, and the TCP / IP stack 350 are in the same manner as in the reference numerals 340 and 340. Figure 3a The electronic device may process the received packet in the OS domain (e.g., decapsulate) and provide a service to the user as a result of processing the packet in the OS domain. The packet received via the network driver may be processed in sequence by the NIC, the network driver 320, the TCP / IP stack 350, and the application 360. The received packet may be processed by a core identified by a different number in each layer.

[0090] According to an embodiment, packets received via a network driver may be processed by the driver core A, the network processing core B, and the application core C as follows: Figure 4 However, for ease of explanation, the cores are disclosed as software, but they can be implemented as hardware components (e.g., core 1, core 2, core 3...) operating in each layer. The operation of the host and the cores for processing packets in each layer will be described later.

[0091] According to an embodiment, the network driver 320 may receive network packets via the NIC and may pass the received packets to the concurrent processing engine 340 .

[0092] According to an embodiment, the network driver 320 may immediately pass the received packets to the concurrent processing engine 340 .

[0093] According to an embodiment, the concurrent processing engine 340 may generate a session ID for packets received from the network driver 320 for use in identifying packets by session. The concurrent processing engine 340 may generate a session ID based on IP address information (e.g., sender IP address and receiver IP address) and port information (e.g., sender port and receiver port) for use in identifying the packet session. The concurrent processing engine 340 may send the session ID of the received packet and the number of the driver core A that has delivered the packet to the concurrent processing engine 340 to the core management controller 330.

[0094] According to an embodiment, the concurrent processing engine 340 may receive location information of the location of the core responsible for the packet session among the cores in the multi-core 410 of the electronic device from the core management controller 330. The location information of the core may be a core number or core cluster information. For example, the core responsible for the session may be a core for TCP / IP stack processing, for example, Figure 4 The network processing core B in .

[0095] According to an embodiment, the concurrent processing engine 340 may activate a network processing core corresponding to the determined location and transmit the packet received from the network driver 320 to the TCP / IP stack 350 .

[0096] According to an embodiment, the TCP / IP stack 350 may perform network layer (e.g., IP layer) and transport layer (e.g., TCP layer and User Datagram Protocol (UDP) layer) processing on the packet. For example, the TCP / IP stack 350 may perform IP and TCP processing on the received packet and send the TCP-processed packet to the user buffer 447 or the application core C.

[0097] According to an embodiment, the core management controller 330 may include a manager 331 and a database (DB) 332 .

[0098] The core management controller 330 can monitor the packet processing status and the operating status of the application in the OS domain based on the manager 331 and the DB 332, and determine the location of the network processing core B and / or the application core C for processing the packet based on the session ID of the packet received from the concurrent processing engine 340 and the core determination policy. For example, the core management controller 330 can determine the identifiers of the network processing core B and / or the application core C or the type of cluster to which the application core C belongs.

[0099] According to an embodiment, the manager 331 of the core management controller 330 may receive the session ID of the received packet from the concurrent processing engine 340. The manager 331 may monitor information related to the corresponding session ID. For example, the manager 331 may monitor the session packet throughput for each application, the location where the network driver 320 has delivered the packet of the corresponding session to the driver core A of the concurrent processing engine 340, and the location where the packet of the corresponding session is delivered from the TCP / IP stack 350 to the application core C of the application 360. For example, the manager 331 may check the number or cluster information of the application core C of the application 360 that delivers the packet of the corresponding session from the agent (not shown) included in the TCP / IP stack 350.

[0100] According to an embodiment, the manager 331 may store the monitored information (eg, packet processing amount and core location) in the DB 332 .

[0101] According to an embodiment, the manager 331 may determine the location of the network processing core B (and / or application processing core C) for processing packets of the corresponding session based on the monitored information, the location of the application core C, the location of the driver core A, and the packet processing volume of the corresponding session.

[0102] According to an embodiment, the manager 331 may determine the location of the network processing core B and / or the application core C. For example, the concurrent processing engine 340 may select one of the cores belonging to the high-performance cluster based on the location information received from the manager 331, and assign the selected core as the network processing core B, wherein the location information indicates the high-performance cluster.

[0103] According to an embodiment, the DB 332 may store information about sessions monitored by the manager 331, predefined core determination policy information, session information, core information, and application information. For example, for convenience of explanation, the DB 332 may be implemented in a table form, but is not limited thereto.

[0104] Table 1 is a table storing core information. The core information may include a cluster type corresponding to each core number and core maximum clock information. The manager 331 may check the core information about the location (ie, cluster type) of the corresponding core.

[0105] Table 1

[0106] Nuclear number Cluster Type Maximum clock 0 Small 1.7GHz 1 Small 1.7GHz ... ... ... 8 big 2.7GHz

[0107] Table 2 stores session information for each application. The session information may include the throughput, Rx data size, driver core number or identifier, Rx data size, application core number or identifier, application identification (ID) information, and threshold throughput range information for the session identified by the session ID. The throughput of a session represents the number of packets processed during a predetermined period. For example, if 10 megabytes (MB) of packets are processed per second during a session, the session throughput may be 10 MBps.

[0108] According to an embodiment, the session information may include a driver core A number, an application core B number, and a network processing core C number corresponding to a combination of an application core C number and a threshold throughput range of the core.

[0109] Table 2

[0110] Session ID Driver Core Application Core Rx data size Processing capacity Network processing core App ID 0 0 3 10Mb 10Mbps 2 1 1 0 5 150Mb 150Mbps 7 2 ... ... ... ... ... ... ... N [0,M] [0,M] Number Number [0,M] K

[0111] Table 3 is a table storing operation flag values ​​corresponding to predetermined application IDs. The flag value may be information indicating a predetermined application.

[0112] Table 3

[0113] App ID Logo 0 0 1 1 ... ... K serial number

[0114] Table 4 shows a core determination policy. Manager 331 can determine the location of network processing core B based on the location of driver core A, the location of application core C, and session processing volume information. For example, if driver core A is a low-performance type, application core C is a high-performance type, and packet processing volume is high, manager 331 can determine that network stack processing core B is a high-performance type. Manager 331 can also determine the location of network processing core B so that a core with a predetermined number or a randomly selected core from the high-performance type cores performs network stack processing.

[0115] Table 4

[0116]

[0117] Hereinafter, the operation of the host and the core processing the packet in the OS domain will be described. Figure 4 , multi-core 410 may include, but is not limited to, core 1 411, core 2 412, core 3 413, and core 4 414. The cores included in multi-core 410 may be classified into one of a low-performance cluster and a high-performance cluster according to their performance. For example, core 1 411 and core 2 412 may belong to the low-performance cluster and be characterized by low power consumption and low processing power, whereas core 3 413 and core 4 414 may belong to the high-performance cluster and be characterized by high power consumption and high processing power.

[0118] Driver core A may pass packets from network driver 320 to concurrent processing engine 340. For example, driver core A may queue the packets passed to network driver 320 in engine buffer 442 of concurrent processing engine 340. Driver core A may control parallel processing engine 340.

[0119] According to an embodiment, the concurrent processing engine 340 may determine one of the cores of the multi-core 410 as the network processing core B based on the core allocation information received from the core management controller 330. The concurrent processing engine 340 may activate the core identified by the number of the determined network processing core B and queue the packet in the engine buffer 442 corresponding to the determined network processing core B.

[0120] The network processing core B may process packets in the TCP / IP stack 350. The application core C may process TCP-processed packets in the TCP buffer in the user domain.

[0121] According to an embodiment, packets received via the network driver 320 may be processed sequentially by driver core A, network processing core B, and application core C. Packets may be processed by cores identified by different numbers in each layer. For example, during packet processing, core 0 may be designated as driver core A, and core 3 may be designated as network core B.

[0122] Buffers for processing packets may be allocated to the cores A, B, and C of each layer. For example, a driver buffer 441 may be allocated to the driver core A for queuing packets and passing the packets to the concurrent processing engine 340. An engine buffer 442 may be allocated to the concurrent processing engine 340 for temporarily queuing packets to be passed to the network processing core B. A TCP buffer 443 for TCP / IP processing may be allocated to the network processing core B. The TCP buffer 443 may be allocated per session, but is not limited thereto. A user buffer 447 for data processing of an application may be allocated to the application core C. Although for ease of explanation, Figure 4 A single buffer per layer is depicted, but multiple buffers may exist per layer. Each buffer may be implemented in the form of a stacked memory or queue, but is not limited thereto. Each buffer may be a buffer of the electronic device 201 (e.g., Figure 1 1) of the electronic device 101 (e.g., Figure 1 A portion of the memory 130 in .

[0123] According to an embodiment, the network driver 320 may send packets received from the NIC to the engine buffer 442 of the concurrent processing engine 340 under the control of any driver core A.

[0124] For example, if a packet arrives at a network driver, a core with a particular number (eg, core 1 411 ) is activated as driver core A, which controls the operation of the concurrent processing engine 340 and queues the received packet in the engine buffer 442 of the concurrent processing engine 340 .

[0125] The concurrent processing engine 340 may generate a session ID of the packet and transmit the session ID information and location information from the driver core A that received the packet to the core management controller 330 .

[0126] The core management controller 330 may determine the location of the application core C for processing the application 360 in the user domain in association with the session ID of the received packet, and provide the location information of the application core C to the concurrent processing engine 340. For example, the core management controller 330 may determine the location of the network processing core B for TCP / IP stack processing based on the location of the application core C, the location of the driver core A, and the session packet processing volume.

[0127] The concurrent processing engine 340 may activate the network processing core B corresponding to the location determined based on the location information received from the core management controller 330. The concurrent processing engine 340 may reflect the changed location information of the application core C based on the location information received from the core management controller 330, and allocate the network processing core B so that a core having a capability equal to or higher than that of the application core C processes the packet.

[0128] Network processing core B may perform TCP stack processing on packets queued in TCP buffer 443. For example, if core 3 413 is activated by concurrent processing engine 340, network processing core B indexed by core 3 sends packets queued in engine buffer 442 to TCP buffer 443 and performs TCP / IP stack processing on the packets queued in TCP buffer 443.

[0129] The application core C may process the packet subjected to TCP / IP processing by the network processing core B based on the session ID of the packet.

[0130] According to an embodiment, the TCP buffer 443 may be allocated to at least one area. For example, the TCP buffer 443 may be included in an Rx queue area 444 and a backlog area 445. The Rx queue area 444 is used to queue packets to be delivered to or read by an application (i.e., packets processed by TCP), and the backlog area 445 is used to deliver packets to be processed by the TCP / IP stack. The Rx queue area 444 may store packets processed by the network processing core B through TCP / IP.

[0131] According to an embodiment, the network processing core B may queue packets in the backlog area 445 for TCP / IP stack processing while the application 360 outputs packets from the Rx queue area 444 to the user domain.

[0132] According to an embodiment, the application associated with the session ID of the packet may batch process all packets queued in the backlog area 445 while the application core C processes all TCP-processed packets queued in the Rx queue area 444 .

[0133] According to various embodiments, the proposed electronic device is capable of improving multi-core performance by determining to allow cores with capabilities equal to or greater than those operating in higher layers to operate in lower layers to optimally batch packets processed in lower layers and passing the optimally batched packets to higher layers.

[0134] Figure 5 is a diagram illustrating a packet processing operation according to an embodiment of the present disclosure.

[0135] In the prior art technology based on receive packet steering (RPS), if a packet is received from a network driver, a network processing core is arbitrarily selected from a plurality of cores to perform TCP / IP processing without any priority order. In the technology based on receive flow steering (RFS), a network processing core with a core number (core N) on which the application 590 is running is selected to perform TCP / IP processing. According to the prior art, a network processing core is selected without considering the processing power of the core and the location of the core executing the application, which causes a performance difference between the application core and the driver core, resulting in an inability to fully utilize the multi-core processing performance. In addition, if the packets are concentrated in a specific session, this may overload the core, resulting in a decrease in packet processing performance.

[0136] Reference Figure 5 , including multi-core (e.g., Figure 2 Multi-core 210 and Figure 4 An electronic device (e.g., a multi-core 410) Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in FIG. 20 can determine the location of an application core based on the session ID of the packet, and determine the location (e.g., number or cluster type) of a network processing core for TCP / IP stack processing based on the location of the driver core and the packet processing volume of the session. According to various embodiments, the network processing core determined by considering the performance of lower-layer and higher-layer cores performs network stack processing on the packet, which improves the performance of multi-core-based batch processing.

[0137] According to an embodiment, if packet 510 arrives at the network driver, the driver core of core 1 may be activated. The application associated with the packet may process the packet processed by the TCP / IP stack of the application core of core N. The driver core of core 1 may send the packet to a concurrent processing engine (e.g., Figure 3a and 3b ), as indicated by reference numeral 520. The concurrent processing engine may then allocate a network processing core for executing TCP / IP stack processing to core 2 based on the location information received from the core management controller. The location of the network processing core may be determined in consideration of the location of the application core (core 2), the location of the driver core (core 1), and the processing volume of the packet session.

[0138] If the driver core of core 1 activates the network processing core of core 2, the concurrent processing engine can send packets to the TCP buffer (e.g., Figure 4 The network processing core may perform TCP / IP stack processing on the packets queued in the TCP buffer. The application may output packets that are processed by the application core of core N through the TCP / IP stack.

[0139] According to an embodiment, the location of the application can be moved from core N to core 2 according to the operating state of the electronic device. For example, the location 590 of the application core executing the application in the user domain can be dynamically changed according to the application execution location (e.g., foreground and background) and the core load value.

[0140] If the application core's position changes from position 590 to position 591, the concurrent processing engine may change the position of the network processing core from core 2 position 550 to core 3 position 551. The concurrent processing engine may send the packet at position 531 to the TCP buffer in core 3. The network processing core of core 3 may perform TCP / IP stack processing on the packet. The application core of core 2 may process the packet processed by the network processing core of core 3.

[0141] According to an embodiment, an electronic device including multiple cores may determine a network stack processing core in consideration of a location of an application core or a location of a driver core.

[0142] Figure 6 is a diagram illustrating a packet processing operation of an electronic device according to an embodiment of the present disclosure.

[0143] Reference Figure 6 , including multi-core (e.g., Figure 2 Multi-core 210 and Figure 4 An electronic device (e.g., a multi-core 410) Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in FIG. 2 may determine the number (or cluster type) of the application core and the number (or cluster type) of the network processing core used for TCP / IP stack processing to change the position of the application core used to process packets.

[0144] For example, considering the location of the application core, the location of the driver core, and the processing volume of each session, the electronic device may determine the location 650 of core 3 as the network processing core for TCP / IP stack processing. The driver core may control the concurrent processing engine to queue packets in the TCP buffer. The network processing core of core 3 may process packets in the TCP buffer (e.g., Figure 4 TCP / IP stack processing is performed on packets queued in the TCP buffer 443 in .

[0145] For example, an application core that reads and processes packets processed by the TCP / IP stack may move its location from core N location 690 to core 2 location 691. Figure 6, the application operating in the application core of core N may be an application predetermined by an application core number (e.g., cluster type). When the session processing volume of the received packet is equal to or greater than a predetermined level, the electronic device may change the position 690 of the application core. For example, if the session processing volume of the received packet reaches a medium or high level, the electronic device may change the position of the application core from core N position 690 to core 2 position 691 by reflecting the position of the predetermined core. If the session processing volume of the received packet is a low level, the electronic device may maintain the position 690 of the application core. In the case whether the position of the application core is changed from core N position 690 to core 2 position 691, the application core of core 2 may read and process the packets processed by the TCP / IP stack.

[0146] Figure 7 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure.

[0147] Reference Figure 7 , operations 710 to 770 may be performed by a processor including multiple cores (e.g., Figure 2 Multi-core 210 and Figure 4 An electronic device (e.g., a multi-core 410) Figure 1 The electronic device 101 and Figure 2 Executed by the electronic device 201).

[0148] According to an embodiment, in operation 710, the electronic device 101 may receive a signal from a NIC (eg, Figure 3a and Figure 3b The NIC 315 in receives at least one packet.

[0149] In operation 720 , the electronic device may activate a driver core A having an arbitrary number X among a plurality of cores of the multi-core based on the received packet.

[0150] According to an embodiment, a core may be activated under the control of a communication processor. A core may be a core having a predetermined default number or a randomly selected core. A core may be a core selected from among cores in sleep mode.

[0151] In operation 730, the driver core A with number X in the electronic device may execute the concurrent processing engine (eg, Figure 3a and 3b Concurrent processing engine 340, Figure 5 The concurrent processing engine 540 and Figure 6 The concurrent processing engine 640 in the engine buffer (e.g., Figure 4 The received packets are queued in the engine buffer 442 in .

[0152] According to an embodiment, the concurrent processing engine may generate a session ID of the received packet and send the session ID of the packet and the number information of the driver core A that has sent the packet to the concurrent processing engine to the core management controller (e.g., Figure 2 The core management controller 230 and Figure 3a and Figure 3b The core management controller may determine the location (e.g., number or cluster type) of network core B by considering the location of driver core A (e.g., number X), the location of application core C associated with the packet (e.g., number Y), and the packet processing volume.

[0153] In operation 740 , the driver core A of the electronic device may receive location information of the network processing core from the core management controller.

[0154] In operation 750, the driver core A may activate the network processing core B corresponding to the location acquired from the location information. The network processing core B may transmit the packet stored in the concurrent processing engine to the TCP buffer.

[0155] According to an embodiment, if the location of the network processing core indicates a cluster type, the driver core A of the electronic device may activate one of the cores belonging to the corresponding cluster type.

[0156] In operation 760 , the network processing core B of the electronic device may perform TCP / IP processing on the packet.

[0157] In operation 770, the application core C of the electronic device may process the packet TCP / IP-processed by the network processing core B. The application core C may be a core for operating an application associated with the session ID of the received packet.

[0158] Depending on the embodiment, operations 760 and 770 may be performed simultaneously or in parallel. For example, the TCP buffers allocated to the TCP / IP stack may include an Rx buffer for queuing packets processed by TCP / IP and a backlog buffer for queuing packets before they are processed. Application core C may process the packets queued in the Rx buffer, and simultaneously or in parallel, network processing core B may perform TCP / IP stack processing on the packets queued in the backlog buffer.

[0159] According to various embodiments, an electronic device (e.g., Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in the embodiment may include a communication device (e.g., Figure 1 The communication module 190 in the embodiment of the present invention is a multi-core (for example, Figure 2), and a memory storing instructions executable by at least one of the plurality of cores (e.g., Figure 1 The memory 130 and Figure 2 240 in the memory), wherein the instructions are used to check the location of a driver core for delivering packets received by the communication device to the OS domain, the location of an application core for processing packets in the user domain, and the processing volume of a session corresponding to the received packet, determine the location of a network processing core in the core based on the location of the driver core and the location of the application core and at least one of the processing volume of the session, and perform network stack processing on the packet delivered to the OS domain at the located network processing core.

[0160] According to an embodiment, the location of the network processing core is a core number or cluster information of a core type classified according to capability difference, and the location of the network processing core may be a core number or cluster information of a cluster type classified according to performance difference.

[0161] According to an embodiment, the instructions enable one of the multiple cores to determine a location of a network processing core by selecting a core number to control a network processing core layer.

[0162] According to an embodiment, a plurality of cores are classified into one of a first cluster type and a second cluster type, and the instructions cause at least one core of the plurality of cores to determine the cluster type of the network processing core and determine the position of the network processing core by randomly selecting a core number belonging to the determined cluster type to determine the position of the network processing core.

[0163] According to an embodiment, the instruction causes a core of a multi-core to activate a driver core with an arbitrary core number X among multiple cores, send a packet to an operating system domain through the driver core with core number X, obtain the position of a determined network processing core at the driver core with core number X, send the packet to a network processing core with core number Z through the driver core with core number X based on the obtained position of the network processing core, perform network stack processing on the received packet at the network processing core with core number Z, and process the packet processed by the network processing core with core number Z at an application core with an arbitrary core number Y.

[0164] According to an embodiment, the instructions cause a core of the multi-core to perform processing by batch-processing packets corresponding in number to a predetermined reference processing amount configured by the network processing core.

[0165] According to an embodiment, the electronic device includes a concurrent processing engine and a core management controller operating in an operating system domain, wherein the instructions cause the concurrent processing engine to: generate session identification information for a packet from a driver core, send the session identification information and the core number of the driver core that sends the packet to the concurrent processing engine to the core management controller, obtain the location of the network processing core from the core management controller, and send the packet received from the driver core to the network processing core at the determined location.

[0166] According to an embodiment, the instructions enable the core management controller to: determine the core number of the network processing core based on the session identification information of the received packet, the core number of the driver core, the core number of the application core that processes the packet, and at least one of the packet processing volume information of the session, and send the core number of the network processing core to the concurrent processing engine.

[0167] According to an embodiment, the instructions cause at least one core in the multi-cores to: monitor the operation of an application processing a packet based on session identification information of the packet to determine the location of the application core, and change the location of the application core processing the packet among the cores based on whether a condition for changing the location of the application core is satisfied, and determine the location of the application core based on whether the application is running in the foreground or in the background based on determining that the location of the core corresponding to the application associated with the packet is not specified. According to an embodiment, the instructions cause at least one core in the multi-cores to perform at least one of the following operations: identify the location of the application core based on determining that the location of the core for the application associated with the packet is specified, using the specified location of the core, determine the location of the application core based on whether the application is running in the foreground or in the background based on determining that the location of the core corresponding to the application associated with the packet is not specified, and determine the location of the application core through learning related to packet processing of the application.

[0168] Figure 8 is a flowchart illustrating a method of determining a core for processing a packet according to an embodiment of the present disclosure.

[0169] Reference Figure 8 , at operation 810, including multiple cores (e.g., Figure 2 An electronic device (e.g., a multi-core 210) Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in the embodiment may be connected to the NIC (e.g., Figure 3a and 3b The NIC 315 in receives the packet.

[0170] In operation 820 , the electronic device may activate the driver core A identified by the number X among the plurality of cores of the multi-core upon receiving the packet.

[0171] In operation 830, the driver core A identified by number X in the electronic device may process the received packet in a concurrent processing engine (eg, Figure 3a and 3b The engine buffer (e.g., Figure 4 The engine buffer 442 in the queue is used for queuing.

[0172] At operation 840, the concurrent processing engine generates a session ID for the packet and obtains the session ID from the core management controller (e.g., Figure 2 The core management controller 230 and Figure 3a and 3b The core management controller 330 in the network processing core B receives the number Y of the network processing core B. For example, Figure 9 Operation 840 is performed through operations 910 to 960 to obtain location information of the network processing core B (eg, number Y).

[0173] According to an embodiment, the concurrent processing engine may check the session ID of the received packet, send the number X of the driver core A that has delivered the packet to the concurrent processing engine to the core management controller, and receive the number Y of the network processing core B from the core management controller.

[0174] According to an embodiment, the core management controller may determine the number of the network processing core B for performing TCP / IP stack processing in consideration of the location of the application core associated with the session ID of the packet, the location of the driver core, and the per-session processing amount.

[0175] According to an embodiment, the core management controller may send number information of the network processing core B to the concurrent processing engine. The concurrent processing engine may assign the network processing core B identified by the corresponding number to process the received packet.

[0176] In operation 850 , the driver core A may activate the network processing core B identified by number Y.

[0177] In operation 860 , the network processing core B identified by number Y may output the packet from the engine buffer and queue the packet in the TCP buffer.

[0178] In operation 870 , the network processing core B identified by number Y may perform TCP / IP processing on the packets queued in the TCP buffer.

[0179] In operation 880, the application core C may process the TCP / IP-processed packet.

[0180] Although the electronic device control Figure 9 and Figure 10 The operation, but understandable, Figure 3a and Figure 3bThe core management controller depicted in or the processor controlling multiple cores controls the operations.

[0181] Figure 9 is a flowchart illustrating a method for a multi-core electronic device to determine a core for processing a packet according to an embodiment of the present disclosure.

[0182] Reference Figure 9 , including multi-core (e.g., Figure 2 Multi-core 210 and Figure 4 An electronic device (e.g., a multi-core 410) Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in FIG. 200 may determine the location of the network processing core B for performing network stack (eg, TCP / IP stack) processing on the packet. Although the electronic device control operations 910 to 960 are described, it is understood that the core management controller (eg, Figure 2 The core management controller 230 and Figure 3a and 3b A core management controller 330 in the ) or a processor that controls multiple cores (e.g., Figure 1 The processor 120 in can control the operations.

[0183] In operation 910, the electronic device may process data from a concurrent processing engine (eg, Figure 3a and 3b Concurrent processing engine 340, Figure 5 The concurrent processing engine 540 and Figure 6 The electronic device receives the session ID of the packet from the concurrent processing engine 640 in the concurrent processing engine. In operation 920, the electronic device may obtain session processing information about each application session. In operation 930, the electronic device may obtain location information (e.g., core number) of the driver core that has sent the packet to the concurrent processing engine. In operation 940, the electronic device may obtain location information (e.g., core number or cluster type) of the application core C used to process the packet associated with the session ID.

[0184] In operation 950 , the electronic device may determine the position Y of the network processing core B based on the session processing information, the core policy information, the position X of the driver core A, and the position Z of the application core C. In operation 960 , the electronic device may transmit information about the number Y of the network processing core B to the concurrent processing engine.

[0185] Figure 10 is a flowchart illustrating a method for a multi-core electronic device to determine a core for processing a packet according to an embodiment of the present disclosure.

[0186] Reference Figure 10 , including multi-core (e.g., Figure 2 Multi-core 210 and Figure 4 An electronic device (e.g., a multi-core 410) Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in the user domain may monitor the location of the application core that processes data in the user domain for changes, and determine the location of the network processing core B based on the changed location of the application core.

[0187] In operation 1010 , the electronic device may detect an application that processes packets queued in a TCP buffer in a user domain.

[0188] In operation 1020, the electronic device may acquire a number 'a' of an application core C that processes application data based on the application ID.

[0189] According to an embodiment, the electronic device may acquire location information (eg, core number or cluster type) of the application core C based on an application ID received from an agent included in a network processing stack (eg, TCP / IP stack).

[0190] In operation 1030 , the electronic device may monitor the application operating status.

[0191] In operation 1040 , the electronic device may determine the location of the application core.

[0192] According to an embodiment, the electronic device may check the application operation status and the number of packets being processed within the time the core processes the application based on the application ID, and if the usage of the core of a predetermined cluster type is greater than a threshold operation value, the cluster type of the corresponding core is designated as the position of the main core for processing the application.

[0193] According to an embodiment, the electronic device may specify the location of the application core based on whether the application is running in the foreground or in the background.

[0194] According to an embodiment, the electronic device may pre-specify a kernel location for a specific application, or specify the location of an application kernel through machine learning.

[0195] In operation 1050 , the electronic device may determine a throughput threshold of a packet throughput of the application according to a location of the application core.

[0196] According to an embodiment, the electronic device may change a threshold value of a packet processing amount of an application based on location information of an application core, location information of a driver core that delivers packets to a concurrent processing engine, and feature information of the application.

[0197] According to an embodiment, the electronic device may change a threshold value of a packet processing amount according to a location of a main core processing an application.

[0198] According to an embodiment, the electronic device may change the threshold value of the packet processing amount based on whether the application is running in the foreground or in the background.

[0199] According to an embodiment, the electronic device may change the threshold value of the packet processing amount based on preconfigured information, or if the position of the application core is designated through learning, may change the threshold value of the packet processing amount based on the designated position of the core.

[0200] The electronic device may update the application information in operation 1060. In operation 1070, the electronic device may determine at least one of the network processing core and / or the application core by applying the updated information.

[0201] Figure 11 is a flowchart illustrating a method for a multi-core electronic device to determine a core for processing a packet according to an embodiment of the present disclosure.

[0202] Reference Figure 11 , at operation 1110, including multiple cores (e.g., Figure 2 Multi-core 210 and Figure 4 An electronic device (e.g., a multi-core 410) Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in the embodiment may check the status of the application (or app) that processes the received packet. In operation 1120, the electronic device may determine whether the application is running in the foreground. If it is determined that the application is running in the foreground, in operation 1130, the electronic device may determine whether there is a core mapping for the application running in the foreground. If it is determined that the application is not running in the foreground, in operation 1125, the electronic device may determine whether there is a core mapping for the application running in the background. For example, the core mapping of the application may be information indicating the location of a pre-specified core based on the application ID.

[0203] If it is determined in operation 1130 or 1125 that a core mapping for the corresponding application exists, the electronic device may specify a cluster-type location of an RPS core for TCP / IP stack processing based on the application core mapping in operation 1140. For example, the RPS core may be a network processing core. If it is determined that a core mapping for the corresponding application does not exist, the process proceeds to operation 1150.

[0204] In operation 1145, the electronic device may determine whether the application core needs to be updated. According to an embodiment, if the location of the core specified in the application core map is different from the location of the application core that processes data in the user domain, the electronic device may determine that the application core map needs to be updated. According to an embodiment, if a predetermined time period for updating the core map has passed, the electronic device may determine that the application core map needs to be updated.

[0205] In operation 1150, the electronic device may determine and store the location of the application core for processing data in the user domain. In operation 1155, the electronic device may determine whether the number of times the same application core location determination result has reached N. If so, in operation 1160, the core may update the core map of the corresponding application. In operation 1170, the electronic device may configure the RPS core for TCP / IP stack processing based on the location information of the application core determined based on the application core location determination result.

[0206] Figure 12 is a flowchart illustrating a method for a multi-core electronic device to determine a core for processing a packet according to an embodiment of the present disclosure.

[0207] Reference Figure 12 , at operation 1210, including multiple cores (e.g., Figure 2 Multi-core 210 and Figure 4 An electronic device (e.g., a multi-core 410) Figure 1 The electronic device 101 and Figure 2 The electronic device 201 may activate a driver core A numbered X among a plurality of cores in the multi-core system. In operation 1220, the driver core A numbered X in the electronic device may send a packet to the concurrent processing engine. In operation 1230, the driver core A in the electronic device may obtain a location of the network processing core B determined based on the location X of the driver core A and the location Y of the application core C.

[0208] In operation 1240, the network processing core B corresponding to the location acquired by the electronic device may perform TCP / IP processing on the received packet.

[0209] In operation 1250, the electronic device may determine whether the location of the application core C is changed. For example, the electronic device may determine whether the location of the application core C is changed by performing a reference to Figure 10 or Figure 11 The described operation determines whether the position of the application core C is changed.

[0210] If it is determined in operation 1250 that the position of the application core C is changed, then in operation 1270, the application core C′ having the changed core number W may process the packet for which TCP / IP processing is performed by the network processing core B. If it is determined in operation 1250 that the position of the application core C is not changed, then in operation 1260, the application core C having the core number Y may process the packet for which TCP / IP processing is performed by the network processing core B.

[0211] According to various embodiments, an electronic device (e.g., Figure 1 The electronic device 101 and Figure 2 The electronic device 201 in the embodiment may include a communication device (e.g., Figure 1, a communication module 190 in the driver core A layer, a network processing core B layer, and an application core C layer), a multi-core (eg, Figure 2 Multi-core 210 in, memory (e.g., Figure 1 The memory 130 and Figure 2 240) and a processor (e.g., Figure 1 the processor 120 in the processor); the processor can be controlled to check the position of a driver core that is one of the multiple cores of the multi-core and is used to send a packet to the OS domain when at least one packet is received via a communication device, the position of an application core that processes the packet in the user domain, and the processing volume of the session corresponding to the received packet, determine the position of a network processing core in the core based on at least one of the position of the driver core, the position of the application core and the processing volume of the session, and control the network processing core at the determined position among the multiple cores to perform network stack processing on the packet.

[0212] According to an embodiment, the processor is configured to determine a location of a network processing core by selecting a core number to control a network processing core layer.

[0213] According to an embodiment, a plurality of cores are classified into one of a first cluster type and a second cluster type, and a processor is configured to control to determine the cluster type of the network processing core and determine the position of the network processing core by selecting a core number belonging to the determined cluster type to determine the position of the network processing core.

[0214] According to an embodiment, the processor is configured to control to activate a driver core with an arbitrary core number X among multiple cores, send a packet to an operating system domain through the driver core with core number X, obtain a determined position of a network processing core at the driver core with core number X, send the packet to a network processing core with core number Z through the driver core with core number X based on the obtained position of the network processing core, perform network stack processing on the received packet at the network processing core with core number Z, and process the packet processed by the network processing core with core number Z at an application core with an arbitrary core number Y.

[0215] According to an embodiment, the processor is configured to perform control to perform processing by batch-processing packets corresponding in number to a predetermined reference processing volume configured by the network processing core in the operating system domain.

[0216] According to an embodiment, the electronic device includes a concurrent processing engine, wherein the concurrent processing engine operates in an operating system domain and is configured to generate session identification information for a packet from a driver core, send the session identification information and a core number of the driver core that sends the packet to the concurrent processing engine to a processor, obtain the location of a network processing core from the processor, and send the packet to the network processing core at the determined location.

[0217] According to an embodiment, the processor is configured to determine the core number of the network processing core based on the session identification information of the received packet, the core number of the driver core, the core number of the application core that processes the packet, and at least one of the packet processing volume information of the session, and send the core number of the network processing core to the concurrent processing engine, wherein the concurrent processing engine is configured to send the packet to the network processing core corresponding to the received core number.

[0218] According to an embodiment, the processor is configured to control to determine the location of the application core by monitoring the operation of the application processing the packet based on the session identification information of the packet, and change the location of the application core processing the packet in the core based on the condition for changing the location of the application core being met.

[0219] According to an embodiment, the processor is configured to control to identify the location of the application core based on determining that the location of the core for the application associated with the group is specified, using the specified location of the core, determining the location of the application core based on whether the application is running in the foreground or in the background based on determining that the location of the core corresponding to the application associated with the group is not specified, or determining the location of the application core through learning related to the group processing of the application.

[0220] Figure 13a 、 Figure 13b and Figure 13c is a graph showing effects according to various embodiments of the present disclosure.

[0221] Reference Figure 13a, the graph shows in a comparative manner the current consumption of the prior art and the proposed technology for processing the same number of packets during a session. Reference numeral 1310 represents the amount of current consumed by the prior art for processing packets, and reference numeral 1320 represents the amount of current consumed by the proposed technology for processing packets by a core selected according to one of the various disclosed embodiments. For example, unlike the prior art that selects a large core for network stack processing when the packet processing volume of a session is equal to or greater than a threshold, the proposed technology can determine the core for network stack processing based on the locations of the application core and the driver core even when the packet processing volume of the session is equal to or greater than the threshold. In the case of using the proposed technology, batch processing efficiency can be maximized by determining the core for performing network stack processing on the received packets in consideration of the processing volume of the session and the location information of the application core and the driver core. With reference Figure 13a ,Compared with the existing technology, the proposed technology improves the current consumption efficiency by 11%. Figure 13b is a graph showing the throughput of the prior art and the proposed technology during a session in a comparative manner. Figure 13b , reference numeral 1330 represents the packet processing volume of the RPS technology of the related art, reference numeral 1340 represents the packet processing volume of the related art, and reference numeral 1350 represents the packet processing volume of the proposed technology, in which packets are processed by a core determined in consideration of the position of the application core and a core for performing network stack processing. For example, in the case of randomly selecting a core for performing network stack processing, the efficiency of batch processing of packets delivered from the driver core may be low due to the relatively low-performance core performing TCP / IP processing. The proposed technology is able to efficiently process packets by determining the core for processing batched packets in consideration of the packet processing volume of the session and the positions of the application core and the driver core. With reference to Figure 13b ,Compared to the existing techniques, the proposed technique improves the ,packet processing by 6%-67% by selecting layer cores in a way that maximizes the batch ,processing throughput. Figure 13c is a graph showing, in a comparative manner, current consumption of the prior art and the proposed technology for processing the same number of packets during two sessions. Reference numeral 1360 represents the amount of current consumed by the prior art for processing packets, and reference numeral 1370 represents the amount of current consumed by the proposed technology, in which the core selected according to one of the various disclosed embodiments processes the packets. Unlike the prior art, in the case of the proposed technology, batch processing efficiency can be maximized by determining the location of the core for processing the packets of each session. Figure 13c ,Compared with the existing technology, the proposed technology improves the current consumption efficiency by 6%.

[0222] While the present disclosure has been shown and described with reference to various embodiments thereof, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the present disclosure as defined by the appended claims and their equivalents.

Claims

1. An electronic device including a multi-core, the electronic device comprising: Communication circuits; a multi-core comprising a plurality of cores, wherein each core is configured to process packetized data; and Memory, The memory is configured to store an execution instruction, wherein the execution instruction is used to cause one core among the multiple cores to perform the following operation: When processing packet data received by the communication circuit, identifying a processing amount of the packet, Allocating a first core to process the packetized network data based on the processing volume, allocating a second core to process application data, and allocating a third core to process driver data, and When the processing amount of received packets becomes equal to or greater than a predetermined level, the first core is allocated to process both network data and application data.

2. The electronic device according to claim 1, wherein Each core of the plurality of cores is classified into one of a first type and a second type, and Here, the first type is one of a large core and a small core, and the second type is the other of the large core and the small core.

3. The electronic device according to claim 1, wherein The operations of allocating the first core to process both network data and application data include: A core classified as the same type as the first core is assigned to process the application data.

4. The electronic device according to claim 1, in, The operations of allocating the first core to process both network data and application data include: A core classified as a type having higher performance than the type of the first core is allocated.

5. The electronic device according to claim 1, wherein The instructions further cause the one of the plurality of cores to: batch processing, by the first core, an amount of the packets corresponding to a predetermined reference processing amount of the first core; The packets batched in the first core are sent to the second core. The electronic device according to claim 1 , wherein: The instructions further cause the one core of the plurality of cores to: activating a third core of the plurality of cores to process the grouped driver data, Get the position of the first core at the third core, Based on assigning the first core to process the network data, the packet is sent to the first core via the third core.

7. The electronic device according to claim 1, further comprising: Concurrent processing engine and core management controller, The instruction causes the concurrent processing engine to perform the following operations: generating session identification information of the packet from the third core, sending the session identification information and the core number of the third core to the core management controller, identifying, by the core management controller, a first core, and The packet received from the third core is sent to the first core.

8. The electronic device according to claim 7, wherein: The instructions further cause the core management controller to: Allocate the first core to process network data based on at least one of the session identification information, allocating the third core to process driver data, allocating the second core to process application data, and packet processing volume information of the session, and At least one core number of the first core and the second core is sent to the concurrent processing engine.

9. The electronic device according to claim 7, wherein: The instructions further cause the one core of the plurality of cores to: allocating a second core to process application data based on monitoring the operation of the application that is processing the packet and the session identification information of the packet; Based on the condition for changing the core that processes the application data being satisfied, a core different from the second core is allocated to process the application data.

10. The electronic device according to claim 9, wherein: The instructions further cause the one of the plurality of cores to perform at least one of the following operations: based on determining that a core is designated for the application associated with the packet, allocating a second core to process the application data using the designated core number of the core, In a case where the core corresponding to the application is not designated, a second core is allocated to process application data based on whether the application is running in the foreground or the background and / or a learning process related to packet processing of the application.

11. An electronic device comprising: Communication circuits; a multi-core comprising a plurality of cores, wherein each core is configured to process packetized data; Memory; and The processor is configured to: When processing packet data received by the communication circuit, identifying a processing amount of the packet, Allocating a first core to process the packetized network data based on the processing volume, allocating a second core to process application data, and allocating a third core to process driver data, and When the processing amount of received packets becomes equal to or greater than a predetermined level, the first core is allocated to process both network data and application data.

12. The electronic device according to claim 11, wherein: Each of the cores is classified as one of a first type and a second type, and wherein the first type is one of a large core and a small core, and the second type is the other of the large core and the small core, The operation of allocating the first core to process both the network data and the application data includes: allocating a core classified as the same type as the first core to process the application data.

13. The electronic device according to claim 11, in, The operations of allocating the first core to process both network data and application data include: A core classified as a type having higher performance than the type of the first core is allocated.

14. The electronic device according to claim 11, wherein The processor is further configured to: controlling to activate a third core among the plurality of cores to process the grouped driver data, Get the position of the first core at the third core, Based on assigning the first core to process the network data, the packet is sent to the first core via the third core.

15. The electronic device according to claim 11, wherein The processor is further configured to control to process by batch-processing packets corresponding to a predetermined reference processing amount configured by the first core; and transmit the packets batch-processed in the first core to the second core.

16. The electronic device according to claim 11, further comprising: The concurrent processing engine operates in the operating system domain and is configured to: generating session identification information of the packet from the third core, sending the session identification information and the core number of the third core to the core management controller, identifying, by the core management controller, a first core, and The packet received from the third core is sent to the first core.

17. The electronic device according to claim 16, wherein: The processor is further configured to: Allocating the first core to process the network data based on at least one of the session identification information, allocating the third core to process the driver data, allocating the second core to process the application data, and the packet processing volume information of the session, and At least one core number of the first core and the second core is sent to the concurrent processing engine.

18. The electronic device according to claim 17, wherein: The processor is further configured to: allocating a second core to process application data based on monitoring an operation of an application processing the packet and the session identification information of the packet; Based on the condition for changing the core that processes the application data being satisfied, a core different from the second core is allocated to process the application data.

19. The electronic device according to claim 18, wherein: The processor is further configured to: based on determining that a core is designated for the application associated with the packet, allocating a second core to process the application data using the designated core number of the core, Based on determining that the core corresponding to the application associated with the packet is unassigned, a second core is assigned to process application data based on whether the application is running in the foreground or background and / or learning related to packet processing of the application.

20. The electronic device according to claim 19, wherein The processor is further configured to: allocate the second core to process application data based on processing requirements of the application.

Citation Information

Patent Citations

  • Systems and methods for handling a multi-connection protocol between a client and server traversing a multi-core system

    US20100322252A1

  • Systems and methods for port allocation

    US20150124828A1

  • Application Characterization for Machine Learning on Heterogeneous Core Devices

    US20160171390A1

  • Shared processing of a packet flow by multiple cores

    US20180365176A1