clonecloud: elastic execution between mobile device … · (1) mobile device. reference mid cid....
TRANSCRIPT
![Page 1: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/1.jpg)
1
CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE AND CLOUD
Byung-Gon Chun
Joint work with Sunghwan Ihm (Princeton) Petros Maniatis (Intel), Mayur Naik (Intel), Ashwin Patti (Intel)
![Page 2: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/2.jpg)
2
Mobile Apps Gain Rapid Popularity
![Page 3: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/3.jpg)
3
Users Increasingly Expect More from Apps
• Examples – Mobile augmented reality – Visual/audio search – Image/video/speech processing – Citizen science – Intrusion detection, exfiltration protection
![Page 4: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/4.jpg)
4
The Mobile-Resource Disparity
• Handheld devices still in the ’90s
– Constrained by thermal profile & size
![Page 5: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/5.jpg)
5
Project Goal
Enable expensive, exotic applications on mobile devices without increase in device
footprint or required capabilities
![Page 6: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/6.jpg)
6
Observations
• Powered devices more powerful than ever – Have them at home, and there’s cloud
• Lots of faster wireless connectivity
![Page 7: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/7.jpg)
7
Use Ambient Resources
• Use accessible clouds, computing hotspots (e.g., cloudlets), available desktops or plugged-in laptops nearby
• Augment mobile device applications through ambient resource execution to make its applications better
Cyber foraging (Balan et al. 2002)
Abundant computation, lots of faster connectivity
![Page 8: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/8.jpg)
8
Approach: Dynamic Splitting of Apps
• Client-Server model? – Split is made manually, early – Split persists even when hardware, networks,
costs, workload, urgency change
• Dynamically shift computation between mobile device and cloud
![Page 9: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/9.jpg)
9
What Does This Look Like? Phone
Application
100%
Phone
Application
10%
Originally
Slow device, Cloud available
![Page 10: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/10.jpg)
10
What Does This Look Like? Phone
Application
100%
Originally
Fast device, Cloud available
MID
Application
80%
![Page 11: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/11.jpg)
11
Talk Outline
• Introduction • CloneCloud design
– Clones – Partitioning – Migration
• Evaluation • Conclusion
![Page 12: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/12.jpg)
12
CloneCloud: Powerful Clones
Datacenter
![Page 13: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/13.jpg)
13
CloneCloud v1 Strategy • Partition apps written for a mobile device
automatically
• Seamlessly execute locally & remotely
• Optimize high-level objective (time, energy) by adaptation
• Exploit application-level VMs
![Page 14: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/14.jpg)
14
The Before-After Picture
Phone
UI W
Phone
Clone
Cloud
WUI W'
Clone
Clone
Clone
![Page 15: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/15.jpg)
15
CloneCloud v1 Architecture
VMMHW
PartitionAnalyzer
OSVirtual HW
Migration
Mobile Device
Runtime
OSHW
Application
App.VM
Man
ager Migration
Clone VM
ProfilerOS
Virtual HW
Application
App.VM
ManagerProfiler
![Page 16: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/16.jpg)
16
AppVM Clones
• Virtual machine of entire client device – Android x86 VM natively executed on
VMWare in an x86 machine
• Synchronized file systems
![Page 17: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/17.jpg)
17
Partitioning
Where to partition code, satisfying any constraints for correctness,
so as to optimize for current conditions
![Page 18: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/18.jpg)
18
Automatic Partitioning Framework
Partition Analyzer
Application binary
Partitioning constraints
Static analysis
location- constraints
Profiling inputs
Dynamic profiling
cost-annotated executions
Optimization solver
Optimal partitioning
points
Identify valid split points
Construct cost models
Pick best choice for an objective
![Page 19: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/19.jpg)
19
Partitioning: Static Analysis • Partitioning points
– Restrict to method entry/exit
• Identify “pinned” methods – Identify framework library methods
• Identify mutually dependent native state
– Class natives stay together
• Collect static control flow – Who calls whom
![Page 20: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/20.jpg)
20
Partitioning: Profiling
• Pick k invocations • For each invocation
– Run app on mobile device
– Run app on clone • For each method
– Execution time – Context size entry/exit – Estimate of energy
consumption
a30, 2100
c60, 810
a'11, 1200
main
main'19, 9
5
b50, 5900
a
![Page 21: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/21.jpg)
21
Partitioning: Intuition
• Partitioning points splice profile trees together • Context size used to estimate network cost
a30, 2100
c60, 810
a'11, 1200
main
main'19, 9
5
b50, 5900
a a
ca'
main
main'
b50, 520
a
MobileDevice Clone
![Page 22: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/22.jpg)
22
Partitioning: Optimization
• List all partitioning choices
• Remove partitioning choices that do not meet the constraints
• For each choice, compute total time
• Find the minimum
![Page 23: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/23.jpg)
23
Distributed Execution
How to seamlessly execute the partitions of an application locally and remotely
![Page 24: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/24.jpg)
24
Migration Architecture
App-VM
Migrator
NodeManager
NodeManagerNet
(1) (4)
Mobile Device Clone
Partitions
App-VM
Application
Migrator
App-VM
Migrator
Application
App-VM
Migrator
Clone
App-VM
Migrator
Clone
App-VM
Migrator
(2)
(3)
![Page 25: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/25.jpg)
25
Migration: Suspend-Transmit-Resume Mobile device Clone
Transmit
At migration point Suspend thread Capture context Transmit Launch process
Patch migrated context Resume thread
Suspend thread Capture context Merge migrated
context Resume thread
At reintegration point
![Page 26: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/26.jpg)
26
Migration Challenges
• Regular IDs (references) not globally unique – Address space difference between mobile
device and clone
• System objects created at boot everywhere
![Page 27: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/27.jpg)
27
Migration: References in Motion
(1) Mobile Device
Reference MID CID0x01 1 null0x02 2 null0x03 3 null
migration
New objects
GC’ed
(2) Clone
Reference MID CID0x21 1 110x22 2 120x23 3 130x24 null 140x22 null 15
rein
tegr
atio
n(3) Mobile DeviceReference MID CID
0x01 1 110x02 2 120x03 3 130x04 4 140x05 5 15
![Page 28: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/28.jpg)
28
The CloneCloud v1 Prototype
• On Android platform + x86 VM clones • Modified DalvikVM to support thread-level
migration and dynamic profiling • Implemented NodeManager to handle
registration and communication • Static analysis using JChord
![Page 29: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/29.jpg)
29
Evaluation Setup • Test applications
– Image search – Virus scanning – Privacy-preserving user profiling
• Phone: Android Dev Phone 1 • Clone VM: a server with a 3.0GHz Xeon CPU
running VMWare ESX 4.1 in Intel IT infrastructures
• Wireless connection: WiFi, T-mobile 3G
![Page 30: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/30.jpg)
30
Execution Time Comparison (Image Search)
Exec
utio
n tim
e (s
econ
ds)
0
500
1000
1500
2000
2500
1 image 10 images 100 images
Phone(Local)
CloneCloud(Wi-Fi)
CloneCloud(3G)
20x
1x
![Page 31: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/31.jpg)
31
Energy Consumption Comparison (Image Search)
Ener
gy c
onsu
mpt
ion
(J)
0
300
600
900
1200
1500
1800
1 image 10 images 100 images
Phone(Local)
CloneCloud(Wi-Fi)
CloneCloud(3G)
20x
1x
![Page 32: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/32.jpg)
32
Discussion
• Applicability is application-specific – Application characteristics – Execution mechanism
• A design point with focus on automation – Apps structured to be more amenable to
migration • Clone VMs in untrusted environments
![Page 33: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/33.jpg)
33
Related Work
• MAUI • Partitioning • Migration • Remote execution
![Page 34: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/34.jpg)
34
Conclusion
• CloneCloud: automatic partitioning and migration to enhance mobile applications – Use of clones – Flexible app partitioning – Seamless migration
Lots of excitements in mobile cloud computing
![Page 35: CLONECLOUD: ELASTIC EXECUTION BETWEEN MOBILE DEVICE … · (1) Mobile Device. Reference MID CID. 0x01 1 null 0x02 2 null 0x03 3 null. on. New objects GC’ed (2) Clone. Reference](https://reader033.vdocuments.net/reader033/viewer/2022050511/5f9bb191416a2a59a214044a/html5/thumbnails/35.jpg)
35
THANK YOU! Q & A