Get Latest Computer/IT Projects directly to your Email ID


Energy Optimization in Android Applications Through Wakelock Placement (Computer Project)

ABSTRACT:

Energy efficiency is a critical factor in mobile systems, and a significant body of recent research efforts has focused on reducing the energy dissipation in mobile hardware and applications.

The Android OS Power Manager provides programming interface routines called wakelocks for controlling the activation state of devices on a mobile system. An appropriate placement of wakelock acquire and release functions in the application can make a significant difference to the energy consumption

In this paper, we propose a data flow analysis based strategy for determining the placement of wakelock statements corresponding to the uses of devices in an application. Our experimental evaluation on a set of Android applications show significant (up to 32%) energy savings with the proposed optimization strategy.

 SNIPPETS:

Illustrative Examples:

It shows the flow graph of an illustrative example with four Basic Blocks, defined as maximal sequence of instructions that can be entered at the first statement and exited at the last. The wakelock for a device is acquired in BB0, and released after use in BB2.

Wakelock Placement Impacts Energy Efficiency.

Wakelock Placement Impacts Energy Efficiency.

Optimization Strategy:

We outline a Data Flow Analysis formulation for keeping track of the USEs of devices/resources, and deriving the best placements of the wakelock ACQUIRE and RELEASE statements in the code, with the objective of minimizing the energy wasted due to resources being unnecessarily kept active.

A. Data Flow Analysis:

Consider a flow graph representing an application with N basic blocks labeled. We assume that estimates are available for power consumption of resources when they are on, and the expected execution durations of each instruction.

Local Data Flow Analysis within a Basic Block.

Local Data Flow Analysis within a Basic Block.

Data Flow Analysis (a) Forward Propagation from Predecessors (b) Backward Propagation from Successors (c) Forward Propagation within Basic Block (d) Backward Prop- agation within Basic Bloc

Data Flow Analysis (a) Forward Propagation from Predecessors (b) Backward Propagation from Successors (c) Forward Propagation within Basic Block (d) Backward Prop- agation within Basic Block.

B. Wakelock Placement:

Following the data flow analysis, the next step is to insert the wakelock ACQUIRE and RELEASE statements in the appropriate places in the code.
Wakelock Placement after Data Flow Analysis.

Wakelock Placement after Data Flow Analysis.

EXPERIMENTAL EVALUATION:

We conducted experiments to evaluate the effectiveness of our proposed power optimization strategy. We used PowerTutor, an application that estimates the energy consumption for Android applications, using a power model based on the HTC Dream phone.

Figure 5 gives a comparison of the energy consumption by the unoptimized and optimized versions of the applications, with the energy of the unoptimized application treated as 100%. The 100% corresponds to absolute values for the energy ranging from 80mJ to 458J. The applications were executed for durations ranging from 2 to 11 minutes in our experiments. We observe energy reductions between 8% and 32% as a result of applying the optimizations.

Fig. 5: Optimization Results for Different Apps.

Fig. 5: Optimization Results for Different Apps.

CONCLUSIONS:

We addressed the issue of energy optimization in mobile applications by carefully controlling the placement of wakelock statements that are responsible for the acquisition and release of devices. We outlined a data flow analysis formulation for determining the exact placement of wakelock statements corresponding to all the uses of devices in an application.

Energy dissipation is reduced by ensuring that devices are maintained in active state only for the necessary duration. Our experiments on a set of applications indicate an overall energy reduction of up to 32% when the optimization is applied. Future research includes the investigation of a closer co-ordination between the application, compiler, and operating system on energy efficiency issues.

Source: Indian Institute of Technology
Authors: Faisal Alam | Preeti Ranjan Panda | Nikhil Tripathi | Namita Sharma | Sanjiv Narayan

Download Project

Subscribe for Computer/IT Project Downloads (Free):

Enter your email address:  

Discuss this Project:

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>