An Adaptive MP3 Player: Reducing Power Consumption and Increasing Application Performance
←
→
Page content transcription
If your browser does not render page correctly, please read the page content below
Proceedings of the 35th Hawaii International Conference on System Sciences - 2002
An Adaptive MP3 Player: Reducing Power Consumption and
Increasing Application Performance
Thomas Kunz and Salim Omar
Systems and Computer Engineering
Carleton University
Ottawa, Canada K1S 5B6
tkunz@sce.carleton.ca
Abstract One group of approaches concentrates on mobile
applications that adapt to the scarce and varying wireless
Cellular and wireless communication, portable link bandwidth by filtering and compressing the data
computers, and satellite services promise to make it stream between a client application on a portable device
possible for mobile users to have access to information and a server executing on a stationary host [1-6]. Data
anywhere and anytime. However, mobile computing is compression in a client-server application is done at one
characterized by many constraints. Any feasible approach of two places. One approach [2,5] enhances the server to
to mobile computing must strike a balance between generate a data stream that is suited for the currently
competing issues. This balance cannot be static as the available bandwidth. Other proposals [1,4,6] extend the
environment of mobile computing changes; it must react, client-server structure to a client-proxy-server structure,
or in other words, the clients must be adaptive. where a proxy executes in the wireless access network,
We propose an approach for adaptive mobile close to the mobile unit. This proxy filters and compresses
applications based on mobile code and report on our the data stream originating from the server to suit the
experience in the context of one resource-intense current wireless bandwidth. This filtering and
application, an MP3 player. The results show that both compression is transparent to the application-layer
increased application performance and reductions in protocol (such as HTTP), but not to the underlying
power consumption are possible under certain conditions transport protocol (such as TCP). In fact, almost all
by shipping the resource-intensive decoding to the less systems follow a "split-TCP" approach, where data is
constraint access network. downloaded completely to the proxy, transcoded there,
and then forwarded to a mobile host.
A second set of approaches provides general solutions
1. Introduction that do not change the TCP semantics [7, 8]. However,
they usually focus on improving TCP throughput, i.e.,
Mobile computing is characterized by many they treat IP packets as opaque. While this addresses
constraints: small, slow, battery-powered portable devices, issues such as high link error rates and spurious
variable and low-bandwidth communication links. These disconnections, it does not address the low bandwidth
constraints are not artifacts of current technology, but are offered by most wireless technologies.
intrinsic to mobility. Together, they complicate the design We propose a third, complementary approach,
of mobile information systems and require rethinking focusing not on the data stream but on the computational
traditional approaches to information access and effort required at the client side. Mobile applications,
application design. Mobility intensifies the tension especially ones that do intensive computation and
between autonomy and interdependency that is communication (such as next-generation multi-medial
characteristic of all distributed systems. Finding PCS and UMTS applications), can be divided
approaches to reduce power consumption and to improve dynamically between the wired network and the mobile
application performance is a vital and interesting problem device according to the mobile environment and to the
to be investigated. Many approaches have been developed availability of the resources on the mobile device, the
to address this problem. They range from hardware to wireless link, and the wired network. The access network
software level approaches. supports the mobile application by providing proxy
Designing applications that adapt to the challenges servers that can execute parts of the application code.
posed by the wireless environment is a hot research area.
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 1
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
With this approach, more windows of adaptability to memory capacity and computational power than laptops,
the mobile environment are possible. In addition, it allows that have more computation power, memory, more
the applications to have dynamic access to faster storage capacity; however; their battery lifetime is shorter
machines through faster servers. This will increase the if we consider typical use of these devices. Designing,
performance of applications and reduce the power implementing and deploying applications that work well
consumption on mobile devices since offloading across all these devices has to address and overcome a
computation to the proxies in the wired network will number of obstacles. The major challenges can be
reduce the CPU cycles and memory needed to achieve categorized as follows:
certain tasks at mobile devices. • Mobility Management and Scalability.
In our work, a mobile application is developed by • Wireless Communication.
composing objects containing functionalities. We call the • Portability.
composition of objects the object graph. A mobile Mobile users establish a connection from potentially
application can have two object graphs. One resides at the many different locations. Wireless connection enables
mobile device, and the other resides at the proxy server. virtual unrestricted mobility and connectivity from any
These graphs change according to the mobile location within the area of radio coverage. Mobility is a
environment and the resources of both devices, similar to new important component in system design. It affects to a
[5,9]. The basic idea here is that the object graph will be certain extent the network level data management as well
reconfigured as needed to adapt to the current execution as the application level. Mobility of clients results in
environment, either at startup or whenever there is a constantly changing topology of the system, calling for
change in the environment. mobility of resources. Location management deals with
This paper demonstrates the feasibility of this idea by mobile clients while configuration management refers to
reporting on our experience with a resource-intensive mobility of resources. In a mobile environment, the
mobile application: an MP3 player. Our implementation location of the user can be considered as a variable whose
uses the concept of mobile code to potentially ship the value changes with every move from one location to
computationally intensive decoding phase from a another. Hence, location becomes a frequently changing
resource-constrained portable device to faster machines in piece of information. While an important problem, the
the fixed infrastructure. The results show that both research reported in this paper does not directly address
increased application performance and reductions in this issue. Some of the issues due to mobility in the
power consumption are possible under certain conditions context of our work are discussed in [10].
by shipping the resource-intensive decoding to the less Mobile computers require wireless network access,
constraint access network. although sometimes they may physically attach to the
The paper is organized as follows. The next section network for a better or a cheaper connection when they
reviews the challenges in mobile computing and Section 3 remain stationary. Wireless communications is much
highlights the most frequently employed strategies to deal more difficult to achieve than wired one because the
with these limitations. Section 4 outlines the architecture surrounding environment interacts with the signal,
of our MP3 player. Section 5 describes a toolkit we blocking signal paths and introducing noise and echoes
developed to support application adaptivity, based on Java. [11]. Wireless connections are of lower quality than wired
The performance improvements and power reductions ones because of these reasons. Lower bandwidths, higher
achievable under certain environment conditions are the error rates, and more frequent spurious disconnection are
topic of Section 6, our findings are summarized and future factors that reduce the quality of wireless
work highlighted in Section 7. communications. These factors can in turn increase
communication latency due to retransmission,
2. Mobile Computing Challenges retransmission timeout delays, error control protocol
processing, and short disconnection. Wireless connection
The rapidly expanding technology of cellular can be lost or degraded also by mobility. Users may step
communication and wireless communication, portable out of the coverage of network transceivers or enter areas
computers, and satellite services promises to make it of high interference. Unlike the typical wired networks,
possible for mobile users to have access to information the number of devices in a cell varies dynamically, and a
anywhere and anytime. Users on a daily basis are using large concentration of mobile users may overload network
portable devices frequently. These types of devices can be capacity as well.
classified primarily by their size, computational power, Mobile application designs need to be more concerned
memory capacity, and power and battery lifetime. For about the bandwidth consumption and constraints than the
example, Personal Digital Assistant devices (PDAs) are fixed computers. Wireless communications deliver lower
small portable computers run on AA batteries. They may bandwidth than wired networks. Wireless links often
be without disk and have more constraints in terms of deliver bandwidths of 10s of kbps, compared to the 10s to
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 2
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
100s of Mbps of typical wired media. Mobile computing The relative resource shortage of mobile elements as
designs also strive to cope with a much greater variation well as their lower trust and robustness argue for reliance
in network bandwidth than the tradition one. Bandwidth on static servers. The need to cope with unreliable and
can shift one to six orders of magnitude between being low-performance networks, as well as the need to be
plugged in versus using wireless access. Fluctuating sensitive to power consumption argues for self-reliance.
traffic load seldom causes this much variation in available Any feasible approach to mobile computing must strike a
bandwidth in fixed networks. balance between these competing issues. This balance
An application can approach this change in bandwidth cannot be static as the environment of mobile computing
in one of the following ways. changes; it must react, or in other words, the clients must
1. It assumes high bandwidth connections and operates be adaptive.
only while plugged in.
2. It assumes low bandwidth connections and does not 3. Related Work
take advantage of existing higher bandwidth.
3. It adapts to currently available resources, providing Application adaptation is a very active research area.
the user with a variable level of quality of service. There are basically two approaches to adaptation:
In our work, we aim to allow applications to exploit application-aware, exemplified by Odyssey; and
high bandwidth when available while reacting application-transparent, as in the Coda File System.
appropriately (and preferably transparent to the user) In Odyssey [13], a monitor is established to monitor
when available bandwidths change drastically. resources such as CPU cycles; bandwidth and battery
Finally, device portability brings with it its own set of power, and to interact with each application to best
challenges. Desktop computer are not expected to be exploit these resources. For example, when high
carried by their users. Their design can consequently bandwidth connectivity is lost due to a radio shadow,
focus on maximum performance with few limitations with Odyssey detects the change and notifies the interested
regard to space, power, and cabling and heat dissipation. applications. Video application, for example, may
The design of portable devices, on the other hand, strives respond by skipping frames, displaying fewer frames per
for properties such as size, weight, durability and long minute, while a Web page client will display degraded
battery life. Any specialized hardware to offload from the versions of large images. This approach towards
CPU tasks such as data compression or encryption should adaptation is characterized as application-aware
justify its consumption of power and in size and weight. adaptation. The essence of this model is a collaboration
Batteries are the largest single source of weight in a effort between the system and the individual applications.
portable computer. While reducing battery weight is The system monitors the resources levels, notifies
important, too small a battery can undermine portability, applications of relevant changes, and enforces resource
requiring the user to charge more frequently. Minimizing allocation decisions. Each application independently
power consumption can improve portability by reducing decides how best to adapt when notified.
battery weight and prolonging the life of a battery. Power Coda [14] is an application-transparent adaptive
can be saved not only by design, but also by efficient use support system. Coda provides clients, particularly mobile
of operations. Power management software can power ones, with highly available access to files. Coda presents
down some individual hardware components when they a single, global namespace to clients organized in
are in idle mode, for example, spinning down the internal volumes, which are sub-trees of the namespace.
disk or turning off screen lighting. Applications can Applications running on Coda clients use the standard
conserve power by reducing computation, communication UNIX file system interface. Desktop applications can
and memory. Since cellular telephone transmission continue to run on mobile clients without modification.
typically requires about ten times as much power as The client cache manager, Venus, is solely responsible for
reception, trading for more receiving can also save power coping with the consequences of mobility. Coda deals
[12]. with the best and worst possible network conditions, and
In conclusion, mobile computing is characterized by it adapts to conditions between these end points. Coda
the previous constraints and challenges. These constraints users can operate clients over Ethernet or other wired
are not a product of current technology, but they are networks, 2 Mb/s radio links, and over modems as slow as
related naturally to mobility. Together, they complicate 9600 baud. As network bandwidth decreases, the
the design of mobile information systems and require importance of reordering or delaying network traffic to
rethinking traditional approaches to information access preserve the illusion of strong connectivity increases. To
and application design. Mobility intensifies the tension preserve the strongly connected illusion, Venus endeavors
between autonomy and interdependency that is to satisfy most demand cache misses as soon as possible,
characteristic of all distributed systems. and delays other traffic as necessary. These decisions are
made at as high level in the system as possible. How to
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 3
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
reschedule network traffic is revisited as available Platform independence was the primary basis for
network quality changes. Adaptive decisions are made in choosing Java as the base for Sumatra. In the design of
three key areas; cache coherence, reintegration, and Sumatra, the Java language was not altered. All added
demand cache fetches. functionality was provided by extending the Java class
As these examples demonstrate, mobile applications library and by modifying the Java interpreter without
need to be capable of responding to time-varying affecting the virtual machine interface. Policy decisions
wireless-QoS and mobile-QoS conditions. Wireless concerning when, where and what to move are left to the
transport and adaptation management systems should application. The high degree of application control allows
therefore be capable of transporting and manipulating programmers to easily explore different policy
content in response to changing mobile network quality of alternatives for resource monitoring and for adapting to
service conditions. Mobile signaling should be capable of variations in resources. An execution engine is the
establishing suitable network support for adaptive mobile abstraction of a location in a distributed environment. It
services. Medium access controllers must be capable of corresponds to an interpreter executing on a host. Sumatra
sharing the wireless link capacity among mobile devices allows object groups to be moved between execution
supporting adaptive quality of service assurances when engines. When an object group is moved, all local
possible. In the following sub-sections, we will explore references to objects in the group (stack references and
the major tools and middleware that support adaptive references from other objects) are converted into proxy
mobile applications. references, which record the new location of the object.
The goal of Comma [15] was to create an architecture Some objects, such as I/O objects, are tightly bound to
and an application programmer interface (API) for local resources and cannot be moved. References to such
adaptive applications. The API provides a simple and objects are reset and must be reinitialized at the new site.
powerful way for application developers to access the The class template for an object (and the associated
information required to easily incorporate adaptive bytecode) can be downloaded into an execution engine on
behavior into their application. It provides easy-to-use application request.
methods to access this information, a wide variety of Sumatra provides a resource-monitoring interface,
operators and ranges available to provide the application which can be used by applications to register monitoring
the information it needs when it needs it, a small library to requests and to determine current values of specific
link with to minimize the overhead placed on the client resources. When an application makes a monitoring
and to minimize the amount of data that needs to be request, Sumatra forwards the request to the local
transferred between the clients and the servers. resource monitor. If the monitor does not support the
The Rover toolkit [5] offers applications a distributed- requested operation, an exception is delivered to the
object system based on the client-server architecture. application.
Clients are Rover applications that typically run on Mobiware [1] provides a set of open programmable
mobile hosts, but could run on stationary hosts as well. CORBA interfaces and objects that abstract and represent
Servers, which may be replicated, typically run on network devices and resources, providing a toolkit for
stationary hosts and hold the long-term state of the programmable signaling, adaptation management and
system. Communication between clients is limited to wireless transport services. Mobiware provides a
peer-to-peer interactions within a mobile host (using the foundation for open programmable mobile networking
local object cache for sharing) and mobile host-server that is suited toward managing the evolving service
interactions; there is no support for remote peer-to-peer or demands of adaptive mobile applications and dealing with
mobile host-mobile host interactions. The Rover toolkit the inherent complexity of delivering scalable audio,
provides mobile communication support based on two video, and real-time services to mobile devices.
ideas: re-locatable dynamic objects (RDOs) and queued Built on an adaptive quality of service API, Mobiware
remote procedure call (QRPC). A re-locatable dynamic consists of a set of controllers that interact with transport,
object is an object with a well-defined interface that can network and medium-access controller distributed objects
be dynamically loaded into a client computer from a that maintain application-specific adaptive quality of
server computer, or vice versa, to reduce client/server service needs. This API is specifically designed to
communication requirements. Queued remote procedure quantitatively address the wireless-QoS and mobile-QoS
call is a communication mechanism that permits needs of adaptive mobile applications. Mobile
applications to continue to make non-blocking remote applications use this API at the transport layer specifying
procedure calls even when a host is disconnected; a utility function that maps the range of observed quality
requests and responses are exchanged upon network to bandwidth. The observed quality index refers to the
reconnection. level of satisfaction perceived by an application at any
Sumatra [16] is an extension of the Java programming moment. The adaptation policy captures the adaptive
environment that supports adaptive mobile programs. nature of mobile applications in terms of a set of
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 4
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
adaptation policies. These policies allow the application for the specific task. In other words, we try first to use
to control how it moves along its utility curve as resource available remote resources to achieve the same task;
availability varies. otherwise, as last resort, we let the application do the
In summary, the adaptation parameters focused on adaptation.
most often are the network states and the mobile device
computation power: bandwidth, the network latency, and 4. MP3 Player
CPU cycles. In the reviewed adaptation approaches, it is
up to the application to the decide how to react to changes We implemented an MP3 player in Java to
to the environment. The reaction could be filtering data, demonstrate the feasibility of our general approach. This
reducing the size of data, entirely changing the content of application requires a powerful CPU to decode the sound
the data, or limiting the computation of specific tasks if due to the complexity of its encoder/decoder algorithm,
necessary. This argues for exporting the network state as which makes it an ideal candidate to demonstrate the need
well as available resources of the mobile device to the for fast static hosts, i.e. proxy servers, to support the
mobile applications to be designed to be adaptive. relative resource-constrained mobile devices.
On the other hand, the automation of adaptation to the CPU time and edge costs (cost of method calls and the
resources was not explored. There are a lot of similarities data volume being transferred between nodes) have been
between our work and the work in Sumatra. Both Sumatra deduced from the call graph that is provided by a toolkit
and our work use extended Java Virtual Machines for called JProbe [17]. This toolkit is basically an
portability and the ease of use of the language especially instrumented JVM that monitors application objects and
for implementing object mobility toolkits. The main the method calls between objects. Tables 1 and 2 contain
difference between our toolkit and the Sumatra toolkit is profiling information regarding nodes and edges in the
that Sumatra entirely leaves the adaptation policy under object graph of the MP3 decoder. This profiling
the control of applications. The applications are fully information was measured on a 350 MHz Pentium II PC.
responsible for moving objects between the mobile device The central object in the implementation is
and the proxy server or reducing the computation of tasks. LayerIII_Decoder, which controls the decode process. As
In other words the reaction to changes in the environment can be deduced from Tables 1 and 2, computationally
is left to the application. heavy objects (such as LayerIII_Decoder, Bit_Reserve,
In our work, adaptation to the change in the resources SynthesisFilter, and temporaire) are not necessarily
and environment is partially left to the toolkit. We try to invoking each other frequently or pass lots of data to each
automate some adaptation policies transparently to other. On the other hand, some lightweight objects
applications. For example, instead of reducing the interact frequently with such CPU-intensive objects.
computation power for a specific task, first we try to Clustering computationally expensive objects for the
move and execute the task remotely at powerful machines purpose of migrating them to a faster server therefore has
to reduce the CPU cycle at the mobile device, which in to take the degree of interaction with other objects into
turn may result in reducing the power consumption at the consideration.
mobile device too. If this adaptation policy costs more,
then we signal the application to reduce the computation
Table 1: Selected objects: Size (in bytes) and average CPU time in milliseconds for decoding 1 MP3 frame
Object Name Object Size Instances Code Size Calls/Frame Avg. CPU Time/Instance
Table43 28 1 107344 620 0.00794
Bit_Reserve 16666 1 1430 3355 0.50058
SBI 223 6 2905 97 0.01926
gr_info_s 376 4 5195 7184 0.06222
temporaire2 376 2 1409 1687 0.00445
Temporaire 593 2 1819 52 0.22175
Header 765 1 9245 11 0.00267
III_side_info_t 959 1 2022 35 0.16715
Ibitstream 1972 1 5301 449 0.29177
huffcodetab 2526 35 45493 693 0.11331
SynthesisFilter 4414 2 18724 4824 0.44725
LayerIII_Decoder 25114 1 47146 160 1.07052
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 5
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
Table 2: Selected edge weights of the object graph
Number of Avg. number of DataIN DataOut Total
Calling Object Called Object
calls/Frame calls/instance/frame /call /call /instance
LayerIII_Decoder SBI 97 16.2 44 44 2231
LayerIII_Decoder gr_info_s 7192 1798 42 42 240932
LayerIII_Decoder temporaire2 429 214.5 50 46 31317
LayerIII_Decoder temporaire 48 24 42 42 3216
LayerIII_Decoder III_side_info_t 10 10 43 42 1350
LayerIII_Decoder Huffcodetab 692 19.8 52 48 2965.714
LayerIII_Decoder SynthesisFilter 144 72 42 40 9504
LayerIII_Decoder Bit_Reserve 587 587 43 43 79832
SynthesisFilter Obuffer 1 1 580 0 630
huffcodetab Bit_Reserve 2768 79.09 42 44 10755.6
LayerIII_Decoder Ibitstream 1 1 0 417 467
LayerIII_Decoder Table43 619 619 44 44 85422
javalayer LayerIII_Decoder 1 1 64 40 154
LayerIII_Decoder Header 14 14 40 44 1876
5. Mobile Code Toolkit • Dynamic object mobility.
The toolkit has a set of APIs, which provide the
The central concept of our framework is the proxy server required functionality for moving objects dynamically.
host. A proxy server is an intermediate device that One instance of the toolkit executes on both the portable
communicates with servers in the Internet using standard device and the proxy. There is not much difference
Internet protocols. The mobile device and the proxy between the structure of the toolkit at the mobile side and
server may communicate through protocols suitable for the proxy side, except that the object migration decision is
wireless connections, such as I-TCP [18] or standard taken at the proxy side since the decision process
TCP. A typical proxy server can be used for the consumes CPU cycles, which would consume power as
following: well. The toolkit contains the following major modules:
• A proxy server can work as a filter receiving data • Mobile/Proxy Device State and Information:
from the Internet and compress received data monitors and delivers the state of the mobile or proxy
according to the need of the mobile device. For device as events to the Object Server. Changes in the
example, color video streams are converted from bandwidth or changes in the power status are
gray color to back-and-white color, the quality of examples of the events that this unit exports.
audio streams can be altered from stereo to mono, or • Code Storage: storage of the validated classes files
the replay sampling frequency can be reduced to (bytecode) at the mobile device. At the request of the
minimize the size of data over the wireless proxy device, the code will be transferred to the
connection. proxy.
• An application can use the resources of the proxy • Object References and Profiling (Object Graph):
server to increase the performance and decrease the contains the representation of the application’s
power consumption by executing selected objects on objects along with the profiling information about
the proxy server. For example, offloading a heavy these objects. These information will be send to the
computation objects such as decoders to a proxy proxy sever to be analyzed and the proxy server will
server may reduce the CPU cycles on the mobile decide which object must be shipped to its side
device, the focus of our work reported here. according to the mobile environment.
In our approach, a mobile application is a composition • Object Server: main core of the toolkit. It runs a
of objects encapsulating functionalities. We call the thread that listens continuously to all the commands
composition of objects the object graph. A mobile from a remote object server. Commands can be
application can have two object graphs. One resides at the related to moving objects or related to the remote
mobile device, and the other resides at the proxy server. invocation of a method on a remote objects.
These graphs change according to the mobile • Remote Method Invocation Protocol: marshal and un-
environment and the resources of both devices. Our marshal a method’s parameters
toolkit is based on Java, and provides the following • Dynamic Decision: analyzes the profiling information
support: of application’s objects. It resides only at the proxy
• Support for information delivery to the application. server. Having decided which objects need to be
• Support to allow an application to react suitably.
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 6
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
executed at the proxy server, it will issue a command Kb/sec, so it does not become a bottleneck. The previous
to the remote object server to download the objects. experiments were repeated with a Windows CE PDA and
• Communication Control Layer: simulates wireless a laptop as client devices. The PDA runs on a RISC
links in terms of the low bandwidth. We chunk the processor of 75 MHz and the laptop runs on a Pentium
data streams being sent through the communication processor of 133 MHz. The proxy server runs on a 350
layer into pre-determined sizes based on the MHz Pentium II PC. The performance of Java
empirical tests. We introduce a controllable amount applications depends primarily on the performance of the
of delay between data chunks which allows us JVM. Both laptop and the proxy server run relatively high
control the throughput dynamically at run time for performance JVMs. The JVM on the PDA, on the other
testing purposes. hand, is very slow, so the relative CPU speed degrades
As mentioned earlier, a mobile computing application considerably. We measured the relative CPU speed
needs to be aware of resource availability and changes in between the PDA, laptop and the proxy and found it to be
the mobile environment. Thus special abstractions must 1:116 and 1:4, respectively. Therefore, while varying
be provided in order to deliver these changes to an bandwidth, the relative CPU speeds are fixed to 1:2 and
application. We model all changes as events, which are 1:116 for a PDA as a client, and 1:4 for a laptop as client.
delivered to objects. Interested objects in an application In the following section, Local Performance and
must define an event handler through which the events, Remote Performance factors are based on decoding 38
such as change in the power state and link bandwidth, can MP3 coded audio frames, with the assumption that output
be handled. Since Java does not support pointer notion, is mono, with sampling rate of 11025 Hz, and 16 bits per
using Java Reflection classes and Interfaces facilitates sample. To predict the achievable performance by
this. executing a set of objects, clustered by GGP, either
Both the state and computation of an application may remotely or locally, a number of equations were derived,
be partitioned between the mobile device and the proxy discussed in detail in [22]. We use these predictions to
server. The degree of partitioning ranges from just explore whether any gains in performance and reductions
executing the user graphic interface to executing the in power consumption can be achieved by offloading any
entire application on the mobile device. We propose to of the clusters derived by our clustering algorithm to the
use a Greedy Graph Partitioning (GGP) algorithm [19] to proxy server. The following tables list the best and worst
identify closely coupled objects. The decision to move results for each scenario for different maximal cluster
such a group of objects can be deferred to run-time, sizes (the maximal cluster size is 56, which groups all
depending on environment factors such as relative CPU objects realizing the MP3 decoder into a single cluster).
speeds and link bandwidth. These tables only provide a select few datapoints,
demonstrating our major findings. In the following tables,
6. Results we use these acronyms:
• BW (Bandwidth)
We executed the MP3 player under various emulated • RCPUS (Relative CPU Speeds) is the relative CPU
environment conditions and observed application speed between the mobile device and the proxy
performance and power consumption on the mobile server.
device. In these experiments, we did not change any of • CS (cluster/page size) is the input into the GGP,
the relevant parameters after the application started. limiting the maximum number of objects in a cluster.
Based on the observed environment, our runtime system Due to the structure of our application, with many
instantiates some objects on the proxy server, others are objects interacting with the central Layer III decoder
created on the mobile device. We studied in particular the object, the GGP algorithm effectively created one
following three parameters: cluster with maximum size for all values of CS,
• Available Bandwidth. leaving other objects in a cluster of their own.
• Relative CPU speeds (Mobile CPU: Proxy CPU). • PS (Partition Size) is the number of objects in a
• Cluster size or page size of the simple GGP. specific cluster/partition.
To observer the importance of the first parameter, the • RTIP (Response Time Improvement Percentage) is
bandwidth available, we choose certain low and high the relative improvement in response time if a
bandwidths. We choose 19.2 Kb/sec to represent CDPD specific partition was executed remotely, compared
[20], a typical wide-area cellular data service. For high to a complete local execution on the mobile device.
bandwidths we choose 1000 Kb/sec to represent the • PCIP (Power Consumption Improvement
bandwidth that can be obtained from Wireless Ethernet Percentage) is the percentage of the power
cards such as WaveLan [21]. consumption reduction in the mobile device.
To observe the importance of the second parameter, • LPerf (Local Performance) and RPerf (Remote
the relative CPU speeds, we fixed the bandwidth to 1000 Performance) are player performance index value
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 7
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
when decoding either locally or remotely. To play an Table 7: Response Time and Power Consumption
MP3 file without any buffering, a value of 100 would for a Laptop, BW = 19.2kb/s, RCPUS = 4.
be required.
The MAX and MIN rows in each table describe the best CS PS RTIP PCIP LPerf RPerf
and worst performance for each possible cluster size. For 1 MIN 1 -242935 -250704 11.73 0.01
example, for a cluster size of 1, each object is individually MAX 1 -255 -263 11.73 3.30
migrated to the proxy, the application performance is MIN 20 -69255 -71469 11.73 0.02
20
measured, and the best and worst cases are reported here.
MAX 1 -255.3 -263 11.73 3.30
30 MIN 30 -43884 -45288 11.73 0.03
Table 3: Response Time and Power Consumption
MAX 1 -255 -263 11.73 3.30
for a PDA, BW = 19.2kb/s, RCPUS = 2.
56 MAX 56 -732 -755 11.73 1.41
CS PS RTIP PCIP LPerf RPerf
1 MIN 1 -51598 -63769 2.49 0.00005 Table 8: Response Time and Power Consumption
MAX 1 -53.35 -65.34 2.49 1.63 for a Laptop, BW = 1000kb/s, RCPUS = 4.
20 MIN 20 -14695 -18151 2.49 0.02
MAX 1 -53.35 -65.34 2.49 1.63 CS PS RTIP PCIP LPerf RPerf
30 MIN 30 -9300 -11479 2.49 0.03 1 MIN 1 -31278.9 -39487.92 78.71 0.25
MAX 1 -53.35 -65.34 2.49 1.63 MAX 1 -31.40 -39.61 78.71 59.90
56 MAX 56 -116.80 -117.54 2.49 1.15
20 MIN 20 -8892.4 -11225.47 78.71 0.88
Table 4: Response Time and Power Consumption MAX 1 -31.41 -39.61 78.71 59.90
for a PDA, BW = 19.2kb/s, RCPUS = 116. 30 MIN 30 -5614.90 -7087.49 78.71 1.38
MAX 1 -31.41 -39.61 78.71 59.90
CS PS RTIP PCIP LPerf RPerf 56 MAX 56 -28.93 -34.73 78.71 61.05
1 MIN 1 -51592 -63769 2.49 0.01
MAX 1 -52.45 -65.34 2.49 1.63
20 MIN 20 -14678 -18151 2.49 0.02
These results demonstrate that available bandwidth is
MAX 1 -52.45 -65.34 2.49 1.63 an important factor. Tables 3 and 4 show that if the
30 MIN 30 -9277 -11479 2.49 0.03 bandwidth is the bottleneck in the system, neither
MAX 1 -52.45 -65.34 2.49 1.63 reduction in power consumption nor increases in MP3
56 MAX 56 -76.72 -117.54 2.49 1.41 player performance can happen, no matter what the
relative CPU speed is. However, if the bandwidth is not
Table 5: Response Time and Power Consumption the bottleneck, then the relative CPU speed becomes a
for a PDA, BW = 1000kb/s, RCPUS = 2. decisive factor in increasing the performance and
decreasing the power consumption at the mobile device.
CS PS RTIP PCIP LPerf RPerf Tables 5 and 6 show that it is possible to save power and
1 MIN 1 -1202 -1563 3.04 0.23 increase performance of the MP3 player if the entire
MAX 1 -0.15 0.58 3.04 3.04 decoder will be executed remotely (cluster size 56) and
20 MIN 20 -324 -408 3.04 0.72 the PDA only works as sound player.
MAX 1 -0.15 0.58 3.04 3.04 The decrease in the power consumption happens when
30 MIN 30 -190 -228 3.04 1.05 the available bandwidth is high. This is because the lower
MAX 1 -0.15 0.58 3.04 3.04 the bandwidth, the longer it takes to transmit data, which
56 MAX 56 46.09 94.62 3.04 5.64 in turn, cause more power consumption. Table 5 and
Table 6 show that with high bandwidths, regardless of the
Table 6: Response Time and Power Consumption relative CPU speed, there is a considerable gain in power
for a PDA, BW = 1000kb/s, RCPUS = 116. consumption.
The computation power of the mobile device is an
CS PS RTIP PCIP LPerf RPerf important factor as well. Tables 7 and 8 show that local
1 MIN 1 -1195 -1563 3.04 0.23 efficiency of the player is always higher than remote
MAX 1 0.95 0.58 3.04 3.07 efficiency even though the available bandwidth in Table 8
20 MIN 20 -304 -408 3.04 0.75 is sufficient to handle the decoded sound and the
MAX 1 0.95 0.58 3.04 3.07 computational power is quit high at the proxy server. This
30 MIN 30 -162 -228 3.04 1.16 argues for the use of many powerful proxies to support a
MAX 1 0.95 0.58 3.04 3.07
huge user population, rather than one centralized proxy
56 MAX 56 95.02 94.62 3.04 61.05
server [23].
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 8
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
These results also show that it is not always beneficial host according to the mobile device and fixed host’s
to start shipping code to gain performance and/or decrease available resources and wireless network state. To support
power consumption. The benefits depend on the graph our approach, we designed and developed a mobile object
topology, the data traffic volume between objects, but toolkit, based on Java. With this toolkit we combine
also the characteristics of the portable device. Tables 5 JVMs on both the proxy server and the mobile device as
and 6 show that there is a considerable decrease in power one virtual machine from the application point of view to
consumption as well as an increase in the performance of dynamically split applications object between JVMs.
the MP3 player when executing on a Windows CE PDA; Through prediction models based on the available
however, Tables 7 and 8 show that it is not worth bandwidth and the relative CPU speeds to estimate power
shipping the MP3 decoder remotely for a laptop. consumption costs and performance costs metrics, we
Tables 3 to 8 are based upon empirically derived determine which of the clusters should be moved to
equations and our own mobile code toolket. To verify our improve one or both of the metrics. The results showed
results for other toolkits, we implemented a version of our that it is possible to simultaneously improve both metrics
MP3 player in Voyager [24], offloading the decoder by dynamically shipping the entire MP3 decoder to the
objects from a laptop to the proxy server (Objectspace proxy server in the case of a slow portable device.
does not provide a Voyager server for Windows CE Although Java as is our primary developing language
PDAs). We measured the efficiency of the player, and for applications as well as for implementing our toolkit,
compared the results with the estimated values in Table 8. Java Virtual Machines are in early stages of development,
The player decodes 38 frames (approximately one second particularly those for the WindowsCE platform. They
to play) and converts the stereo output to mono of need to be extended to export the mobile computing
sampling rate 11025 Hz with 16 bits per sample. Table 9 environment variables, such as available bandwidth,
shows the chosen clusters and the partition numbers, the battery lifetime and power available at the mobile host as
local efficiency, and the remote efficiency when certain well as performance parameters such as CPU utilization.
clusters of objects are moved remotely to the proxy server These extensions require the use of native interfaces,
(using a bandwidth of 1 Mbps). which if not standardized, will prevent the mobile
adaptive application from being portable.
Table 9: Our toolkit vs. Voyager A number of issues need to be addressed in future
work, some of which is currently under way. We are
Cluster working on improving the mobile object toolkit to help
LPerf RPerf
size facilitate the implementation of the adaptive mobile
Our Our application for PDAs in particular. The main
Voyager Voyager improvement to our toolkit addresses the implementation
Toolkit Toolkit
1 76.24 78.71 61.89 59.90 of the RMI protocol, which is based on serialized object
30 76.24 78.71 2.35 1.37 commands between the object servers on both Java
56 76.24 78.71 65.40 61.05 Virtual Machines. Another improvement deals with proxy
objects. To support location-transparent invocation of
The first and third scenario correspond to the best methods, each object is associated with one or more proxy
possible configuration in Table 8 (the MAX row for objects. These proxy objects are always local to an
cluster size 1 and the single entry for cluster size 56), the invoking object and either invoke the requested method
second scenario represents the worst possible locally (if the associated object resides in the same JVM)
configuration (the MIN row) for cluster size 30. The or marshal parameters and contact the remote object
values in Table 9 are close to the values in Table 8. Thus, server to invoke the method remotely. Currently, we
we believe that our findings are equally applicable to manually write these proxy objects; however, we plan to
other mobile code toolkits, certainly as far as general develop tools to automate this process and integrate it
trends are concerned. Detailed performance gains and with the toolkit.
reductions in power consumptions will depend on the A second issue addresses the complete automation of
efficiency of the specific toolkit, however. the dynamic application partitioning decision. Our results
reported here indicate which parameters are important.
7. Conclusions and Future Work What we are currently lacking are ways to monitor live
application executions to build object graphs with
minimal overhead and an algorithm that takes the object
Finding approaches to reduce power consumption and
graph and information about the execution environment to
to improve application performance is a vital and
determine automatically which set of objects to migrate to
interesting problem to be investigated. We suggested a
a proxy server. Once we have such runtime support, we
new approach in which an application’s objects will be
can then also experiment with scenarios where the
split dynamically between the mobile device and fixed
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 9
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEProceedings of the 35th Hawaii International Conference on System Sciences - 2002
execution environment changes drastically while the and Networking, Budapest, Hungary, September 1997, pages
application executes. Intuitively, we would expect the 77-8
runtime system to rebalance the application accordingly. 9. Hokimoto, Kurihara, and Nakajima. An approach for
However, based on previous experience [23], we know constructing mobile applications using service proxies.
Proceedings of the 16th International Conference on Distributed
that shipping objects at runtime is not cheap. So we need Computing Systems, Hong Kong, May 1996, pages 726-733
to explore how to balance the resulting overhead with the 10. Jianwen Wang and Thomas Kunz. A proxy server
anticipated performance gains and power reductions, in infrastructure for adaptive mobile applications. Proceedings of
particular in execution environments that change rapidly. the Eighteenth IASTED International Conference on Applied
Finally, while our results reported here show that there is Informatics, Innsbruck, Austria, February 2000, pages 561-567.
no trade-off between power reduction and performance 11. J. Ioannisdis, D. Duchamp, and G. Magurier Jr. IP-based
improvement, our previous work reported in [25] protocols for mobile internetworking. Proceedings of
indicates that there may well be such trade-offs for other SIGCOMM’91 Symposium, Sept 1991, pages 253-245.
12. G. Forman and J. Zahorjan, The challenges of mobile
applications. In these cases, we need to identify how to
computing, IEEE Computer, April 1994.
balance conflicting objectives. One possible solution 13. B. Noble, M. Satyanarayanan, D. Narayanan, J.E. Tilton, J.
could be to allow the mobile user to select preferences Flinn, K. Walker. Agile application-aware adaptation for
that prioritize objectives. mobility, Proceedings of the 16th ACM Symposium on Operating
A final area of possible future work is the interaction System Principles, October 1997, St. Malo, France
between application-aware and application-transparent 14. M. Satyanarayanan, Mobile information access
adaptation. The MP3 player we implemented does not http://www.cs.cmu.edu/afs/cs.cmu.edu/project/coda//Web/docdi
react to changes in bandwidth, for example by reducing r/ieeepcs95.pdf
sampling size or audio quality. In our experiments, we 15. David Kidston, James P. Black, Thomas Kunz, Michael E.
fixed the output playing rate and the sampling size. Nidd, Marcello Lioy, Brent Elphick, and Michal Ostrowski.
Comma, A communication manager for mobile applications.
Further study is required to show how application Proceedings of the 10th International Conference on Wireless
adaptation policies affect and interact with the automated Communications, Calgary, Alberta, Canada, July 1998, pages
adaptation by our toolkit. 103-116
16. L. Ranganathan, A. Acharya, S. Sharma and J.Saltz.
References Network-aware mobile programs, Department of Computer
1. O. Angin, A.T. Campbell, M.E. Kounavis and R. Liao. The Science University of Maryland College Park, MD 20740
Mobiware toolkit: Programmable support for adaptive mobile 17. Java profiling toolkit: JProbe, http://services.klgroup.com
networking. IEEE Personal Communications, 5(4):32-43, Aug. 18. A. Bakre, and B. Badrinath. I-TCP: Indirect TCP for
1998. mobile hosts, Proceedings of the 15th International Conference
2. J. Bolliger and T. Gross. A framework-based approach to on Distributed Computing Systems, Vancouver, Canada, May
the development of network-aware applications. IEEE Trans. on 1995, pages 136-143.
Software Eng., 24(5):376-390, May 1998. 19. C. Walshaw, M. Cross, and M. Everett. Parallel dynamic
3. N. Davies, A. Friday, S.P. Wade and G.S. Blair. L2imbo: A graph partitioning for adaptive unstructured meshes. Journal of
distributed systems platform for mobile computing. Mobile Parallel and Distributed Computing, 47(2):102-108, 1997.
Networks and Applications, 3(2):143-156, Aug. 1998. 20. CDPD Consortium, Cellular Digital Packet Data System
4. A. Fox, S.D. Gribble, Y. Chawathe and E. Breuer. Specification, Release 1.1, January 19, 1995 (CD-ROM)
Adapting to network and client variation using infrastructure 21. Lucent Technologies. WaveLAN Wireless Computing,
proxies: Lessons and perspectives. IEEE Personal http://www.wavelan.com/
Communications, 5(4):10-19, Aug. 1998. 22. Salim Omar. A mobile code toolkit for adaptive mobile
5. A.D. Joseph, A.F. deLaspinasse, J.A. Tauber, D.K. Gifford applications, April 2000, Thesis (M.C.S.), Carleton University,
and M.F. Kaashoek. Rover: a toolkit for mobile information School of Computer Science
access. ACM Operating Systems Review, 29(5):156-171, Dec. 23. W. Jianwen, A Proxy server infrastructure for adaptive
1995. mobile applications, September 1999, Thesis (M.C.S.), Carleton
6. B. Zenel and D. Duchamp. A general proxy filtering University, School of Computer Science
mechanism applied to the mobile environment, Proceedings of 24. ObjectSpace. Voyager 2.0.0 User Guide,
the Third Annual ACM/IEEE Conference on Mobile Computing http://www.objectspace.com/Voyager/
and Networking, Budapest, Hungary, September 1997, pages 25. Salim Omar and Thomas Kunz. Reducing power
248--259 consumption and increasing application performance for PDAs
7. H. Balakrishnan, S. Seshan, E. Amir, and R. H. Katz. through mobile code. Proceedings of the 1999 International
Improving TCP/IP performance over wireless networks, Conference on Parallel and Distributed Processing Techniques
Proceedings of the First Annual International Conference on and Applications, Vol. II, Las Vegas, Nevada, USA, June 1999,
Mobile Computing and Communications, Berkeley, USA, pages 1005-1011.
November 1995, pages 2-11
8. H. Balakrishnan, V. N. Padmanabhan, and R. H. Katz. The
effects of asymmetry on TCP performance, Proceedings of the
Third Annual ACM/IEEE Conference on Mobile Computing
0-7695-1435-9/02 $17.00 (c) 2002 IEEE 10
Proceedings of the 35th Annual Hawaii International Conference on System Sciences (HICSS-35’02)
0-7695-1435-9/02 $17.00 © 2002 IEEEYou can also read