intelligent offload to improve battery lifetime of mobile devices ranveer chandra microsoft research
TRANSCRIPT
![Page 1: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/1.jpg)
Intelligent Offload to Improve Battery Lifetime of Mobile
Devices
Ranveer ChandraMicrosoft Research
![Page 2: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/2.jpg)
Phones are Energy Constrained
Energy: A critical issue in smartphones Limited battery lifetime
Battery energy density onlydoubled in last 15 years
Smartphone capability has increased drastically Multiple Components: GPS, 3G, retina display, ….
2
![Page 3: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/3.jpg)
Where Does the Energy Go?
Suspended State (68 mW)
Video Playback (450 mW + backlight)
Network, Display & CPU are the main energy hogs!
Android G1 energy consumption “An Analysis of Power Consumption in a Smartphone”, USENIX 2010
3
![Page 4: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/4.jpg)
Efforts to Improve Battery Life Battery: bigger, more energy density
Challenge: Lighter phones
CPU: low power cores, parking individual cores Challenge: multi-core, faster processors
Network: low power cellular & Wi-Fi states Challenge: LTE, 802.11ac
Display: energy-efficient display, e.g. AMOLED Challenge: larger & brighter displays, video,
animation4
![Page 5: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/5.jpg)
Mission & Big Bets
“Lasting a week without charge under normal usage”
Profile energy use of each component₋ Application energy profiler ₋ Energy debugging
Big Bets:- Offload: Intelligently utilize available resources - Energy-aware UI: based on OLED energy models- Adaptive battery usage: OS controlled multi-
battery systems5
![Page 6: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/6.jpg)
OFFLOAD
6
![Page 7: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/7.jpg)
Computational Offload
Move computation away from main processor without degrading user experience Such that SoC is in low power states for longer
7
Application Processor
Graphics UnitMem
ory
Uni
t
Stor
age
Wi-Fi & Cell Modem
Accelerator
SoC (~1W when awake, ~10 mW when asleep)
Offload Component
![Page 8: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/8.jpg)
Where to Offload?
Low power subsystem on SoC Already shipping with TI and other SoC vendors
8
Application Processor
Graphics UnitMem
ory
Uni
t
Stor
age
Wi-Fi & Cell Modem
Accelerator
SoC (~1W when awake, ~10 mW when asleep)
Offload Component(Low Power Processor)
![Page 9: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/9.jpg)
Where to Offload?
Low power subsystem on SoC
Low power processor connected to NIC
9
Application Processor
Graphics UnitMem
ory
Uni
t
Stor
age
Wi-Fi & Cell Modem
Accelerator
SoC (~1W when awake, ~10 mW when asleep)
Offload Component(Low Power Processor)
![Page 10: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/10.jpg)
Where to Offload?
Low power subsystem on SoC
Low power processor connected to NIC
Cloud or another machine
10
Application Processor
Graphics UnitMem
ory
Uni
t
Stor
age
Wi-Fi & Cell Modem
Accelerator
SoC (~1W when awake, ~10 mW when asleep)
Offload Component(Cloud/PC)
![Page 11: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/11.jpg)
Use Cases
When display is off Push e-mail Continuous sensing Large downloads Instant Messaging P2P file sharing
When display is on Gaming Speech translation …
11
![Page 12: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/12.jpg)
OFFLOAD TO LOW-POWER PROCESSOR
12
Application Processor
Graphics UnitMem
ory
Uni
t
Stor
age
Wi-Fi & Cell Modem
Accelerator
SoC (~1W when awake, ~10 mW when asleep)
Offload Component(Low Power Processor)
![Page 13: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/13.jpg)
100’s of apps using the accelerometer
Not using the full potential of sensors13
![Page 14: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/14.jpg)
Responsive Sleeping Challenge
Sensor (accelerometer): 0.56mW Phone (mainly processor): ~600mW
Wakeup + sleep time: 1200ms @ 1Hz sampling, processor can’t
sleep
Sampling overhead High wakeup/sleep overhead
Solution: Offload sampling/processing sensor data to a low-power processor
14
![Page 15: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/15.jpg)
Phone Application Processor
Low-power proc.
High-speed serial bus + GPIO
Sensor buses (I2C, SPI etc.)Sensors
Phone Application Processor
Sensor buses (I2C, SPI etc.)
Sensors
Current Phones EERS
Energy Efficient Responsive Sleeping
Bodhi, Jie, Dimitrios (2010)
15
![Page 16: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/16.jpg)
Hardware Prototype
Interfaced directly to phone’s AP Processor: MSP430F5438
16KB RAM, 256KB Flash Active: 6.6mW @16MHz; sleep: 10mW Wakeup time: 4µs
Sensors: Temperature Pressure 3D compass 3D accelerometer 3D gyro Capacitive touch sensing (x16)
16
![Page 17: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/17.jpg)
17
Reprogrammable over the phone Leakage (sleep) power: 270mW Extensible: can accommodate more sensors,
radios etc. Can interrupt and turn on/off the phone Interfaced directly to phone processor (SPI bus +
GPIOs) Directly powered from the phone’s battery
Glue + Reset LogicPhone Interface
Main Proc.
Processor Module
SlaveProc.
SPI
Flash
GPIO
Digital Sensor Module
3-axisCompass Temp. Pressure3-axis
Accel.
Analog Sensor Module
ZGyro
A/DX-Y
Gyro SPI
I2C
Little Rock
Phone Battery
Power Supplies
![Page 18: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/18.jpg)
Summary
Low Power processor on SoC can drive sensors Key application: Continuous sensing
18
![Page 19: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/19.jpg)
OFFLOAD TO NETWORK-CONNECTED LOW-POWER PROCESSOR
19
Application Processor
Graphics UnitMem
ory
Uni
t
Stor
age
Wi-Fi & Cell Modem
Accelerator
SoC (~1W when awake, ~10 mW when asleep)
Offload Component(Low Power Processor)
Collaborators: Yuvraj Agarwal, Steve Hodges, James Scott, Victor Bahl
![Page 20: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/20.jpg)
Power/Energy Efficiency are Key Drivers Today
Battery Powered Computers “Wall Powered” Computers
Lenovo X61 laptop • Power: 0.74W (sleep) to 16W (active)• Goal: improve battery lifetime
Dell Optiplex 745 desktop • Power: 1.2W (sleep) to >140W (active)• Goal: reduce energy costs and impact to the environment
Energy efficiency: do more work for less power or energy
20
![Page 21: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/21.jpg)
IT Equipment Consumes Significant Power
Yet, shutdown opportunities are rarely used
Studies show that: 67% of office PCs are left on after work hours
“Sleep” modes used in less than 4% of these PCs! [1] Home PCs are left on for 34% of the time
50% of the time they are not being used
Confirmed by our measurements: CSE@UCSD 600+ desktops left always on (total=700+ )
@150W each 100kW (25% of total energy bill)
Propriety solutions at WaMu, Dell and GE have reported savings of millions dollars per year Thousands of tons of CO2 emission avoided!!!
[1] J. Roberson et al. “After-hours Power Status of Office Equipment and Energy use of Miscellaneous Plug-load Equipment. LawrenceBerkeley National Laboratory, Berkeley, California. Report# LBNL-53729-Revised, 2004 21
![Page 22: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/22.jpg)
Saving Power Runs into Usability
Reasons why users do not switch off their PCs Maintain state: desktop and applications
preferences Occasional access
Remote desktop/SSH, accessing files Administrative: updates, patches, backups
Active applications running Maintaining presence: e.g. incoming Skype call, IM Long running applications: Web downloads, BitTorrent
Cannot be handled by low-power modes (e.g. Sleep, Hibernate)
22
![Page 23: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/23.jpg)
Power Management vs. Use Models
• Current design trends in power management:– Hosts (PCs): either Awake (Active) or Sleep (Inactive)
• Power consumed when Awake = 100X power in Sleep!
– Network: Assumes hosts are always “Connected” (Awake)
• What users really want: – Provide functionality of an Awake (active) host… ….While consuming power as if in Sleep
mode– Resume host to Awake mode only if needed
Change the fundamental distinction between Sleep and Active states…23
![Page 24: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/24.jpg)
Network Interface
Augment PC’s Network Interface
Objective: Make PCs responsive even when asleep Maintain availability across the entire protocol stack
E.g. ARP(layer 2), ICMP(layer 3), SSH (Application layer) Without making changes to the infrastructure or user behavior
Active State : >140 WIdle State : 100 W Sleep State : 1.2 W
+Low Power
CPU
+
DRAM
+
Flash Memory Storage
Secondary Processor (Power in active state ~1W)
Requirements: • Functionally similar - masquerade as the host • Much lower power
24
![Page 25: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/25.jpg)
Somniloquy*: PCs Talk in their Sleep
Somniloquydaemon
Host processor,RAM, peripherals, etc.
Operating system, including networking
stack
Apps
Network interface hardware
Secondary processorEmbedded CPU, RAM,
flash
Embedded OS, including
networking stack
wakeupfilters
Appln. stubs
Host PC• Augment network interfaces:– Add a separate power domain
• Powered on when host is asleep • Processor + Memory +
Flash Storage + Network stack
– Same MAC/IP Address
• Wake up Host when needed– E.g. incoming connection
• Handle some applications while PC remains asleep– Using “application stubs” 25
![Page 26: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/26.jpg)
Supporting Stateless Apps: Filters
Wake up host on any user defined “filter” E.g. incoming Skype call, Remote Desktop
request Wake-on-LAN either impractical or affects
usability
Specified at any layer of the network stack E.g. from a particular IP (layer 3) or MAC (layer
2) E.g. wake up on finding “MSFTWLAN” Wi-Fi
network 26
![Page 27: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/27.jpg)
Supporting Stateful Apps: Stubs
Applications actively maintain state E.g. background web downloads, P2P file sharing (BitTorrent) Need application specific code on the secondary processor
Challenge: secondary processor limited in resources
CPU, memory, flash storage Cannot run the full application
Offload part of the applications: i.e. “stub” code Generate “stub” code manually Stubs for BitTorrent, Web downloads, IM
27
![Page 28: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/28.jpg)
Software Components
Somniloquy States
Stub config/app-layer wakeup filters
Secondary Processor
Port filters (TCP, UDP, ICMP etc)
Application stubs
Network config
Sleep/wake Mgmt.
Host PC
Somniloquy daemon
Applications
Operating System
Get/setnetwork config.
Computer active, using
network
Secondary subsystem not using network
Timer-based or user-initiated sleep
Wake up on incoming network eventor timer-based/user-initiated action
Computer asleep, not
using network
Secondary processor
enabled, using network
Port-Based wakeup filters
Application state
Network-based wakeup filters
Current network config
Wake-up signal and updated state
28
![Page 29: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/29.jpg)
Somniloquy Prototype
Prototype uses “gumstix” platform PXA270 processor with full TCP/IP
stack USB connection to PC for sleep
detection/wakeup trigger, power while asleep, and IP networking for data
Wired and wireless prototypes *-1NIC version follows initial vision of
augmented NIC, where all data goes via gumstix even when PC is awake
*-2NIC version uses PC’s internal interface while it is awake, and allows for simpler legacy-friendly support
Wired-1NIC prototype
Wireless-2NIC prototype
29
![Page 30: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/30.jpg)
USB Interface (Wake up Host + Status + Debug)
USB Interface (power + USBNet)
100Mbps Ethernet Interface
Processor
SD Storage
Prototype
30
![Page 31: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/31.jpg)
Evaluation Methodology
Maintain network reachability
Stateless applications (filter based): Measure increase in “application layer” latency Detailed power profile: Gumstix, Host PCs Extend battery lifetime (Laptops), Energy Savings
(Desktop)
Stateful applications (stub based): Measure energy savings
31
![Page 32: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/32.jpg)
Maintaining Reachability Respond to “ping”, ARPs, maintain DHCP
lease
0 10 20 30 40 50 60 70 800
1
2
3
4
5
6
7
8
Time (seconds)
ICM
P e
cho
-res
po
nse
s L
aten
cy (
ms)
Desktop going to Sleep 4 seconds
Desktop resuming from Sleep 5 seconds
Break in ICMP responses are due to state transitions: Sleep Active 32
![Page 33: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/33.jpg)
Stateless Apps: “Setup” Latency
• Measured time till user-perceived response
• For each, incoming TCP SYN caused wakeup
• Additional latency: 3-10s for all prototypes
• As a proportion of the resulting session, this is OK
Wire
d-1N
IC
Wire
d-2N
IC
Wire
less
-2N
IC
Wire
d-1N
IC
Wire
d-2N
IC
Wire
less
-2N
IC
Wire
d-1N
IC
Wire
d-2N
IC
Wire
less
-2N
IC
Wire
d-1N
IC
Wire
d-2N
IC
Wire
less
-2N
IC
Remote desktop connect
(RDP)
List remote directory (SMB)
Remote file copy (SMB)
Call connect (VOIP)
0
5
10
15
20
25
30
35
40Asleep (Somniloquy)
Awake
Tim
e (s
) till
appl
icati
on-le
vel t
ask
com
pleti
on
33
![Page 34: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/34.jpg)
Gumstix: Power Consumption
Gumstix State PowerWIRED VERSION
1. Gumstix only – No Ethernet 210mW
2. Gumstix + Ethernet Idle 1073mW
3. Gumstix + Ethernet + Write to flash 1675mW
WIRELESS VERSION
4. Gumstix only - no Wi-Fi 210mW
5. Gumstix + Wi-Fi associated (PSM) 290mW
6. Gumstix + Wi-Fi Associated (CAM) 1300mW
• Our prototypes consume 290mW (Wi-Fi) to 1W (Ethernet) • Similar to power consumed by our test laptop (740mW) in the “sleep” state.
...and our test desktop (1.2W) in the “sleep” state.
34
![Page 35: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/35.jpg)
Desktops: Power Savings
Using Somniloquy: – Power drops from >100W to <5W– Assuming a 45 hour work week
– 620kWh saved per year – US $56 savings, 378 kg CO2
Dell Optiplex 745 Power Consumption and transitions between states
State Power Normal Idle State 102.1W
Lowest CPU frequency 97.4W
Disable Multiple cores 93.1W
“Base Power” 93.1W
Suspend state (S3) 1.2W
35
![Page 36: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/36.jpg)
Laptops: Extends Battery Lifetime
Using Somniloquy: – Power drops from >11W to 1W,
– Battery life increases from <6 hours to >60 hours
– Provides functionality of the “Baseline” state– Power consumption similar to “Sleep” state
36
![Page 37: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/37.jpg)
Energy Savings for Sample Workloads
Use trace data from [Nedevschi-NSDI2009] 24 desktop PCs: ON, sleep, idle and OFF
durations
Bin data into 3 categories based on % idle time
% Idle Time % Energy Saving using Somniloquy
<25% of the time (7 PCs) 38%
25% - 75% of the time (6PCs) 68%
>75% of the time (9 PCs) 85%
37
![Page 38: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/38.jpg)
Stateful Application: Energy Savings
• Web download “stub” on the gumstix – 200MB flash, download when Desktop PC is asleep – Wake up PC to upload data whenever needed
– 92% less energy than using the host PC for download
0
50
100
150
200
Host Only Somniloquy
Time (seconds)
Pow
er C
onsu
mpti
on
(Watt
s)
1 600 1200 1800 2400
38
![Page 39: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/39.jpg)
Summary:
Somniloquy: augment network interfaces of PCs Maintain reachability and availability transparently Power consumption similar to a “sleep” state
Incrementally deployable prototype No changes to infrastructure, application servers
Demonstrable savings Desktops: reduced energy cost, carbon footprint Laptops: extend battery lifetime
39
![Page 40: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/40.jpg)
In the context of mobile devices Network-connected low power processor
can: Sync with e-mail Perform IM tasks Run Skype in the background Download music
… all without waking up the main processor
40
![Page 41: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/41.jpg)
CLOUD OFFLOAD
41
Application Processor
Graphics UnitMem
ory
Uni
t
Stor
age
Wi-Fi & Cell Modem
Accelerator
SoC (~1W when awake, ~10 mW when asleep)
Offload Component(Cloud/PC)
Collaborators: Eduardo Cuervo, Aruna Balasubramanian, Alec Wolman, Stefan Saroiu, Victor Bahl
![Page 42: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/42.jpg)
Mobile apps can’t reach their full potential
Augmented Reality
Speech Recognition and Synthesis Interactive Games
Slow, Limited or Inaccurate
Too CPU intensive Limited
Power Intensive
Not on par with desktop counterparts
42
![Page 43: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/43.jpg)
One Solution: Remote Execution
Remote execution can reduce energy consumption
Challenges: What should be offloaded? How to dynamically decide when to offload? How to minimize the required programmer
effort?
43
![Page 44: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/44.jpg)
MAUI: Mobile Assistance Using Infrastructure
MAUI Contributions: Combine extensive profiling with an ILP
solver Makes dynamic offload decisions Optimize for energy reduction Profile: device, network, application
Leverage modern language runtime (.NET CLR) To simplify program partitioning Reflection, serialization, strong typing
44
![Page 45: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/45.jpg)
Roadmap
Motivation MAUI system design
MAUI proxy MAUI profiler MAUI solver
Evaluation
45
![Page 46: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/46.jpg)
Maui serverSmartphone
Application
Client Proxy
Profiler
Solver
Maui Runtime
Server Proxy
Profiler
Solver
Maui Runtime
MAUI Architecture
Application
RPC
RPC
Maui Controller
46
![Page 47: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/47.jpg)
How Does a Programmer Use MAUI?
Goal: make it dead-simple to MAUI-ify apps Build app as a standalone phone app Add .NET attributes to indicate “remoteable” Follow a simple set of rules
47
![Page 48: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/48.jpg)
Run-Time Support For Partitioning
Portability: Mobile (ARM) vs Server (x86) .NET Framework Common Intermediate
Language Type-Safety and Serialization:
Automate state extraction Reflection:
Identifies methods with [Remoteable] tag Automates generation of RPC stubs
48
![Page 49: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/49.jpg)
Maui serverSmartphone
Application
Client Proxy
Profiler
Solver
Maui Runtime
Server Proxy
Profiler
Solver
Maui Runtime
Application
RPC
RPC
Maui Controller
MAUI Proxy
Intercepts Application CallsSynchronizes State
Chooses local or remote
Handles Errors
Provides runtime information
49
![Page 50: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/50.jpg)
MAUI Profiler
ProfilerCallgraph
Execution Time
State size
Network Latency
Network Bandwidth
Device ProfileCPU Cycles
Network Power CostNetwork DelayComputational Delay
Computational Power CostComputational Delay
Annotated Callgraph
50
![Page 51: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/51.jpg)
MAUI Solver
B900 mJ15ms
C5000 mJ3000 ms
1000mJ25000 m
J D15000 mJ12000 ms
1000
0 m
J
A
Computation energy and delay for execution
Energy and delay for state transfer
A sample callgraph
51
![Page 52: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/52.jpg)
Is Global Program Analysis Needed?
FindMatch900 mJ
InitializeFaceRecognizer
5000 mJ
1000mJ25000 m
J DetectAndExtract Faces
15000 mJ
1000
0 m
J
UserInterface
Yes! – This simple example from Face Recognition app shows why local analysis fails.
Cheaper to do local
52
![Page 53: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/53.jpg)
Is Global Program Analysis Needed?
FindMatch900 mJ
InitializeFaceRecognizer
5000 mJ
1000mJ25000 m
J DetectAndExtract Faces
15000 mJ
1000
0 m
J
UserInterface
Yes! – This simple example from Face Recognition app shows why local analysis fails.
Cheaper to do local
Cheaper to do local53
![Page 54: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/54.jpg)
Is Global Program Analysis Needed?
FindMatch
InitializeFaceRecognizer
1000mJ
DetectAndExtract Faces
UserInterface 25900mJ
Cheaper to offload
54
![Page 55: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/55.jpg)
Adapting to Changing Conditions Adapt to:
Network Bandwidth/Latency Changes Variability on method’s computational
requirements
Experiment: Modified off the shelf arcade game application Physics Modeling (homing missiles) Evaluated under different latency settings
55
![Page 56: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/56.jpg)
DoLevel
HandleMissiles
DoFrame
HandleEnemies
HandleBonuses
11KB + missiles
11KB
+
miss
iles
missiles
*Missiles take around 60 bytes each
11KB + missiles
Required state is smaller
Complexity increases with # of missiles
Adapting to Changing Conditions?
56
![Page 57: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/57.jpg)
Case 1
DoLevel
HandleMissiles
DoFrame
HandleEnemies
HandleBonuses
*Missiles take around 60 bytes each
Zero Missiles Low latency (RTT < 10ms)
Computation cost is close to zero
Offload starting at DoLevel
57
![Page 58: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/58.jpg)
Case 2
DoLevel
HandleMissiles
DoFrame
HandleEnemies
HandleBonuses
*Missiles take around 60 bytes each
5 Missiles Some latency (RTT = 50ms)
Most of the computation cost
Very expensive to offload everything
Little state to offload
Only offload Handle Missiles
58
![Page 59: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/59.jpg)
Roadmap
Motivation MAUI system design
MAUI proxy MAUI profiler MAUI solver
Evaluation
59
![Page 60: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/60.jpg)
MAUI Implementation
Platform Windows Mobile 6.5 .NET Framework 3.5 HTC Fuze Smartphone Monsoon power monitor
Applications Chess Face Recognition Arcade Game Voice-based translator
60
![Page 61: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/61.jpg)
Questions
How much can MAUI reduce energy consumption?
How much can MAUI improve performance? Can MAUI Run Resource-Intensive
Applications?
61
![Page 62: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/62.jpg)
0
5
10
15
20
25
30
35Smartphone onlyMAUI (Wi-Fi, 10ms RTT)MAUI (Wi-Fi, 25ms RTT)MAUI (Wi-Fi, 50ms RTT)MAUI (Wi-Fi, 100ms RTT)MAUI* (3G, 220ms RTT)
Ener
gy (J
oule
s)How much can MAUI reduce energy
consumption?
Big savings even on 3GAn order of magnitude improvement on Wi-Fi
Face Recognizer
62
![Page 63: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/63.jpg)
How much can MAUI improve performance?
0
3,000
6,000
9,000
12,000
15,000
18,000
21,000Smartphone onlyMAUI (Wi-Fi, 10ms RTT)MAUI (Wi-Fi, 25ms RTT)MAUI (Wi-Fi, 50ms RTT)MAUI (Wi-Fi, 100ms RTT)MAUI* (3G, 220ms RTT)
Exec
ution
Dur
ation
(ms)
Improvement of around an order of magnitude
Face Recognizer
63
![Page 64: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/64.jpg)
Latency to server impacts opportunities for fine-grained offload
0
20
40
60Smartphone onlyMAUI (Wi-Fi, 10ms RTT)MAUI (Wi-Fi, 25ms RTT)MAUI (Wi-Fi, 50ms RTT)MAUI (WiFi, 100ms RTT)MAUI* (3G, 220ms RTT)
Ener
gy (J
oule
s)
Up to 40% energy savings on Wi-Fi
Solver would decide not to offloadArcade Game
64
![Page 65: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/65.jpg)
Can MAUI Run Resource-Intensive Applications?
59:16 00:00 00:43 01:26 02:09 02:520
10
20
30
40
50
60
70
80
90
100
CPU1CPU2
Time
CPU
Con
sum
ption
(%)
CPU Intensive even on a Core 2 Duo PC
Can be run on the phone with MAUI
Translator
65
![Page 66: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/66.jpg)
SUMMARY
66
![Page 67: Intelligent Offload to Improve Battery Lifetime of Mobile Devices Ranveer Chandra Microsoft Research](https://reader030.vdocuments.site/reader030/viewer/2022032801/56649de55503460f94adc8ef/html5/thumbnails/67.jpg)
Looking ahead…
Mechanisms are in place Low power cores in the SoC
TI and others … Big.Little processors from ARM
Expected by end of year Smart Web Services
Offload Policies: the next big move?
67