This post is an extract of the articles “Automated Selection of Offloadable Tasks for Mobile Computation Offloading in Edge Computing”, presented at Conference on Network and Service Management (CNSM), 2017, Tokyo (Japan) and “Automated Offloading of Android Applications for Computation/Energy-usage Optimizations” presented at IEEE International Conference on Computer Communications (INFOCOM), 2017, Atlanta (USA).

Mobile applications are constantly growing in terms of their functionality and complexity in order to offer a wider set of high-level features that challenge execution time and energy usage. Recent mobile applications such as speech recognition, natural language processing, computer vision and augmented reality applications may require processing power beyond which mobile devices are equipped with or can drain their battery life at an unacceptable pace.

Computation offloading is widely accepted as a powerful concept that can overcome the resource constraints of resource limited devices, that may span from mobile devices to low-power Internet-of-Things devices, by dynamically sending dynamically computation-intensive tasks to remote servers depending on context. It can reduce execution time and energy consumption at the cost of transferring computation-related information.

ULOOF (User Level Online Offloading Framework) has been introduced in order to benefit from computation offloading for Android mobile devices and laverage on edge comptuing and cloud computing to improve the mobile execution.

Several different solutions have been proposed in the past but ULOOF differs from them for different reasons:

  • fully autonomous code selection mechanism with method-level granularity
  • dynamically analyze every kind of Android application and detect the list of methods suitable to be offloaded
  • decoupled and lightweight solution that does not specifically target a powerful remote platform (i.e. cloud computing)
  • and can be used in less-powerful remote servers independently from the available resources (i.e. fog/edge computing)

ULOOF can autonomously scan a generic Android mobile application, without any prior and application-specific knowledge, to autonomously create a new version of the application, which is functionally equivalent, but with the capability to offload computations to a remote server. This is achieved by an automated analysis to detect which methods can be executed on the server consistently and by modifying those methods code, by instrumenting the Android application inserting hooks, to run them remotely in a completely transparent way. The result is then integrated into a new Android application that runs some methods locally on the mobile device and others remotely on the server.

In addition, ULOOF is equipped with a machine learning logic and a smart decision engine to minimize both execution time and energy consumption of mobile Android applications while not requiring any modification in underlying device operating system and by choosing at runtime the best decision. ULOOF objective is to provide offloading functionality to any existing Android application, by inspecting, decompiling and recompiling it.

The modified Android application contains the ULOOf framework which predicts execution time and energy consumption of a mobile computation and measures the potential gain in terms of the two aspects in order to decide whether to offload a certain computation.

uloof architecture

A Virtual Machine (VM), emulating a remote Android device, is called for the remote execution when a local decision engine, exploiting machine learning on the consumed energy and execution time on a per-method level. Additional post-processing tasks on the primitive APK may be run on the VM rather than on the device. Instead of the VM, another Android device (to support device-to-device computation offloading) or bare-metal machine could also be used.

The ULOOF framework consists of a smart decision engine which predicts execution time and energy consumption of a mobile computation. The decision engine measures the potential gain in terms of the two aspects and decide whether to offload a certain computation.

In order to test the whole framework, the complete framework code is accessible at ULOOf on GitHub, where it is possible to retrieve more practical information and a step by step explanation about how to getting started with ULOOF.

Here there is a video about how ULOOF works with an application that simulates the Fibonacci series calculation.