CN106776039B - Data processing method and device - Google Patents

Data processing method and device Download PDF

Info

Publication number
CN106776039B
CN106776039B CN201611265302.7A CN201611265302A CN106776039B CN 106776039 B CN106776039 B CN 106776039B CN 201611265302 A CN201611265302 A CN 201611265302A CN 106776039 B CN106776039 B CN 106776039B
Authority
CN
China
Prior art keywords
processor
target
data
service
processed
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201611265302.7A
Other languages
Chinese (zh)
Other versions
CN106776039A (en
Inventor
白剑
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201611265302.7A priority Critical patent/CN106776039B/en
Publication of CN106776039A publication Critical patent/CN106776039A/en
Application granted granted Critical
Publication of CN106776039B publication Critical patent/CN106776039B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Telephonic Communication Services (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the invention discloses a data processing method and a data processing device, wherein the data processing method comprises the following steps: the service distributor receives data to be processed; the service distributor determines the target service type of the data to be processed; the service distributor determines a target processor adapted to the target service type; and the service distributor inputs the data to be processed into the target processor for processing. The invention can process the data with pertinence, improve the data processing efficiency and save the processing resource.

Description

Data processing method and device
Technical Field
The present invention relates to the field of communications network technologies, and in particular, to a data processing method and apparatus.
Background
All service data of the terminal are processed by a main processor, for example, after the service data such as voice, picture, music, text and the like are input into the terminal, the terminal adopts the main processor to process the service data, and in order to improve the efficiency of data processing, the main processor is continuously optimized in the industry, for example, the processing speed is continuously improved, the accuracy of processing data is continuously improved, and the like. However, different service data generally have different performance requirements for the main processor, and for example, it is very wasteful to use a high-performance processor to process plain text information.
Disclosure of Invention
The embodiment of the invention provides a data processing method and device, which can be used for processing data in a targeted manner, improving the data processing efficiency and saving processing resources.
A first aspect of an embodiment of the present invention provides a data processing method, which is applied to a terminal, where the terminal includes a service distributor and a plurality of processors, where the plurality of processors have different performances, and the method may include:
the service distributor receives data to be processed;
the service distributor determines the target service type of the data to be processed;
the service distributor determines a target processor adapted to the target service type;
and the service distributor inputs the data to be processed into the target processor for processing.
A second aspect of the embodiments of the present invention provides a data processing apparatus, which is applied to a service distributor of a terminal, where the terminal further includes multiple processors, and the multiple processors have different performances, and may include:
the receiving unit is used for receiving data to be processed;
the first determining unit is used for determining the type of the target service to which the data to be processed belongs;
a second determining unit, configured to determine a target processor adapted to the target service type;
and the first input module is used for inputting the data to be processed into the target processor for processing.
In the embodiment of the invention, the terminal comprises a service distributor and a plurality of processors, wherein the plurality of processors have different performances, the service distributor receives data to be processed, determines the target service type of the data to be processed, determines the target processor matched with the target service type, and inputs the data to be processed into the target processor for processing.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flow chart of a data processing method according to a first embodiment of the present invention;
FIG. 2 is a flowchart illustrating a data processing method according to a second embodiment of the present invention;
FIG. 3 is a flowchart illustrating a data processing method according to a third embodiment of the present invention;
fig. 4 is a diagram illustrating an internal system architecture of a terminal according to an embodiment of the present invention;
FIG. 5 is a schematic structural diagram of a data processing apparatus according to an embodiment of the present invention;
FIG. 6 is a block diagram of another data processing apparatus according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of another data processing apparatus according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The term "object" in the description and claims of the present invention and the drawings is used to distinguish between different objects and is not used to describe a particular object. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the invention. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
The terminal described in the embodiment of the present invention may include a smart Phone (such as an Android Phone, an iOS Phone, a Windows Phone, etc.), a tablet computer, a palm computer, a notebook computer, a mobile internet device (MID, mobile internet Devices), or a wearable device, and the terminal is merely an example, and is not exhaustive and includes but is not limited to the terminal.
The following describes a data processing method and apparatus provided by an embodiment of the present invention with reference to fig. 1 to 7.
Fig. 1 is a flowchart illustrating a data processing method according to a first embodiment of the present invention. As shown in the figure, the data processing method of the embodiment of the present invention includes the steps of:
s101, the service distributor receives data to be processed;
in the embodiment of the present invention, the data to be processed may be various data received by the terminal, such as voice data, video data, picture data, music data, text data, and the like. As shown in fig. 4, the terminal is internally provided with a service distributor and a plurality of processors (such as processor 1, processor 2 and processor 3 in the figure) with different performances. For example, the processing speed of the processor 1 is the best, the other performances are general, the processing accuracy of the processor 2 is the highest, the processing speed is slightly slow, the processing speed and the processing accuracy of the processor 3 are poor, the processor 3 belongs to the processor with the worst performance among the three processors, and of course, the cost of the processor 3 is low, and the costs of the processor 2 and the processor 3 are high.
S102, the service distributor determines the target service type of the data to be processed;
in the embodiment of the invention, after receiving the data to be processed, the service distributor analyzes the data to be processed and determines the target service type of the data to be processed. Specifically, optionally, the data to be processed is encapsulated in a frame structure, where the frame structure includes a service type identifier to which the data to be processed belongs. The service distributor can determine the target service type of the data to be processed according to the service type identifier in the frame structure.
The service types can be divided according to the types of the data to be processed, for example, the chat information of the instant messaging application chat belongs to the text service type; the played local video, the played online video or the video data transmitted by utilizing the instant messaging application to carry out video chat all belong to video service types; the local audio played by using the terminal, the online audio played by using the terminal, the voice call performed by using the terminal between users or the music played by using the music application all belong to audio service types; the signaling exchanged between the terminal and the base station or the access point belongs to the control service type.
S103, the service distributor determines a target processor adaptive to the target service type;
in the embodiment of the present invention, generally, the data of different service types have different requirements on the performance of the processor, for example, for the data of an audio service type or the data of a video service type, the processing speed requirement on the processor is relatively high, and if the processing speed of the processor is not fast enough, a pause phenomenon may be generated, which seriously affects the user experience. For the data of the control service type, the processing accuracy rate of the processor is high, and if the processing accuracy rate of the processor is not high enough, the result of data analysis error is generated, and finally network connection failure is caused. And for the data of the text service type, no specific requirements are required on the processing speed and the processing accuracy of the processor.
The service distributor determines a target processor adapted to a target service type of the data to be processed, and specifically, optionally, the service distributor may preset a corresponding relationship between each service type and the processor, where the corresponding relationship may be to determine the corresponding processor according to a data processing requirement of the service type, for example, a service type with a higher requirement on processing speed, that is, a processor corresponding to a higher processing speed, and a service type with a higher requirement on processing accuracy, that is, a processor corresponding to a higher processing accuracy.
After the service distributor determines the target service type of the data to be processed, a target processor corresponding to the target service type is inquired, and the target processor is determined as a processor adaptive to the target service type.
Alternatively, the service distributor may classify the processors into a plurality of categories according to the performance difference, for example, a plurality of processors with higher processing speed are classified into a processor with a higher processing speed, a plurality of processors with higher processing accuracy are classified into a processor with a higher accuracy, and a plurality of processors with general processing performance are classified into a general processor. When the service distributor determines a target service type of data to be processed, the processing requirement of the target service type for the processor is obtained, for example, the target service type is a video service type, a processor with a high processing speed is required, that is, an idle or least-loaded processor is selected from a plurality of processors with high processor speed as a target processor.
S104, the service distributor inputs the data to be processed into the target processor for processing.
In the embodiment of the present invention, the service distributor inputs the data to be processed into the target processor for processing, as shown in fig. 4, if the service distributor determines that the target processor adapted to the target service type of the data to be processed is the processor 3, the service distributor inputs the data to be processed into the processor 3 for processing.
It should be noted that, each processor processes data simultaneously, and may invoke the same hardware resource, for example, the processor 2 needs to invoke the bluetooth hardware resource when processing data, and the processor 3 also needs to invoke the bluetooth hardware resource when processing data, so that the processor 2 and the processor 3 may invoke the same hardware resource in a time division multiplexing manner.
In the embodiment of the invention, the terminal comprises a service distributor and a plurality of processors, wherein the plurality of processors have different performances, the service distributor receives data to be processed, determines the target service type of the data to be processed, determines the target processor matched with the target service type, and inputs the data to be processed into the target processor for processing.
Fig. 2 is a flowchart illustrating a data processing method according to a second embodiment of the present invention. As shown in the figure, the data processing method of the embodiment of the present invention includes the steps of:
s201, the service distributor sets corresponding relations between the plurality of service types and the plurality of processors according to performance differences of the plurality of processors and processing requirements of data of the plurality of service types in advance;
optionally, the correspondence between the service types and the processors includes:
the voice service type and the video service type correspond to a processor with a processing speed greater than a first threshold value;
controlling the signaling service type to correspond to the processor with the processing accuracy rate larger than a second threshold value;
the text service type corresponds to a processor with a processing speed less than or equal to the first threshold and a processing accuracy less than or equal to the second threshold.
In this embodiment of the present invention, the service distributor may preset a correspondence between a plurality of service types and a plurality of processors, for example, at least one processor may be distributed according to processing requirements of data of the service types on the processors, and a correspondence between the service types and the at least one processor is established, that is, one service type may correspond to one processor, or one service corresponds to a plurality of processors, further optionally, a plurality of service types may correspond to the same processor, or one processor may correspond to only one service type, that is, a one-to-one correspondence relationship between processors and service types.
Specifically, optionally, if the requirements of the voice service type and the video service type on the processing speed of the processor are higher, the processor with the processing speed greater than the first threshold value corresponding to the voice service type and the video service type can be established, and the first threshold value can be set according to the actual situation; if the requirement of the control signaling service type on the processing accuracy of the processor is higher, the control signaling service type and the processor with the processing accuracy larger than the second threshold value can be established to correspond to each other; for a general service type, such as a text service type, the text service type may be established to correspond to a general processor, and the general processor may be a process with a smaller processing speed and a smaller processing accuracy.
By differentially establishing the correspondence between each service type and the processor, the cost can be saved, because the cost of the high-performance processor is much higher than that of the low-performance processor, and the processing efficiency of the data can not be influenced.
S202, the service distributor receives data to be processed;
s203, the service distributor determines the target service type of the data to be processed;
referring to steps S101 to S102 of the embodiment of fig. 1, steps S202 to S203 of the embodiment of the present invention are not described herein again.
S204, the service distributor searches a target processor corresponding to the target service type.
In the embodiment of the present invention, after the corresponding relationship between each service type and a processor is established, the service distributor may search for a target processor corresponding to the target service type, and if the target processor corresponding to the target service type is found to include multiple processors, a processor with the smallest load may be selected from the multiple processors as a target processor adapted to the target service type.
S205, the service distributor inputs the data to be processed into the target processor for processing.
Step S205 in the embodiment of the present invention refers to step S104 in the embodiment of fig. 1, and is not described herein again.
In the embodiment of the invention, the terminal comprises a service distributor and a plurality of processors, wherein the plurality of processors have different performances, the service distributor receives data to be processed, determines the target service type of the data to be processed, determines the target processor matched with the target service type, and inputs the data to be processed into the target processor for processing.
Fig. 3 is a flowchart illustrating a data processing method according to a third embodiment of the present invention. As shown in the figure, the data processing method of the embodiment of the present invention includes the steps of:
s301, the service distributor receives data to be processed;
s302, the service distributor determines the target service type of the data to be processed;
s303, the service distributor determines a target processor adapted to the target service type;
referring to steps S101 to S103 of the embodiment of fig. 1, steps S301 to S303 of the embodiment of the present invention are not described herein again.
S304, the service distributor judges whether the load of the target processor is smaller than a third threshold value;
s305, if the load of the target processor is smaller than the third threshold, the service distributor inputs the data to be processed into the target processor for processing.
In the embodiment of the present invention, if one service type corresponds to one processor, but one processor may correspond to multiple service types, after determining a target processor adapted to a target service type, the service distributor determines whether a load of the target processor is smaller than a third threshold.
And if the load of the target processor is smaller than the third threshold value, inputting the data to be processed into the target processor for processing.
S306, if the load of the target processor is greater than the third threshold, the service distributor determines an alternative processor of the target processor, the target performance value of the alternative processor is different from the target performance value of the target processor by a fourth threshold, and the target performance is the optimal performance of the target processor;
in the embodiment of the present invention, if the load of the target processor is greater than the third threshold, the data to be processed cannot be input into the target processor for processing, because if the data to be processed is input into the target processor for processing, a long time is required, which reduces user experience.
If the load of the target processor is greater than the third threshold, the service distributor determines an alternative processor of the target processor, and it should be noted that the alternative processor may be set in advance (for example, the alternative processor corresponding to the target processor is bound in advance), or may be temporarily distributed according to the load condition of each current processor and the processing performance of each processor.
S307, the service distributor inputs the data to be processed into the alternative processor for processing.
In the embodiment of the invention, the service distributor inputs the data to be processed into the alternative processors for processing, so that the load of each processor can be balanced, and the processing efficiency of the data to be processed cannot be reduced.
In the embodiment of the invention, the terminal comprises a service distributor and a plurality of processors, wherein the plurality of processors have different performances, the service distributor receives data to be processed, determines the target service type of the data to be processed, determines the target processor matched with the target service type, and inputs the data to be processed into the target processor for processing.
Fig. 5 is a schematic structural diagram of a data processing apparatus according to an embodiment of the present invention. As shown in the figure, the data processing apparatus according to the embodiment of the present invention includes a receiving unit 10, a first determining unit 11, a second determining unit number 12, and a first input unit 13;
a receiving unit 10, configured to receive data to be processed;
in the embodiment of the present invention, the data to be processed may be various data received by the terminal, such as voice data, video data, picture data, music data, text data, and the like. As shown in fig. 4, the terminal is internally provided with a service distributor and a plurality of processors (such as processor 1, processor 2 and processor 3 in the figure) with different performances. For example, the processing speed of the processor 1 is the best, the other performances are general, the processing accuracy of the processor 2 is the highest, the processing speed is slightly slow, the processing speed and the processing accuracy of the processor 3 are poor, the processor 3 belongs to the processor with the worst performance among the three processors, and of course, the cost of the processor 3 is low, and the costs of the processor 2 and the processor 3 are high.
A first determining unit 11, configured to determine a target service type to which the to-be-processed data belongs;
in the embodiment of the invention, after receiving the data to be processed, the service distributor analyzes the data to be processed and determines the target service type of the data to be processed. Specifically, optionally, the data to be processed is encapsulated in a frame structure, where the frame structure includes a service type identifier to which the data to be processed belongs. The service distributor can determine the target service type of the data to be processed according to the service type identifier in the frame structure.
The service types can be divided according to the types of the data to be processed, for example, the chat information of the instant messaging application chat belongs to the text service type; the played local video, the played online video or the video data transmitted by utilizing the instant messaging application to carry out video chat all belong to video service types; the local audio played by using the terminal, the online audio played by using the terminal, the voice call performed by using the terminal between users or the music played by using the music application all belong to audio service types; the signaling exchanged between the terminal and the base station or the access point belongs to the control service type.
A second determining unit 12, configured to determine a target processor adapted to the target service type;
in the embodiment of the present invention, generally, the data of different service types have different requirements on the performance of the processor, for example, for the data of an audio service type or the data of a video service type, the processing speed requirement on the processor is relatively high, and if the processing speed of the processor is not fast enough, a pause phenomenon may be generated, which seriously affects the user experience. For the data of the control service type, the processing accuracy rate of the processor is high, and if the processing accuracy rate of the processor is not high enough, the result of data analysis error is generated, and finally network connection failure is caused. And for the data of the text service type, no specific requirements are required on the processing speed and the processing accuracy of the processor.
The service distributor determines a target processor adapted to a target service type of the data to be processed, and specifically, optionally, the service distributor may preset a corresponding relationship between each service type and the processor, where the corresponding relationship may be to determine the corresponding processor according to a data processing requirement of the service type, for example, a service type with a higher requirement on processing speed, that is, a processor corresponding to a higher processing speed, and a service type with a higher requirement on processing accuracy, that is, a processor corresponding to a higher processing accuracy.
After the service distributor determines the target service type of the data to be processed, a target processor corresponding to the target service type is inquired, and the target processor is determined as a processor adaptive to the target service type.
Alternatively, the service distributor may classify the processors into a plurality of categories according to the performance difference, for example, a plurality of processors with higher processing speed are classified into a processor with a higher processing speed, a plurality of processors with higher processing accuracy are classified into a processor with a higher accuracy, and a plurality of processors with general processing performance are classified into a general processor. When the service distributor determines a target service type of data to be processed, the processing requirement of the target service type for the processor is obtained, for example, the target service type is a video service type, a processor with a high processing speed is required, that is, an idle or least-loaded processor is selected from a plurality of processors with high processor speed as a target processor.
A first input unit 13, configured to input the data to be processed into the target processor for processing.
In the embodiment of the present invention, the service distributor inputs the data to be processed into the target processor for processing, as shown in fig. 4, if the service distributor determines that the target processor adapted to the target service type of the data to be processed is the processor 3, the service distributor inputs the data to be processed into the processor 3 for processing.
It should be noted that, each processor processes data simultaneously, and may invoke the same hardware resource, for example, the processor 2 needs to invoke the bluetooth hardware resource when processing data, and the processor 3 also needs to invoke the bluetooth hardware resource when processing data, so that the processor 2 and the processor 3 may invoke the same hardware resource in a time division multiplexing manner.
In the embodiment of the invention, the terminal comprises a service distributor and a plurality of processors, wherein the plurality of processors have different performances, the service distributor receives data to be processed, determines the target service type of the data to be processed, determines the target processor matched with the target service type, and inputs the data to be processed into the target processor for processing.
Fig. 6 is a schematic structural diagram of another data processing apparatus according to an embodiment of the present invention. As shown in the figure, the data processing apparatus according to the embodiment of the present invention includes a setting unit 20, a receiving unit 21, a first determining unit 22, a second determining unit 23, and a first input unit 24;
a setting unit 20, configured to set, in advance, correspondence between the multiple service types and the multiple processors according to performance differences of the multiple processors and processing requirements of data of the multiple service types;
optionally, the correspondence between the service types and the processors includes:
the voice service type and the video service type correspond to a processor with a processing speed greater than a first threshold value;
controlling the signaling service type to correspond to the processor with the processing accuracy rate larger than a second threshold value;
the text service type corresponds to a processor with a processing speed less than or equal to the first threshold and a processing accuracy less than or equal to the second threshold.
In this embodiment of the present invention, the service distributor may preset a correspondence between a plurality of service types and a plurality of processors, for example, at least one processor may be distributed according to processing requirements of data of the service types on the processors, and a correspondence between the service types and the at least one processor is established, that is, one service type may correspond to one processor, or one service corresponds to a plurality of processors, further optionally, a plurality of service types may correspond to the same processor, or one processor may correspond to only one service type, that is, a one-to-one correspondence relationship between processors and service types.
Specifically, optionally, if the requirements of the voice service type and the video service type on the processing speed of the processor are higher, the processor with the processing speed greater than the first threshold value corresponding to the voice service type and the video service type can be established, and the first threshold value can be set according to the actual situation; if the requirement of the control signaling service type on the processing accuracy of the processor is higher, the control signaling service type and the processor with the processing accuracy larger than the second threshold value can be established to correspond to each other; for a general service type, such as a text service type, the text service type may be established to correspond to a general processor, and the general processor may be a process with a smaller processing speed and a smaller processing accuracy.
By differentially establishing the correspondence between each service type and the processor, the cost can be saved, because the cost of the high-performance processor is much higher than that of the low-performance processor, and the processing efficiency of the data can not be influenced.
A receiving unit 21, configured to receive data to be processed;
a first determining unit 22, configured to determine a target service type to which the to-be-processed data belongs;
the second determining unit 23 is specifically configured to search for a target processor corresponding to the target service type.
In the embodiment of the present invention, after the corresponding relationship between each service type and a processor is established, the service distributor may search for a target processor corresponding to the target service type, and if the target processor corresponding to the target service type is found to include multiple processors, a processor with the smallest load may be selected from the multiple processors as a target processor adapted to the target service type.
A first input unit 24, configured to input the data to be processed into the target processor for processing.
In the embodiment of the invention, the terminal comprises a service distributor and a plurality of processors, wherein the plurality of processors have different performances, the service distributor receives data to be processed, determines the target service type of the data to be processed, determines the target processor matched with the target service type, and inputs the data to be processed into the target processor for processing.
Fig. 7 is a schematic structural diagram of another data processing apparatus according to an embodiment of the present invention. As shown in the figure, the data processing apparatus according to the embodiment of the present invention includes a receiving unit 30, a first determining unit 31, a second determining unit 32, a judging unit 33, a first input unit 34, a third determining unit 35, and a second input unit 36;
a judging unit 33, configured to judge whether the load of the target processor is smaller than a third threshold;
the first input unit 34 is specifically configured to input the data to be processed into the target processor for processing if the load of the target processor is smaller than the third threshold.
In the embodiment of the present invention, if one service type corresponds to one processor, but one processor may correspond to multiple service types, after determining a target processor adapted to a target service type, the service distributor determines whether a load of the target processor is smaller than a third threshold.
And if the load of the target processor is smaller than the third threshold value, inputting the data to be processed into the target processor for processing.
A third determining unit 35, configured to determine, if the load of the target processor is greater than the third threshold, an alternative processor of the target processor, where a target performance value of the alternative processor is different from a target performance value of the target processor by a fourth threshold, where the target performance is the optimal performance of the target processor;
in the embodiment of the present invention, if the load of the target processor is greater than the third threshold, the data to be processed cannot be input into the target processor for processing, because if the data to be processed is input into the target processor for processing, a long time is required, which reduces user experience.
If the load of the target processor is greater than the third threshold, the service distributor determines an alternative processor of the target processor, and it should be noted that the alternative processor may be set in advance (for example, the alternative processor corresponding to the target processor is bound in advance), or may be temporarily distributed according to the load condition of each current processor and the processing performance of each processor.
A second input unit 36, configured to input the data to be processed into the alternative processor for processing.
In the embodiment of the invention, the service distributor inputs the data to be processed into the alternative processors for processing, so that the load of each processor can be balanced, and the processing efficiency of the data to be processed cannot be reduced.
The receiving unit 30, the first determining unit 31, and the second determining unit 32 are described with reference to the embodiment of fig. 6, and are not described herein again.
In the embodiment of the invention, the terminal comprises a service distributor and a plurality of processors, wherein the plurality of processors have different performances, the service distributor receives data to be processed, determines the target service type of the data to be processed, determines the target processor matched with the target service type, and inputs the data to be processed into the target processor for processing.
An embodiment of the present invention further provides a computer storage medium, where the computer storage medium may store a program, and the program includes, when executed, some or all of the steps of any one of the data processing methods described in the above method embodiments.
While the invention has been described in connection with various embodiments, other variations to the disclosed embodiments can be understood and effected by those skilled in the art in practicing the claimed invention, from a review of the drawings, the disclosure, and the appended claims. In the claims, the word "comprising" does not exclude other elements or steps, and the word "a" or "an" does not exclude a plurality. A single processor or other unit may fulfill the functions of several items recited in the claims. The mere fact that certain measures are recited in mutually different dependent claims does not indicate that a combination of these measures cannot be used to advantage.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus (device), or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein. A computer program stored/distributed on a suitable medium supplied together with or as part of other hardware, may also take other distributed forms, such as via the Internet or other wired or wireless telecommunication systems.
The present invention has been described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (devices) and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the invention has been described in conjunction with specific features and embodiments thereof, it will be evident that various modifications and combinations can be made thereto without departing from the spirit and scope of the invention. Accordingly, the specification and figures are merely exemplary of the invention as defined in the appended claims and are intended to cover any and all modifications, variations, combinations, or equivalents within the scope of the invention. It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (8)

1. A data processing method is applied to a terminal, the terminal comprises a service distributor and a plurality of processors, and the plurality of processors have different performances, and the method is characterized by comprising the following steps:
the service distributor receives data to be processed;
the service distributor determines the target service type of the data to be processed;
the service distributor determines a target processor adapted to the target service type;
the service distributor judges whether the load of the target processor is smaller than a third threshold value; if the load of the target processor is smaller than the third threshold value, the service distributor inputs the data to be processed into the target processor for processing;
the method further comprises the following steps:
if the load of the target processor is greater than the third threshold, the service distributor determines an alternative processor of the target processor, the target performance value of the alternative processor is different from the target performance value of the target processor by a fourth threshold, and the target performance of the alternative processor or the target processor is the optimal performance of the target processor; and the service distributor inputs the data to be processed into the alternative processor for processing.
2. The method of claim 1, wherein prior to the traffic distributor receiving the pending data, further comprising:
the service distributor sets corresponding relations between the plurality of service types and the plurality of processors according to the performance difference of the plurality of processors and the processing requirements of data of the plurality of service types in advance;
the service distributor determines a target processor adapted to the target service type, including:
and the service distributor searches a target processor corresponding to the target service type.
3. The method of claim 2, wherein the correspondence between the plurality of traffic types and the plurality of processors comprises:
the voice service type and the video service type correspond to a processor with a processing speed greater than a first threshold value;
controlling the signaling service type to correspond to the processor with the processing accuracy rate larger than a second threshold value; the signaling interacted between the terminal and the base station or the access point belongs to the type of control signaling service;
the text service type corresponds to a processor with a processing speed less than or equal to the first threshold and a processing accuracy less than or equal to the second threshold.
4. A data processing apparatus for use in a traffic distributor of a terminal, the terminal further comprising a plurality of processors having different capabilities, the apparatus comprising:
the receiving unit is used for receiving data to be processed;
the first determining unit is used for determining the type of the target service to which the data to be processed belongs;
a second determining unit, configured to determine a target processor adapted to the target service type;
a judging unit, configured to judge whether a load of the target processor is smaller than a third threshold; the first input unit is used for inputting the data to be processed into the target processor for processing if the load of the target processor is smaller than the third threshold value;
wherein the apparatus further comprises:
a third determining unit, configured to determine, if the load of the target processor is greater than the third threshold, an alternative processor of the target processor, where a target performance value of the alternative processor is different from a target performance value of the target processor by a fourth threshold, and a target performance of the alternative processor or the target processor is an optimal performance of the target processor;
and the second input unit is used for inputting the data to be processed into the alternative processor for processing.
5. The apparatus of claim 4, wherein the apparatus further comprises:
the setting unit is used for setting the corresponding relation between the plurality of service types and the plurality of processors according to the performance difference of the plurality of processors and the processing requirements of the data of the plurality of service types in advance;
the second determining unit is specifically configured to search for a target processor corresponding to the target service type.
6. The apparatus of claim 5, wherein the correspondence between the plurality of traffic types and the plurality of processors comprises:
the voice service type and the video service type correspond to a processor with a processing speed greater than a first threshold value;
controlling the signaling service type to correspond to the processor with the processing accuracy rate larger than a second threshold value;
the text service type corresponds to a processor with a processing speed less than or equal to the first threshold and a processing accuracy less than or equal to the second threshold; and the signaling interacted between the terminal and the base station or the access point belongs to the control signaling service type.
7. A terminal, characterized in that the terminal comprises a service distributor and a plurality of processors, the plurality of processors differing in their capabilities;
the service distributor is used for receiving data to be processed; determining the type of a target service to which the data to be processed belongs; determining a target processor adaptive to the target service type of the data to be processed, and judging whether the load of the target processor is smaller than a third threshold value; if the load of the target processor is smaller than the third threshold value, inputting the data to be processed into the target processor for processing;
the traffic distributor is also arranged to,
if the load of the target processor is larger than the third threshold, determining an alternative processor of the target processor, wherein the target performance value of the alternative processor is different from the target performance value of the target processor by a fourth threshold, and the target performance of the alternative processor or the target processor is the optimal performance of the target processor; and inputting the data to be processed into the alternative processor for processing.
8. A computer storage medium comprising, in combination,
the computer storage medium stores a program that implements the method of any one of claims 1 to 3 when executed by associated hardware.
CN201611265302.7A 2016-12-30 2016-12-30 Data processing method and device Active CN106776039B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611265302.7A CN106776039B (en) 2016-12-30 2016-12-30 Data processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611265302.7A CN106776039B (en) 2016-12-30 2016-12-30 Data processing method and device

Publications (2)

Publication Number Publication Date
CN106776039A CN106776039A (en) 2017-05-31
CN106776039B true CN106776039B (en) 2020-04-03

Family

ID=58951697

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611265302.7A Active CN106776039B (en) 2016-12-30 2016-12-30 Data processing method and device

Country Status (1)

Country Link
CN (1) CN106776039B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108234720B (en) * 2018-01-22 2021-04-02 Oppo广东移动通信有限公司 Electronic device, fall detection method and related product
CN112306010A (en) * 2019-07-31 2021-02-02 北京国双科技有限公司 Data processing method and device
CN110782122B (en) * 2019-09-16 2023-11-24 腾讯大地通途(北京)科技有限公司 Data processing method and device and electronic equipment
CN111176851A (en) * 2020-01-09 2020-05-19 国网福建省电力有限公司 User data analysis method and system for electricity selling side
CN111597042A (en) * 2020-05-11 2020-08-28 Oppo广东移动通信有限公司 Service thread running method and device, storage medium and electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103294554A (en) * 2012-03-05 2013-09-11 中兴通讯股份有限公司 SOC multiprocessor dispatching method and apparatus
CN103617088A (en) * 2013-11-29 2014-03-05 深圳中微电科技有限公司 Method, device and processor of device for distributing core resources in different types of threads of processor
CN104536831A (en) * 2015-01-12 2015-04-22 北京神舟航天软件技术有限公司 Multi-core SoC software mapping method based on multi-objective optimization
CN104679586A (en) * 2013-10-31 2015-06-03 三星电子株式会社 Electronic systems including heterogeneous multi-core processors and method of operating same

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103294554A (en) * 2012-03-05 2013-09-11 中兴通讯股份有限公司 SOC multiprocessor dispatching method and apparatus
CN104679586A (en) * 2013-10-31 2015-06-03 三星电子株式会社 Electronic systems including heterogeneous multi-core processors and method of operating same
CN103617088A (en) * 2013-11-29 2014-03-05 深圳中微电科技有限公司 Method, device and processor of device for distributing core resources in different types of threads of processor
CN104536831A (en) * 2015-01-12 2015-04-22 北京神舟航天软件技术有限公司 Multi-core SoC software mapping method based on multi-objective optimization

Also Published As

Publication number Publication date
CN106776039A (en) 2017-05-31

Similar Documents

Publication Publication Date Title
CN106776039B (en) Data processing method and device
CN104540176B (en) Wireless network access method, device and terminal
CN104699218A (en) Task management method and equipment
US9451391B1 (en) Wireless device pairing management
EP4258741A3 (en) Address coordination method, device, base station, smf network element and storage medium
CN102774321A (en) Vehicle-mounted system and sound control method thereof
US10051443B2 (en) Trunking communication service processing method, core network device, UE and storage medium
CN109376062B (en) Network state prompting method and related device
CN105262881A (en) Communication control method and electronic equipment
CN104702534A (en) Method and device for processing data of multi-process sharing port
US20160255614A1 (en) Network Device, Terminal Device, and Voice Service Control Method
CN102333280A (en) Business secret key renewing method and system and business processing server
CN104052801B (en) A kind of information processing method and electronic equipment
CN105867921A (en) Wallpaper shared use method and terminal
CN111475230B (en) Application function configuration method and device and electronic equipment
KR101669267B1 (en) A method and a system for establishing a communication channel between a predetermined number of selected devices and a device and a server arranged for use in the system
CN103713946A (en) Operating instruction dispatching method and device
CN107124353B (en) Message processing method and device, computer device and storage medium
CN111918019B (en) Video conference method and system, and computer readable storage medium
CN104572264A (en) Application running control method and mobile terminal equipment
CN104243587A (en) Load balancing method and system for message servers
US20170163791A1 (en) Method and device for message prompting
CN110808051B (en) Skill selection method and related device
US11082826B2 (en) Emergency communication method and apparatus
CN103905295A (en) Information transmission method and electronic device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 523860 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong

Applicant after: OPPO Guangdong Mobile Communications Co., Ltd.

Address before: 523860 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong

Applicant before: Guangdong OPPO Mobile Communications Co., Ltd.

GR01 Patent grant
GR01 Patent grant