Appscope: Application Energy Metering Framework for Android Smartphones Using Kernel Activity Monitoring

Appscope: Application Energy Metering Framework for Android Smartphones Using Kernel Activity Monitoring

AppScope: Application Energy Metering Framework for Android Smartphones using Kernel Activity Monitoring Chanmin Yoon, Dongwon Kim, Wonwoo Jung, Chulkoo Kang, Hojung Cha Dept. of Computer Science, Yonsei University, Korea {cmyoon,dkim010,wwjung,ckkang,hjcha}@cs.yonsei.ac.kr Abstract models are lacking in terms of granularity and accuracy. An example of a previous system is PowerScope [6], Understanding the energy consumption of a smartphone which provided the energy consumption of applications application is a key area of interest for end users, as well at a fine-grained level, but required post-processing as application and system software developers. Previous using an external device. The developer also needs to work has only been able to provide limited information import related APIs for energy metering. PowerTutor [7, concerning the energy consumption of individual ap- 8] proposed an estimation method for hardware com- plications because of limited access to underlying ponents, but the system does not provide energy infor- hardware and system software. The energy consumption mation for each application or process. PowerProf [9] of a smartphone application is, therefore, often estimated required information on the API usage for each applica- with low accuracy and granularity. In this paper, we tion in order to estimate energy consumption. The limi- propose AppScope, an Android-based energy metering tations of the above mentioned models are the result of system. This system monitors application’s hardware schemes that focus on the accuracy of the power model usage at the kernel level and accurately estimates energy but do not consider the actual usage of the hardware consumption. AppScope is implemented as a kernel component. Accurate estimation of an application’s module and uses an event-driven monitoring method energy consumption depends on the accuracy of the that generates low overhead and provides high accuracy. power model and the accuracy of a hardware compo- The evaluation results indicate that AppScope accurately nent’s usage statistics. In particular, the hardware usage estimates the energy consumption of Android applica- estimation is critical because it is a pre-requisite for tions expending approximately 35mW and 2.1% in estimating the energy consumption of smartphone ap- power consumption and CPU utilization overhead, re- plications. spectively. Usage estimation for hardware components has been previously completed using hardware performance 1 Introduction counter (HPC) [5, 10-13], software performance counter (SPC) such as the Linux procfs/sysfs [7, 14-16], or Bat- With the widespread use of smartphone applications, the teryStats, which is provided by Android [8, 17]. How- energy consumption of each application is important ever, depending on the process or underlying hardware information that is used to manage a device’s power. components, these approaches provide different infor- Smartphone users can adaptively select energy-efficient mation. Thus, obtaining accurate usage statistics for applications based on the energy consumption of an each hardware component is limited by this feature. application. Additionally, understanding the energy In this paper, we propose a software scheme, called consumption of each process or hardware component is AppScope. This scheme automatically estimates the a key area of interest for application and system software energy consumption of applications running on Android developers [1-5]. smartphones. The proposed system accurately estimates Estimating the energy consumption of a smartphone the usage (or utilization) statistics for each device application is practically difficult. The estimation sys- component. We have designed the scheme based on tem should be able to determine the power usage of monitoring the Android kernel at a microscopic level. In various hardware components in the device. However, order to estimate the usage statistics of each application, this information is difficult to acquire because of com- the system analyzes the traces of a system call, as well as plicated hardware schematics and compact form factor. the messages for Android binder inter-process commu- An accurate power model for hardware components nication (IPC). AppScope collects usage information should be available to determine the level of energy based on an event-driven approach; hence, the energy consumption for each component. consumption of each application is estimated at a fi- Previous work has addressed various energy metering ne-grained level. Additionally, the proposed approach is methods for smartphones [6-9]. However, these earlier applicable for any Android-based device, without mod- energy consumed by process . is expressed with , ification of system software, because we implemented and , where and represent the usage vector the scheme using a dynamic module in the Linux kernel. and active duration of hardware component accessed The contributions of our work are as follows: by process , respectively. Note that the accuracy of is influenced by , , and . To estimate the energy AppScope provides the energy consumption of consumption of smartphone applications, it is essential Android applications automatically, being custom- to obtain accurate values of , , and in an effective ized to the underlying system software and the way. Note that AppScope employs a linear model to hardware components in the device. estimate the energy consumption of smartphones. AppScope accurately estimates, in real-time, the 2.2 DevScope usage of hardware components at a microscopic level. Previous studies on linear power modeling for mobile devices [7, 14, 15] used external power measurement to We implemented AppScope as a loadable kernel profile for each device type. In practice, varies, module to improve portability of the proposed ap- even on the same type of device, depending on hardware, proach. Thus, AppScope can be used on an An- software configuration, and battery status [16, 19]. droid-based device without modifying the system Typically, these values are directly obtained with software. hardware measurements for target devices; hence, this offline method is costly and hardly adaptive to changing 2 Backgrounds environments. The limitation of the offline method can possibly be The accuracy of application energy metering and gran- overcome by using an online approach that employs a ularity of measurement depend on power and energy battery monitoring unit (BMU) [16, 19], which is built in models. In this section, we discuss the models and to smartphones. The scheme would enable the imple- briefly discuss DevScope, which provides a nonintrusive, mentation of an online power model that automatically online power analysis of smartphone hardware compo- constructs a power model for each device, adapting to nents. changes of external factors, such as aging or software updates. However, in order to employ a BMU as an 2.1 Power and Energy Models online power measurement tool, we must consider two factors that are inherent in the properties of BMU. First, Depending on the power interdependencies among un- the information update rate of a BMU is noticeably derlying hardware components, power models are typi- lower than external measurement tools; hence the online cally classified into a linear or a non-linear regression results may not be accurate. Second, since the user is not model. The non-linear models often capture power de- able to intervene in the process of constructing a model, pendency among hardware components, although their it is difficult to understand the exact relationship be- performance does not significantly outperform linear tween system activities and power consumption. models [18]. We only consider linear models in this DevScope [19], an Android application, is an auto- paper. matic and online tool used to generate a power model for With a linear model, the power consumption P of a smartphones. The tool probes operating systems to ob- device is expressed as follows: tain information about individual component types and ( ) (1), their configurations. Additionally, by monitoring the update activity of BMU, DevScope detects the update Here, represents the vector of usage measurement rate automatically. According to individual component for hardware component and the power coefficient types, system configuration, and BMU update rates, for component . Also, is the base power con- DevScope dynamically creates a control scenario for sumption, and is a noise term that cannot be estimated each hardware component to perform power analysis. by the model. Then, the total energy consumption of a Hence, even though a device (i.e., smartphone) is iden- smartphone is expressed as: tical, the scenario might be different due to each device’s ∑ ( ) where configuration. The scenario assigns a workload to each component, which then triggers every possible power ∑ ( ) (2) state of the component; for example, specific operations for CPU, display brightness, GPS on/off, and packet Here, is the device’s power-up duration. is the transmission for cellular and WiFi. Each workload is maintained for a time period to collect enough meas- Table 1: Power model for smartphone components urement samples (i.e., 5 samples) to overcome the limi- Component Model tation of BMU’s low update rate. DevScope turns off 퐶푃푈 퐶푃푈 푖푑푙푒 every other component, except for the component under 푃 훽푓푟푒푞 푢 훽푓푟푒푞 measurement. However, since the CPU should be alive CPU u: utilization, 0 ≤ 푢 ≤ 100 to measure the power consumption

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    14 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us