The present invention relates to hardware management, and more particularly, to a method for referring to an application scenario to manage a hardware component of an electronic device and an associated non-transitory machine-readable medium.
In the current design, a modulator-demodulator (modem) of a wireless communication device (e.g., a cellular phone) supports many low-power tricks to reduce its power consumption. However, it is not easy to implement the power reduction function without penalty introduced. For example, network traffic is monitored by the modem to determine whether to enable the power reduction function. Since no upper layer information is involved in controlling enablement of the power reduction function of the modem, the overall system performance may be degraded.
Thus, there is a need for an innovative hardware management design which can help the modem to apply these low-power tricks more aggressively.
One of the objectives of the claimed invention is to provide a method for referring to an application scenario to manage a hardware component of an electronic device and an associated non-transitory machine-readable medium.
According to a first aspect of the present invention, an exemplary hardware management method is disclosed. The exemplary hardware management method includes: checking an application on an electronic device to categorize a scenario of the application into a pre-defined application scenario, and during a period in which the application is running on the electronic device, managing a hardware component of the electronic device in response to the pre-defined application scenario.
According to a second aspect of the present invention, an exemplary non-transitory machine-readable medium is disclosed. The exemplary non-transitory machine-readable medium stores a program code that, when executed by a processing circuit, causes the processing circuit to perform following steps: checking an application on an electronic device to categorize a scenario of the application into a pre-defined application scenario, and during a period in which the application is running on the electronic device, managing a hardware component of the electronic device in response to the pre-defined application scenario.
These and other objectives of the present invention will no doubt become obvious to those of ordinary skill in the art after reading the following detailed description of the preferred embodiment that is illustrated in the various figures and drawings.
Certain terms are used throughout the following description and claims, which refer to particular components. As one skilled in the art will appreciate, electronic equipment manufacturers may refer to a component by different names. This document does not intend to distinguish between components that differ in name but not in function. In the following description and in the claims, the terms “include” and “comprise” are used in an open-ended fashion, and thus should be interpreted to mean “include, but not limited to . . . ”. Also, the term “couple” is intended to mean either an indirect or direct electrical connection. Accordingly, if one device is coupled to another device, that connection may be through a direct electrical connection, or through an indirect electrical connection via other devices and connections.
Regarding the application scenario categorization at step 202, the program code PROG may detect a user interface (UI) behavior of the application APP running on the electronic device 100. For example, foreground UI type (e.g., web view or list view) and/or foreground UI event (e.g., input method) may be checked by the program code PROG to determine whether the application APP running on the electronic device 100 is operating under a low throughput scenario or a high throughput scenario. In a case where the scenario of the application APP is categorized into the low throughput scenario, it can imply that the APP may only need the modem 110 to provide a low network throughput. In another case where the scenario of the application APP is categorized into the high throughput scenario, it can imply that the APP may need the modem 110 to provide a high network throughput.
In a streaming case, the program code PROG may check a video codec (coder and decoder), a streaming status, and/or a video buffer status. For example, when the video codec is in operation, the streaming is idle, and the video buffer is full, it can imply that the video codec may directly read video data from the video buffer for decoding and then output decoded frames to the display panel 106. At this moment, the modem 110 does not need to receive the video data from a streaming source, such that the network throughput of the modem 110 is low. Hence, the program code PROG may judge that the application APP running on the electronic device 100 is operating under a low throughput scenario.
In an instant messaging case, the program code PROG may judge that the application APP running on the electronic device 100 is operating under a low throughput scenario when the application APP adopts a list view which groups several items and displays them in a vertical scrollable list on the UI. At this moment, the modem 110 does not need to receive the video data from a streaming source, such that the network throughput of the modem 110 is low.
In another instant messaging case, the program code PROG may judge that the application APP running on the electronic device 100 is operating under a high throughput scenario when the application APP adopts a surface view for live streaming. At this moment, the modem 110 needs to receive the video data from a streaming source, such that the network throughput of the modem 110 is high.
In a browser case, the program code PROG may judge that the application APP running on the electronic device 100 is operating under a low throughput scenario when the application APP adopts a web view for displaying a completely loaded web content. At this moment, the modem 110 does not need to receive the video data from a web server, such that the network throughput of the modem 110 is low.
It should be noted that the scenario of the application APP may vary, depending upon a current function enabled by the application APP running on the electronic device 100. That is, when a first function of the application APP running on the electronic device 100 is enabled by the user, the program code PROG may judge that the application APP is operating under one pre-defined application scenario, and when a second function of the application APP running on the electronic device 100 is enabled by the user, the program code PROG may judge that the application APP is operating under another pre-defined application scenario. For example, considering a case where the application APP is a social media application, the scenario of the application APP running on the electronic device 100 may be categorized into a low throughput scenario when the user is using a messaging function of the application APP, and may be categorized into a low latency scenario when the user is using a video call function of the application APP.
Furthermore, in some embodiments of the present invention, a game application may be treated as a low latency application that operates under a low latency scenario, and a non-game application may be treated as a non-low latency application that operates under a non-low latency scenario. Hence, with regard to certain applications, a type of an application may also imply a scenario of the application running on an application processor. To put it another way, an application scenario may be determined through detecting an application type.
Regarding the application scenario categorization at step 202, the program code PROG may detect if the application APP is a low latency application, such as a game application. For example, static information of the application APP and/or dynamic information of the application APP may be checked to determine if the application APP is a low latency application, where the static information of the application APP is fixed during runtime of the application APP, and dynamic information of the application APP is not fixed during runtime of the application APP.
At step 304, the program code PROG may check package information of the application (e.g., application APP). At step 306, the program code PROG may refer to the package information of the application (e.g., application APP) to determine if the application (e.g., application APP) is a low latency application, such as a game application. For example, when the application (e.g., application APP) has a package name with a keyword “game” or “tmgp”, the scenario of the application (e.g., application APP) can be categorized into a low latency scenario (Step 316) because “game” or “tmgp” may imply the application is a game application. For example, when the application (e.g., application APP) has an activity name with a keyword “game”, the scenario of the application (e.g., application APP) can be categorized into a low latency scenario (Step 316) because “game” may imply the application is a game application. For yet another example, when a manifest Extensible Markup Language (XML) file of the application (e.g., application APP) records a flag “isGame”, a game identifier (ID) and/or an application category that is set by “game”, the scenario of the application (e.g., application APP) can be categorized into a low latency scenario (Step 316) because “isGame” or “game” may imply the application is a game application.
If the package information of the application (e.g., application APP) does not hint that the application (e.g., application APP) is a low latency application, the flow proceeds with step 308. At step 308, the program code PROG may refer to the pre-defined resource usage of the application (e.g., application APP) to determine if the application (e.g., application APP) is a low latency application. For example, when a manifest XML file of the application (e.g., application APP) records that the application is written with a game engine or a game library, the scenario of the application (e.g., application APP) can be categorized into a low latency scenario because the application may be a game application (Step 316).
If the pre-defined resource usage of the application (e.g., application APP) does not hint that the application (e.g., application APP) is a low latency application, the flow proceeds with step 312. At step 312, the program code PROG may refer to the registry key information of the application (e.g., application APP) to determine if the application (e.g., application APP) is a low latency application. When the registry key information is indicative of a low latency application, the scenario of the application (e.g., application APP) can be categorized into a low latency scenario (Step 316). When the registry key information is not indicative of a low latency application, the scenario of the application (e.g., application APP) can be categorized into a non-low latency scenario (Step 318).
At step 404, the program code PROG may check at least one of static information of the new application screen/activity, GPU usage, a run status of a game engine, and a status of network socket connection. That is, the dynamic information of the currently running application (e.g., application APP) may include static information of the new application screen/activity and/or application resource usage change. At step 406, the program code PROG may refer to the dynamic information of the currently running application (e.g., application APP) to determine if the currently running application (e.g., application APP) is a low latency application, such as a game application. When the dynamic information of the currently running application (e.g., application APP) indicates that the currently running application (e.g., application APP) is a low latency application, the scenario of the currently running application (e.g., application APP) can be categorized into a low latency scenario (Step 408). When the dynamic information of the currently running application (e.g., application APP) does not indicate that the currently running application (e.g., application APP) is a low latency application, the scenario of the currently running application (e.g., application APP) can be categorized into a non-low latency scenario (Step 410).
In one exemplary design, the application scenario categorization at step 202 shown in
After the scenario of the application APP is categorized into a pre-defined application scenario at step 202, the application scenario categorization result can be referenced for managing a hardware component of the electronic device 100 at step 204. In a first exemplary design, power consumption of the hardware component can be managed in response to the pre-defined application scenario. For example, the hardware component may be the modem 110, and power consumption of the modem 110 can be reduced under a condition that the scenario of the application APP is categorized into the low throughput scenario. For another example, the hardware component may be the display panel 106, and power consumption of the display panel 106 can be reduced under a condition that the scenario of the application APP is categorized into the low throughput scenario.
In a second exemplary design, computing power of the hardware component can be managed in response to the pre-defined application scenario. For example, the hardware component may be the CPU 112, and computing power of the CPU 112 can be enhanced under a condition that the scenario of the application APP is categorized into the low latency scenario (e.g. gaming scenario). For another example, the hardware component may be the GPU 114, and computing power of the GPU 114 can be enhanced under a condition that the scenario of the application APP is categorized into the low latency scenario (e.g. gaming scenario).
In a third exemplary design, video shading offered by the hardware component can be managed in response to the pre-defined application scenario. For example, video shading offered by the hardware component may be enhanced under some application scenarios that require high visual quality.
In a fourth exemplary design, audio quality offered by the hardware component can be managed in response to the pre-defined application scenario. For example, the hardware component may be the audio processor 108, and audio quality offered by the audio processor 108 can be lowered under some application scenarios that do not need high quality audio playback.
It should be noted that the above are for illustrative purposes only, and are not meant to be limitations of the present invention. In practice, an electronic device may use an application scenario categorization result to manage a hardware component for achieving other purpose. These alternative designs all fall within the scope of the present invention.
Those skilled in the art will readily observe that numerous modifications and alterations of the device and method may be made while retaining the teachings of the invention. Accordingly, the above disclosure should be construed as limited only by the metes and bounds of the appended claims.
This application claims the benefit of U.S. provisional application No. 62/937,831, filed on Dec. 20, 2019 and incorporated herein by reference.
Number | Date | Country | |
---|---|---|---|
62937831 | Nov 2019 | US |