A frequency modulation method, system and terminal based on resource scheduling

Through the frequency modulation method of resource scheduling, the problem of long loading time of browser applications caused by low DDR frequency is solved, and the resource frequency is automatically adjusted, which improves system performance and user experience.

CN118690096BActive Publication Date: 2024-11-22深圳开鸿数字产业发展有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411187433.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-28
Publication Date
2024-11-22
Estimated Expiration
2044-08-28

AI Technical Summary

Technical Problem

In the prior art, the low frequency of DDR leads to the problem that the browser application page and resource loading time is too long.

Method used

By receiving the event number sent by the browser component, analyzing and generating event information, controlling the frequency modulation service component to subscribe to events, obtaining configuration files, and updating the frequency according to event processing parameters, to realize the frequency modulation function of resource scheduling.

Benefits of technology

It improves the overall performance of browser applications, shortens page and resource loading time, ensures system performance and power consumption balance, and improves the user experience of developers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118690096B_ABST
    Figure CN118690096B_ABST
Patent Text Reader

Abstract

The present invention discloses a frequency modulation method, system and terminal based on resource scheduling, the method comprising: receiving an event number sent by a browser component, and sending it to a resource scheduling component for processing, to obtain event information; controlling a frequency modulation service component to subscribe to an event, and sending the corresponding event information to the frequency modulation service component for processing, to obtain event processing parameters; obtaining a configuration file of the event, analyzing the configuration file and the corresponding event processing parameters, to obtain adjustment information, and updating the frequency in the corresponding configuration file according to the adjustment information. The present invention processes and analyzes the monitored events through an event processing function, and generates a frequency modulation file for frequency adjustment, thereby automatically adjusting the frequency of each resource according to the business scenario, ensuring the performance and power consumption balance of the system, and improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of resource scheduling and frequency modulation, and in particular to a frequency modulation method, system, terminal and computer-readable storage medium based on resource scheduling. Background Art

[0002] Currently, since it takes too long for users to load pages and resources using browser applications, it is necessary to optimize browser performance and improve user experience.

[0003] From the perspective of resource scheduling, the increase in DDR (Double Data Rate) frequency is positively correlated with the user experience of using the browser. When the DDR frequency is high, the memory can read and write data faster, thereby improving the overall performance of the application; when the DDR frequency is low, the memory read and write speed is slow, resulting in longer page and resource loading time in the browser application, and the DDR frequency modulation function needs to be implemented in resource scheduling.

[0004] Therefore, the prior art still needs to be improved and developed. Summary of the invention

[0005] The main purpose of the present invention is to provide a frequency modulation method, system, terminal and computer-readable storage medium based on resource scheduling, aiming to solve the problem in the prior art that the DDR frequency is too low, resulting in a long application page and resource loading time when the user uses the browser.

[0006] To achieve the above object, the present invention provides a frequency modulation method based on resource scheduling, and the frequency modulation method based on resource scheduling comprises the following steps:

[0007] Receive multiple event numbers of multiple events sent by the browser component, send the multiple event numbers to the resource scheduling component through a callback function, and receive multiple event information sent by the resource scheduling component, the event information is generated by the resource scheduling component after analyzing the multiple event numbers;

[0008] Control the frequency modulation service component to subscribe to each of the events, and send the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, so as to obtain a plurality of event processing parameters;

[0009] A configuration file of each of the events is obtained, each of the configuration files and the corresponding event processing parameters are analyzed to obtain a plurality of adjustment information, and the frequency in the corresponding configuration file is updated according to the plurality of adjustment information.

[0010] Optionally, the frequency modulation method based on resource scheduling, wherein the receiving multiple event numbers of the multiple events sent by the browser component, sending the multiple event numbers to the resource scheduling component through a callback function, and receiving multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing the multiple event numbers, specifically includes:

[0011] Receiving multiple click instructions input by a user, and triggering multiple focus events and / or multiple out-of-focus events of the browser component through the multiple click instructions;

[0012] Receiving a plurality of first event numbers corresponding to the plurality of focus events and / or a plurality of second event numbers corresponding to the plurality of out-of-focus events sent by the browser component, wherein the first event numbers and / or the second event numbers are generated by the browser component according to the focus events;

[0013] Report all the focus events and / or all the out-of-focus events to the resource scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receive multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing multiple first event numbers and / or multiple second event numbers.

[0014] Optionally, in the frequency modulation method based on resource scheduling, the event information includes: first event information and second event information, wherein the first event information includes: a first event name, a first event state and a first event type, and the second event information includes a second event name, a second event state and a second event type;

[0015] The reporting all the focus events and / or all the out-of-focus events to the resource scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receiving multiple event information sent by the resource scheduling component, specifically includes:

[0016] Receiving a plurality of first event names sent by the browser component, wherein the first event name is generated by the browser component according to the first event number and / or the second event number;

[0017] According to all the first event names, report all the focus events and / or all the out-of-focus events to the source scheduling component, so as to send all the first event numbers and / or all the second event numbers to the resource scheduling component;

[0018] Receive multiple second event names, multiple second event states and multiple second event types sent by the resource scheduling component, wherein the second event state and the second event type are generated by the resource scheduling component by analyzing the first event number and / or the second event number.

[0019] Optionally, the frequency modulation method based on resource scheduling, wherein the receiving of multiple second event names, multiple second event states and multiple second event types sent by the resource scheduling component further includes:

[0020] Acquire a plurality of the second event states and a plurality of the second event types sent by the browser component;

[0021] Comparing each of the first event names with the corresponding second event names, each of the first event states with the corresponding second event states, and each of the first event types with the corresponding second event types;

[0022] If there is a mismatch between the first event name and the corresponding second event name, the first event state and the corresponding second event state, or the first event type and the corresponding second event type, an early warning message is generated, and the resource scheduling component is controlled to regenerate multiple second event names, multiple second event states, or multiple second event types.

[0023] Optionally, the frequency modulation method based on resource scheduling, wherein the control frequency modulation service component subscribes to each of the events, sends the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, and obtains multiple event processing parameters, specifically including:

[0024] Control the frequency modulation service component to subscribe to each of the focus events and / or each of the out-of-focus events;

[0025] Sending the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events to the frequency modulation service component for analysis to obtain an information analysis result;

[0026] A plurality of event processing parameters sent by the frequency modulation service component are received, wherein the event processing parameters are generated by the frequency modulation service component by analyzing the information analysis result through an information processing function.

[0027] Optionally, the frequency modulation method based on resource scheduling, wherein the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events are sent to the frequency modulation service component for analysis to obtain an information analysis result, and then further includes:

[0028] Obtaining a plurality of configuration files for each of the focus events and / or each of the out-of-focus events stored in a remote load component;

[0029] Uploading all the configuration files to the frequency modulation service component, and comparing them with the corresponding first event information and / or second event information;

[0030] If the configuration file does not match the corresponding first event information or second event information, the frequency modulation service component is stopped.

[0031] Optionally, the frequency modulation method based on resource scheduling, wherein the acquiring of the configuration file of each of the events, analyzing each of the configuration files and the corresponding event processing parameters to obtain a plurality of adjustment information, and updating the frequency in the corresponding configuration file according to the plurality of adjustment information, specifically comprises:

[0032] Obtaining a plurality of configuration files for each of the focus events and / or each of the out-of-focus events;

[0033] Analyze each of the configuration files and the corresponding first event number and / or second event number to obtain adjustment information corresponding to each of the focus events and / or each of the out-of-focus events;

[0034] According to each of the adjustment information, the corresponding frequency in the configuration file of each of the focus events and / or each of the out-of-focus events is updated.

[0035] In addition, to achieve the above-mentioned purpose, the present invention further provides a frequency modulation system based on resource scheduling, wherein the frequency modulation system based on resource scheduling includes:

[0036] An event information generation module, used for receiving multiple event numbers of multiple events sent by the browser component, sending the multiple event numbers to the resource scheduling component through a callback function, and receiving multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component analyzing the event numbers;

[0037] An event processing parameter generation module, used to control the frequency modulation service component to subscribe to each of the events, and send the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, so as to obtain a plurality of event processing parameters;

[0038] The frequency adjustment module is used to obtain a configuration file of each event, analyze each configuration file and the corresponding event processing parameter, obtain a plurality of adjustment information, and update the frequency in the corresponding configuration file according to the plurality of adjustment information.

[0039] In addition, to achieve the above-mentioned purpose, the present invention also provides a terminal, wherein the terminal includes: a memory, a processor, and a frequency modulation program based on resource scheduling stored in the memory and executable on the processor, and when the frequency modulation program based on resource scheduling is executed by the processor, the steps of the frequency modulation method based on resource scheduling as described above are implemented.

[0040] In addition, to achieve the above-mentioned purpose, the present invention also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a frequency modulation program based on resource scheduling, and when the frequency modulation program based on resource scheduling is executed by a processor, the steps of the frequency modulation method based on resource scheduling as described above are implemented.

[0041] In the present invention, multiple event numbers of multiple events sent by the browser component are received, multiple event numbers are sent to the resource scheduling component through a callback function, and multiple event information sent by the resource scheduling component is received, and the event information is generated by the resource scheduling component after analyzing the multiple event numbers; the frequency modulation service component is controlled to subscribe to each of the events, and the event information corresponding to each subscribed event is sent to the frequency modulation service component for processing, and multiple event processing parameters are obtained; the configuration file of each event is obtained, and each configuration file and the corresponding event processing parameters are analyzed to obtain multiple adjustment information, and the frequency in the corresponding configuration file is updated according to the multiple adjustment information. The present invention processes and analyzes the monitored events through the event processing function, and generates a frequency modulation file for frequency adjustment, thereby automatically adjusting the frequency of each resource according to the business scenario, ensuring the performance and power consumption balance of the system, only needing to call business-related components in development, without the need to care about the operation of the underlying system, improving the efficiency of system maintenance by developers, and significantly improving the use experience of developers. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] Figure 1 It is a flow chart of a preferred embodiment of the frequency modulation method based on resource scheduling of the present invention;

[0043] Figure 2 It is a flow chart of a preferred embodiment of the frequency modulation method based on resource scheduling of the present invention;

[0044] Figure 3 It is a schematic diagram of event distribution of a preferred embodiment of the frequency modulation method based on resource scheduling of the present invention;

[0045] Figure 4 It is a schematic diagram of a frequency modulation mechanism of a preferred embodiment of a frequency modulation method based on resource scheduling of the present invention;

[0046] Figure 5 It is a schematic diagram of the principle of a preferred embodiment of a frequency modulation system based on resource scheduling of the present invention;

[0047] Figure 6 Schematic diagram of the operating environment of a preferred embodiment of the terminal of the present invention. DETAILED DESCRIPTION

[0048] In order to make the purpose, technical solution and advantages of the present invention clearer and more specific, the present invention is further described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0049] The frequency modulation method based on resource scheduling described in the preferred embodiment of the present invention is as follows: Figure 1 As shown, the frequency modulation method based on resource scheduling includes the following steps:

[0050] Step S10, receiving multiple event numbers of multiple events sent by the browser component, sending the multiple event numbers to the resource scheduling component through the callback function, and receiving multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing the multiple event numbers.

[0051] Among them, Figure 2 As shown, when a user opens an application, the browser component obtains a focus event, and when a user closes an application, the browser component obtains a loss of focus event. Then, the focus event or loss of focus event triggers a browser component callback and sends the event information to the resource scheduling component.

[0052] Specifically, multiple click instructions input by the user are received, and multiple focus events and / or multiple out-of-focus events of the browser component are triggered by the multiple click instructions; multiple first event numbers corresponding to the multiple focus events and / or multiple second event numbers corresponding to the multiple out-of-focus events sent by the browser component are received, wherein the first event number and / or the second event number are generated by the browser component according to the focus event; all the focus events and / or all the out-of-focus events are reported to the resource scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and multiple event information sent by the resource scheduling component is received, wherein the event information is generated by the resource scheduling component after analyzing the multiple first event numbers and / or the multiple second event numbers.

[0053] Among them, different event trigger callbacks are implemented through different interfaces. For example, the callback of the focus event can be "voID WebClientImpl::OnFocus()", and the callback of the out-of-focus event can be "voID WebDelegate::OnBlur()". Different event numbers are obtained according to different event types, and reported through the external call interface provided by the resource scheduling component. Its interface declaration can be "voID ResSchedReport::ResSchedDataReport(constchar* name, const std::unordered_map<std::string, std::string> ¶m)", where the parameter "name" corresponds to the string name of the event, and the parameter "param" is used to store the string name corresponding to the event.

[0054] For example, the method used by the callback for reporting focus events is:

[0055] "voID WebClientImpl::OnFocus()

[0056] {

[0057] ContainerScope scope(instanceID_);

[0058] auto delegate = webDelegate_.Upgrade();

[0059] if (!delegate) {

[0060] return;

[0061] }

[0062] delegate->OnRequestFocus();

[0063] delegate->RequestFocus();

[0064] LOGI("web focus event report");

[0065] ResSchedReport::GetInstance().ResSchedDataReport("web_focus");

[0066] }";

[0067] The method used by the callback to report the out-of-focus event:

[0068] "voID WebDelegate::OnBlur()

[0069] {

[0070] ACE_DCHECK(nweb_ != nullptr);

[0071] if (nweb_) {

[0072] nweb_->OnBlur(blurReason_);

[0073] LOGI("web unfocus event report");

[0074] ResSchedReport::GetInstance().ResSchedDataReport("web_unfocus");

[0075] }

[0076] }".

[0077] The event information includes: first event information and second event information, wherein the first event information includes: a first event name, a first event status and a first event type, and the second event information includes a second event name, a second event status and a second event type.

[0078] Further, multiple first event names sent by the browser component are received, wherein the first event names are generated by the browser component based on the first event number and / or the second event number; based on all the first event names, all the focus events and / or all the out-of-focus events are reported to the source scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component; multiple second event names, multiple second event states and multiple second event types are received from the resource scheduling component, wherein the second event state and the second event type are generated by the resource scheduling component analyzing the first event number and / or the second event number.

[0079] The resource scheduling component analyzes the event type, event status, event name and other information corresponding to each event according to the event number of each event. For example, the interface declaration "void ResSchedClient::Report(uint32_t resType, int64_t value, const std::unordered_map<std::string, std::string> &mapPayload)", where "resType" indicates the integer parameter corresponding to the event type, "value" indicates the integer parameter corresponding to the event status, and "mapPayload" is used to store the string name, application name, process and thread ID of the application corresponding to the event. Different choices are made according to different event types to achieve different frequency modulation standards, which enables automatic adjustment of the frequency of each resource in the business scenario, ensures the balance between system performance and power consumption, and helps improve the user experience.

[0080] Furthermore, multiple second event states and multiple second event types sent by the browser component are obtained; each first event name and the corresponding second event name, each first event state and the corresponding second event state, and each first event type and the corresponding second event type are compared; if there is a mismatch between the first event name and the corresponding second event name, the first event state and the corresponding second event state, or the first event type and the corresponding second event type, an early warning message is generated, and the resource scheduling component is controlled to regenerate multiple second event names, multiple second event states, or multiple second event types.

[0081] Among them, for the same application, there are two event numbers, corresponding to two different event information. If for the click instruction of the same application, if the first event name and the second event name do not match, the first event status and the second event status or the first event type or the second event type does not match, then an early warning message is generated to prompt the user that there is a problem with the current program and the current application cannot be closed. The current application needs to be closed again to control the resource scheduling component to regenerate the corresponding second event name, second event status and second event type.

[0082] Step S20: Control the frequency modulation service component to subscribe to each of the events, and send the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, to obtain a plurality of event processing parameters.

[0083] Among them, the control frequency modulation service component subscribes to all out-of-focus events and focus events, so as to select different plug-ins according to the event type. For different events, frequency modulation can be performed simultaneously or for a single event. This can be achieved by adding a new processing interface: "void SocPerfPlugin::HandleWebFocus(const std::shared_ptr <resdata>&data)", where "data" is used to store the event type, event status and event name.

[0084] Furthermore, the event structure can be expressed as:

[0085] "enum : uint32_t {

[0086] / / web window focus event; value 0: focused, 1: unfocused.

[0087] RES_TYPE_WEB_FOCUS = 35,

[0088] }";

[0089] The character names corresponding to the events are:

[0090] "static const std::map<uint32_t, std::string> resTypeToStr = {

[0091] { RES_TYPE_WEB_FOCUS, "WEB_FOCUS"},

[0092] }";

[0093] The event status is:

[0094] " / **

[0095] * @brief Web focus Status

[0096] * /

[0097] enum WebFocuscsStatus : int64_t {

[0098] WEB_FOCUS_BEGIN = 0,

[0099] WEB_FOCUS_END = 1,

[0100] }".

[0101] Specifically, the FM service component is controlled to subscribe to each of the focus events and / or each of the out-of-focus events; the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events are sent to the FM service component for analysis to obtain information analysis results; and a plurality of event processing parameters sent by the FM service component are received, wherein the event processing parameters are generated by the FM service component by analyzing the information analysis results through an information processing function.

[0102] For example, you can subscribe to events via:

[0103] " / / event

[0104] constexpr uint32_t RES_TYPE_WEB_FOCUS = 35;

[0105] / / status

[0106] constexpr int32_t WEB_FOCUS_EVENT = 0;

[0107] constexpr int32_t WEB_UNFOCUS_EVENT = 1;

[0108] / / string

[0109] constexpr char WEB_FOCUS[] = "web_focus";

[0110] constexpr char WEB_UNFOCUS[] = "web_unfocus";".

[0111] Among them, Figure 3 As shown, the frequency modulation service component obtains the relevant information of each focus event and / or out-of-focus event and analyzes it to determine the specific details of frequency modulation for the relevant focus event or out-of-focus event, and finally obtains the event processing parameters and distributes them to the SOC (System-on-a-Chip) unified frequency modulation service to realize frequency modulation processing.

[0112] Furthermore, multiple configuration files for each of the focus events and / or each of the out-of-focus events stored in the remote load component are obtained; all of the configuration files are uploaded to the frequency modulation service component and compared with the corresponding first event information and / or second event information; if there is a mismatch between the configuration file and the corresponding first event information or second event information, the frequency modulation service component is stopped.

[0113] For example, you can upload relevant data through the following code:

[0114] "void ResSchedReport::ResSchedDataReport(const char* name, conststd::unordered_map<std::string, std::string> ¶m)

[0115] {

[0116] functionMap = {

[0117] { WEB_FOCUS,

[0118] [this](std::unordered_map<std::string, std::string> &payload) {

[0119] reportDataFunc_(RES_TYPE_WEB_FOCUS, WEB_FOCUS_EVENT, payload);

[0120] }

[0121] },

[0122] { WEB_UNFOCUS,

[0123] [this](std::unordered_map<std::string, std::string> &payload) {

[0124] reportDataFunc_(RES_TYPE_WEB_FOCUS, WEB_UNFOCUS_EVENT, payload);

[0125] }

[0126] },

[0127] };".

[0128] Among them, after analyzing the event processing parameters of each focus event and / or out-of-focus event, a corresponding configuration file is generated, and the configuration file can be used for information comparison of each event before frequency modulation processing, which can avoid frequency modulation processing of wrong events, thereby causing program errors and affecting the user experience, and improving the security of resource adjustment while ensuring resource adjustment efficiency.

[0129] Step S30: Obtain a configuration file for each of the events, analyze each of the configuration files and the corresponding event processing parameters, obtain a plurality of adjustment information, and update the frequency in the corresponding configuration file according to the plurality of adjustment information.

[0130] Among them, after obtaining the configuration file of each event, it is also necessary to subscribe to each event, determine the adjustment information of each event according to the event processing parameters corresponding to the configuration file, and then update the frequency in the configuration file to meet the needs of users.

[0131] For example, the definition of subscribing to an event can be:

[0132] "namespace {

[0133] const int32_t PERF_REQUEST_CMD_ID_WEB_FOCUS = 10020;

[0134] }";

[0135] "void SocPerfPlugin::Init()

[0136] {

[0137] functionMap = {

[0138] { RES_TYPE_WEB_FOCUS,

[0139] [this](const std::shared_ptr <resdata>&data) {HandleWebFocus(data);}},

[0140] };

[0141] resTypes = { ......

[0143] RES_TYPE_WEB_FOCUS,

[0144] };

[0145] }".

[0146] Specifically, multiple configuration files for each of the focus events and / or each of the out-of-focus events are obtained; each of the configuration files and the corresponding first event number and / or the second event number are analyzed to obtain adjustment information corresponding to each of the focus events and / or each of the out-of-focus events; and according to each of the adjustment information, the corresponding frequency in the configuration file of each of the focus events and / or each of the out-of-focus events is updated.

[0147] Among them, the frequency-raising mechanism of the SOC unified frequency modulation service is applied through DDR (Double Data Rate, a memory technology), and the frequency modulation interface includes two types: "PerfRequest" and "PerfRequestEx", among which, "PerfRequest" can only handle events of one state, and the interface declaration is: "void SocPerf::PerfRequest(int32_t cmdId,const std::string&msg)", where "cmdId" represents the command prompt ID corresponding to the event, which needs to be consistent with the configuration file, and "msg" represents the process where the application is located and the ID of the process; and "PerfRequestEx" can handle events with two states, and the interface declaration is: "void SocPerf::PerfRequestEx(int32_t cmdId, boolonOffTag, const std::string&msg)", where "onOffTag" represents the state of the corresponding event. If it is "1", it means that the current event is a focus event, and if it is "0", it means that the current event is an out-of-focus event.

[0148] Among them, Figure 4 As shown, after obtaining the adjustment information, the event processing function is used to update the corresponding frequency in each event configuration file, and the specific definition of the event processing function can be:

[0149] "void SocPerfPlugin::HandleWebFocus(const std::shared_ptr <resdata>&data)

[0150] {

[0151] if (data == nullptr) {

[0152] return;

[0153] }

[0154] if (data->value == WebFocuscsStatus::WEB_FOCUS_BEGIN) {

[0155] RESSCHED_LOGI("SocPerfPlugin: socperf->WEB_FOCUS: %{public}lld", (long long)data->value);

[0156] OHOS::SOCPERF::SocPerfClient::GetInstance().PerfRequestEx(PERF_REQUEST_CMD_ID_WEB_FOCUS, true, "");

[0157] } else if (data->value == WebFocuscsStatus::WEB_FOCUS_END) {

[0158] RESSCHED_LOGI("SocPerfPlugin: socperf->WEB_UNFOCUS: %{public}lld", (long long)data->value);

[0159] OHOS::SOCPERF::SocPerfClient::GetInstance().PerfRequestEx(PERF_REQUEST_CMD_ID_WEB_FOCUS, false, "");

[0160] }

[0161] }”。

[0162] Furthermore, the changes to the configuration files can be queried by searching for the "dmc_opp_table" command, and the changes to the configuration files can include two configuration files: "socperf_resource_config.xml" and "socperf_boost_config.xml", where the specific content of "socperf_resource_config.xml" is:

[0163] " <res id="3000" name="lit_ddr_min_freq" pair="3001">

[0164] <default> 324000000< / default>

[0165] <path> / sys / class / devfreq / dmc / min_freq< / path>

[0166] <node> 324000000 528000000 780000000 1560000000< / node>

[0167] < / res>

[0168] <res id="3001" name="lit_ddr_max_freq" pair="3000" mode="1">

[0169] <default> 1560000000< / default>

[0170] <path> / sys / class / devfreq / dmc / max_freq< / path>

[0171] <node> 324000000 528000000 780000000 1560000000< / node>

[0172] < / res> ”;

[0173] The specific content of "socperf_boost_config.xml" is:

[0174] " <cmd id="10022" name="web_focus">

[0175] <action>

[0176] <duration> 0< / duration>

[0177] <lit_ddr_min_freq>1560000000< / lit_ddr_min_freq>

[0178] < / action>

[0179] < / cmd> ”.

[0180] The present invention processes and analyzes monitored events through event processing functions, and generates frequency modulation files for frequency regulation, thereby automatically adjusting the frequency of each resource according to the business scenario, ensuring the balance between system performance and power consumption. It only needs to call business-related components during development without affecting the operation of the underlying system, which improves the efficiency of developers in maintaining the system and significantly improves the developer's user experience.

[0181] Furthermore, if Figure 5 As shown, based on the above frequency modulation method based on resource scheduling, the present invention also provides a frequency modulation system based on resource scheduling, wherein the frequency modulation system based on resource scheduling includes:

[0182] An event information generating module 51 is used to receive multiple event numbers of multiple events sent by the browser component, send the multiple event numbers to the resource scheduling component through a callback function, and receive multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component analyzing the event numbers;

[0183] An event processing parameter generating module 52 is used to control the frequency modulation service component to subscribe to each of the events, and send the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, so as to obtain a plurality of event processing parameters;

[0184] The frequency adjustment module 53 is used to obtain the configuration file of each event, analyze each configuration file and the corresponding event processing parameter, obtain multiple adjustment information, and update the frequency in the corresponding configuration file according to the multiple adjustment information.

[0185] Furthermore, if Figure 6 As shown, based on the above-mentioned frequency modulation method and system based on resource scheduling, the present invention also provides a terminal accordingly, and the terminal includes a processor 10, a memory 20 and a display 30. Figure 6 Only some components of the terminal are shown, but it should be understood that it is not required to implement all of the components shown, and more or fewer components may be implemented instead.

[0186] In some embodiments, the memory 20 may be an internal storage unit of the terminal, such as a hard disk or memory of the terminal. In other embodiments, the memory 20 may also be an external storage device of the terminal, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (SecureDigital, SD) card, a flash card (Flash Card), etc. equipped on the terminal. Further, the memory 20 may also include both an internal storage unit of the terminal and an external storage device. The memory 20 is used to store application software and various types of data installed on the terminal, such as the program code of the installation terminal. The memory 20 may also be used to temporarily store data that has been output or is to be output. In one embodiment, a frequency modulation program 40 based on resource scheduling is stored on the memory 20, and the frequency modulation program 40 based on resource scheduling can be executed by the processor 10, thereby realizing the frequency modulation method based on resource scheduling in the present application.

[0187] In some embodiments, the processor 10 may be a central processing unit (CPU), a microprocessor or other data processing chip, used to run the program code or process data stored in the memory 20, such as executing the frequency modulation method based on resource scheduling.

[0188] In some embodiments, the display 30 may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, etc. The display 30 is used to display information on the terminal and to display a visual user interface. The components 10-30 of the terminal communicate with each other via a system bus.

[0189] In one embodiment, when the processor 10 executes the frequency modulation program 40 based on resource scheduling in the memory 20, the following steps are implemented:

[0190] Receive multiple event numbers of multiple events sent by the browser component, send the multiple event numbers to the resource scheduling component through a callback function, and receive multiple event information sent by the resource scheduling component, the event information is generated by the resource scheduling component after analyzing the multiple event numbers;

[0191] Control the frequency modulation service component to subscribe to each of the events, and send the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, so as to obtain a plurality of event processing parameters;

[0192] A configuration file of each of the events is obtained, each of the configuration files and the corresponding event processing parameters are analyzed to obtain a plurality of adjustment information, and the frequency in the corresponding configuration file is updated according to the plurality of adjustment information.

[0193] The receiving of multiple event numbers of multiple events sent by the browser component, sending the multiple event numbers to the resource scheduling component through a callback function, and receiving multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing the multiple event numbers, specifically includes:

[0194] Receiving multiple click instructions input by a user, and triggering multiple focus events and / or multiple out-of-focus events of the browser component through the multiple click instructions;

[0195] Receiving a plurality of first event numbers corresponding to the plurality of focus events and / or a plurality of second event numbers corresponding to the plurality of out-of-focus events sent by the browser component, wherein the first event numbers and / or the second event numbers are generated by the browser component according to the focus events;

[0196] Report all the focus events and / or all the out-of-focus events to the resource scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receive multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing multiple first event numbers and / or multiple second event numbers.

[0197] The event information includes: first event information and second event information, wherein the first event information includes: a first event name, a first event state and a first event type, and the second event information includes a second event name, a second event state and a second event type;

[0198] The reporting all the focus events and / or all the out-of-focus events to the resource scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receiving multiple event information sent by the resource scheduling component, specifically includes:

[0199] Receiving a plurality of first event names sent by the browser component, wherein the first event name is generated by the browser component according to the first event number and / or the second event number;

[0200] According to all the first event names, report all the focus events and / or all the out-of-focus events to the source scheduling component, so as to send all the first event numbers and / or all the second event numbers to the resource scheduling component;

[0201] Receive multiple second event names, multiple second event states and multiple second event types sent by the resource scheduling component, wherein the second event state and the second event type are generated by the resource scheduling component by analyzing the first event number and / or the second event number.

[0202] The receiving of a plurality of second event names, a plurality of second event states, and a plurality of second event types sent by the resource scheduling component further includes:

[0203] Acquire a plurality of the second event states and a plurality of the second event types sent by the browser component;

[0204] Comparing each of the first event names with the corresponding second event names, each of the first event states with the corresponding second event states, and each of the first event types with the corresponding second event types;

[0205] If there is a mismatch between the first event name and the corresponding second event name, the first event state and the corresponding second event state, or the first event type and the corresponding second event type, an early warning message is generated, and the resource scheduling component is controlled to regenerate multiple second event names, multiple second event states, or multiple second event types.

[0206] The control frequency modulation service component subscribes to each of the events, and sends the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, to obtain multiple event processing parameters, specifically including:

[0207] Control the frequency modulation service component to subscribe to each of the focus events and / or each of the out-of-focus events;

[0208] Sending the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events to the frequency modulation service component for analysis to obtain an information analysis result;

[0209] A plurality of event processing parameters sent by the frequency modulation service component are received, wherein the event processing parameters are generated by the frequency modulation service component by analyzing the information analysis result through an information processing function.

[0210] The sending of the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events to the frequency modulation service component for analysis to obtain an information analysis result further includes:

[0211] Obtaining a plurality of configuration files for each of the focus events and / or each of the out-of-focus events stored in a remote load component;

[0212] Uploading all the configuration files to the frequency modulation service component, and comparing them with the corresponding first event information and / or second event information;

[0213] If the configuration file does not match the corresponding first event information or second event information, the frequency modulation service component is stopped.

[0214] The acquiring of the configuration file of each event, analyzing each configuration file and the corresponding event processing parameter to obtain a plurality of adjustment information, and updating the frequency in the corresponding configuration file according to the plurality of adjustment information specifically includes:

[0215] Obtaining a plurality of configuration files for each of the focus events and / or each of the out-of-focus events;

[0216] Analyze each of the configuration files and the corresponding first event number and / or second event number to obtain adjustment information corresponding to each of the focus events and / or each of the out-of-focus events;

[0217] According to each of the adjustment information, the corresponding frequency in the configuration file of each of the focus events and / or each of the out-of-focus events is updated.

[0218] The present invention also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a frequency modulation program based on resource scheduling, and when the frequency modulation program based on resource scheduling is executed by a processor, the steps of the frequency modulation method based on resource scheduling as described above are implemented.

[0219] In summary, the present invention provides a frequency modulation method based on resource scheduling and related equipment, the method comprising: receiving multiple event numbers of multiple events sent by a browser component, sending the multiple event numbers to a resource scheduling component through a callback function, and receiving multiple event information sent by the resource scheduling component, the event information is generated by the resource scheduling component after analyzing the multiple event numbers; controlling the frequency modulation service component to subscribe to each of the events, sending the event information corresponding to each subscribed event to the frequency modulation service component for processing, and obtaining multiple event processing parameters; obtaining the configuration file of each event, analyzing each configuration file and the corresponding event processing parameters, obtaining multiple adjustment information, and updating the frequency in the corresponding configuration file according to the multiple adjustment information. The present invention processes and analyzes the monitored events through an event processing function, and generates a frequency modulation file for frequency adjustment, thereby automatically adjusting the frequency of each resource according to the business scenario, ensuring the performance and power consumption balance of the system, only needing to call business-related components during development, without the need to care about the operation of the underlying system, improving the efficiency of system maintenance by developers, and significantly improving the use experience of developers.

[0220] It should be noted that, in this article, the term "includes", "comprising" or any other variation thereof is intended to cover non-exclusive inclusion, so that a process, method, article or terminal including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the existence of other identical elements in the process, method, article or terminal including the element.

[0221] Of course, those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing related hardware (such as a processor, a terminal, etc.) through a computer program, and the program can be stored in a computer-readable storage medium that can be read by a computer, and the program can include the processes of the above-mentioned method embodiments when executed. The computer-readable storage medium can be a memory, a disk, an optical disk, etc.

[0222] It should be understood that the application of the present invention is not limited to the above examples. For ordinary technicians in this field, improvements or changes can be made based on the above description. All these improvements and changes should fall within the scope of protection of the claims attached to the present invention.< / resdata> < / resdata> < / resdata>

Claims

1. A frequency modulation method based on resource scheduling, characterized in that: The frequency modulation method based on resource scheduling includes: Receive multiple event numbers of multiple events sent by the browser component, send the multiple event numbers to the resource scheduling component through a callback function, and receive multiple event information sent by the resource scheduling component, the event information is generated by the resource scheduling component after analyzing the multiple event numbers; The receiving of multiple event numbers of multiple events sent by the browser component, sending the multiple event numbers to the resource scheduling component through a callback function, and receiving multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing the multiple event numbers, specifically includes: Receiving multiple click instructions input by a user, and triggering multiple focus events and / or multiple out-of-focus events of the browser component through the multiple click instructions; Implement different event trigger callbacks through different interfaces; Receiving a plurality of first event numbers corresponding to the plurality of focus events and / or a plurality of second event numbers corresponding to the plurality of out-of-focus events sent by the browser component, wherein the first event numbers and / or the second event numbers are generated by the browser component according to the focus events; Reporting all the focus events and / or all the out-of-focus events to the resource scheduling component, so as to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receiving a plurality of event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing a plurality of the first event numbers and / or a plurality of the second event numbers; The event information includes: first event information and second event information, wherein the first event information includes: a first event name, a first event state and a first event type, and the second event information includes a second event name, a second event state and a second event type; The reporting all the focus events and / or all the out-of-focus events to the resource scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receiving multiple event information sent by the resource scheduling component, specifically includes: Receiving a plurality of first event names sent by the browser component, wherein the first event name is generated by the browser component according to the first event number and / or the second event number; According to all the first event names, report all the focus events and / or all the out-of-focus events to the source scheduling component, so as to send all the first event numbers and / or all the second event numbers to the resource scheduling component; receiving a plurality of second event names, a plurality of second event states, and a plurality of second event types sent by the resource scheduling component, wherein the second event state and the second event type are generated by the resource scheduling component analyzing the first event number and / or the second event number; Control the frequency modulation service component to subscribe to each of the events, and send the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, so as to obtain a plurality of event processing parameters; The control frequency modulation service component subscribes to each of the events, and sends the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, to obtain multiple event processing parameters, specifically including: Select different plug-ins according to different event types, and tune different events or a single event at the same time; Control the frequency modulation service component to subscribe to each of the focus events and / or each of the out-of-focus events; Sending the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events to the frequency modulation service component for analysis to obtain an information analysis result; Receiving a plurality of event processing parameters sent by the frequency modulation service component, wherein the event processing parameters are generated by the frequency modulation service component by analyzing the information analysis result through an information processing function; Obtaining a configuration file for each of the events, analyzing each of the configuration files and the corresponding event processing parameters to obtain a plurality of adjustment information, and updating the frequency in the corresponding configuration file according to the plurality of adjustment information; The obtaining of the configuration file of each event, analyzing each configuration file and the corresponding event processing parameter to obtain a plurality of adjustment information, and updating the frequency in the corresponding configuration file according to the plurality of adjustment information specifically includes: Obtaining a plurality of configuration files for each of the focus events and / or each of the out-of-focus events; Analyze each of the configuration files and the corresponding first event number and / or second event number to obtain adjustment information corresponding to each of the focus events and / or each of the out-of-focus events; According to each of the adjustment information, updating a corresponding frequency in a configuration file of each of the focus events and / or each of the out-of-focus events; Query the updated configuration file by searching the preset command.

2. The frequency modulation method based on resource scheduling according to claim 1, characterized in that: The receiving of a plurality of second event names, a plurality of second event states, and a plurality of second event types sent by the resource scheduling component further includes: Acquire a plurality of the second event states and a plurality of the second event types sent by the browser component; Comparing each of the first event names with the corresponding second event names, each of the first event states with the corresponding second event states, and each of the first event types with the corresponding second event types; If there is a mismatch between the first event name and the corresponding second event name, the first event state and the corresponding second event state, or the first event type and the corresponding second event type, an early warning message is generated, and the resource scheduling component is controlled to regenerate multiple second event names, multiple second event states, or multiple second event types.

3. The frequency modulation method based on resource scheduling according to claim 1, characterized in that: The sending of the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events to the frequency modulation service component for analysis to obtain an information analysis result further includes: Obtaining a plurality of configuration files for each of the focus events and / or each of the out-of-focus events stored in a remote load component; Uploading all the configuration files to the frequency modulation service component, and comparing them with the corresponding first event information and / or second event information; If the configuration file does not match the corresponding first event information or second event information, the frequency modulation service component is stopped.

4. A frequency modulation system based on resource scheduling, characterized in that: The frequency modulation system based on resource scheduling includes: An event information generation module, used for receiving multiple event numbers of multiple events sent by the browser component, sending the multiple event numbers to the resource scheduling component through a callback function, and receiving multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component analyzing the event numbers; The receiving of multiple event numbers of multiple events sent by the browser component, sending the multiple event numbers to the resource scheduling component through a callback function, and receiving multiple event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing the multiple event numbers, specifically includes: Receiving multiple click instructions input by a user, and triggering multiple focus events and / or multiple out-of-focus events of the browser component through the multiple click instructions; Implement different event trigger callbacks through different interfaces; Receiving a plurality of first event numbers corresponding to the plurality of focus events and / or a plurality of second event numbers corresponding to the plurality of out-of-focus events sent by the browser component, wherein the first event numbers and / or the second event numbers are generated by the browser component according to the focus events; Reporting all the focus events and / or all the out-of-focus events to the resource scheduling component, so as to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receiving a plurality of event information sent by the resource scheduling component, wherein the event information is generated by the resource scheduling component after analyzing a plurality of the first event numbers and / or a plurality of the second event numbers; The event information includes: first event information and second event information, wherein the first event information includes: a first event name, a first event state and a first event type, and the second event information includes a second event name, a second event state and a second event type; The reporting all the focus events and / or all the out-of-focus events to the resource scheduling component to send all the first event numbers and / or all the second event numbers to the resource scheduling component, and receiving multiple event information sent by the resource scheduling component, specifically includes: Receiving a plurality of first event names sent by the browser component, wherein the first event name is generated by the browser component according to the first event number and / or the second event number; According to all the first event names, report all the focus events and / or all the out-of-focus events to the source scheduling component, so as to send all the first event numbers and / or all the second event numbers to the resource scheduling component; receiving a plurality of second event names, a plurality of second event states, and a plurality of second event types sent by the resource scheduling component, wherein the second event state and the second event type are generated by the resource scheduling component analyzing the first event number and / or the second event number; An event processing parameter generation module, used to control the frequency modulation service component to subscribe to each of the events, and send the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, so as to obtain a plurality of event processing parameters; The control frequency modulation service component subscribes to each of the events, and sends the event information corresponding to each of the subscribed events to the frequency modulation service component for processing, to obtain multiple event processing parameters, specifically including: Select different plug-ins according to different event types, and tune different events or a single event at the same time; Control the frequency modulation service component to subscribe to each of the focus events and / or each of the out-of-focus events; Sending the first event information corresponding to each of the focus events and / or the second event information corresponding to each of the out-of-focus events to the frequency modulation service component for analysis to obtain an information analysis result; Receiving a plurality of event processing parameters sent by the frequency modulation service component, wherein the event processing parameters are generated by the frequency modulation service component by analyzing the information analysis result through an information processing function; A frequency adjustment module, used to obtain a configuration file of each event, analyze each configuration file and the corresponding event processing parameter, obtain a plurality of adjustment information, and update the frequency in the corresponding configuration file according to the plurality of adjustment information; The obtaining of the configuration file of each event, analyzing each configuration file and the corresponding event processing parameter to obtain a plurality of adjustment information, and updating the frequency in the corresponding configuration file according to the plurality of adjustment information specifically includes: Obtaining a plurality of configuration files for each of the focus events and / or each of the out-of-focus events; Analyze each of the configuration files and the corresponding first event number and / or second event number to obtain adjustment information corresponding to each of the focus events and / or each of the out-of-focus events; According to each of the adjustment information, updating a corresponding frequency in a configuration file of each of the focus events and / or each of the out-of-focus events; Query the updated configuration file by searching the preset command.

5. A terminal, characterized in that: The terminal includes: a memory, a processor, and a frequency modulation program based on resource scheduling stored in the memory and executable on the processor. When the frequency modulation program based on resource scheduling is executed by the processor, the steps of the frequency modulation method based on resource scheduling are implemented as described in any one of claims 1-3.

6. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a frequency modulation program based on resource scheduling, and when the frequency modulation program based on resource scheduling is executed by a processor, the steps of the frequency modulation method based on resource scheduling are implemented as described in any one of claims 1-3.