F ast A pp L aunching for Mobile Devices Using Predictive User Con text
description
Transcript of F ast A pp L aunching for Mobile Devices Using Predictive User Con text
Fast App Launching for Mobile Devices Using Predictive User Context Tingxin Yan University of Massachusetts AmherstDavid Chu Microsoft ResearchDeepak Ganesan University of Massachusetts AmherstAman Kansal Microsoft ResearchJie Liu Microsoft Research
1
“The Peregrine Falcon is renowned for its speed, reaching over 322
km/h (200 mph) during its characteristic hunting stoop (high speed dive), making it the fastest member of the animal kingdom.”
MobiSys 2012Low Wood Bay, Lake District, UK
falcon
2
Mobile Apps…
measured on Samsung Focus Windows Phone
Top Apps in Marketplace
Average loading time > 12s
Angry
Birds
SONIC
THE H
EDGE
Need f
or Sp
eed
Fruit N
inja
Tetri
s
PES 2
011
Doodle
Jump
Naviga
tion
HoloPh
one 3
D0
5
10
15
20
25
Load
ing
Tim
e (s
)
Loading Slowly
Slow Network Content Fetching
3
Email News Social
measured on iPhone 3GS Loading time > 10s in 3G
4
App Prelaunch with Context
Challenges and Approaches
What is Prelaunch?Prelaunch: Schedule an app to run before the user launches it
Which app to prelaunch?
Context clues indicate predictable app usage
patterns
Data insights shed light on informative
context (3)
At what cost and benefit?
Cost: energy, memory
Benefit: latency reduction
Problem formulation efficiently provides
optimal solution
Requiring what systems support?
FALCON’s scheduling and memory management
complement kernel’s
Windows Phone OS mod prototype
implementation
inference
optimization
systems
5
Trigger Context
0
0.1
0.2
0.3
SMS Email Social Phone Browser
Session
TimeEmail News Game
Trigger Followers
0
0.1
0.2
WordsWF SMS Email Phone Browser
most popular triggers overallmost popular triggers for Angry Birds
Trigger Context: given a trigger
app, identify most likely follower
apps[interpretation]
Interruptions lead us to habitual
routines
6
Location Context
HOME WORK SHOPPING0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
Game Calendar Social
Pro
babi
lity
Den
sity
Cal
Cal
Calendar
Game
Game
Location Context: given a location (cluster
id), identify most likely apps
Productivity Apps @ Work
Social Apps@ Outdoors
[interpretation]What we are
doing depends on Where we are
7
Burst Context
0
50
100
150
JAN FEB MAR APR MAY JUNE JULY AUG SEPT OCT NOV DEC JAN FEB
App
Usa
ge Angry Bird
2010 2011How long are bursts?
Burst window
0
0.5
1
1 10 20 30 40 50 60
Pro
babi
lity
Days
Burst Context: detect and
predict whether an app is bursting
Apps exhibit bursts of popularity
[interpretation]We get bored of
stuff
8
Decision Engine, Step 1: Likelihood Estimation
App Likelihood Estimation: Conditional probability on <Trigger,
Location, Burst>
Likelihood Estimates used as ranking metric…
baseline
trigger
+location
+burstbetter
Context:Trigger, Location, Burst
9
Decision Engine, Step 2: Cost-Benefit AnalysisLikelihood Estimates
• Maximize Latency Reduction
• Subject to energy budget (e.g. 2%)
Optimization Problem
• Knapsack Problem• Top-K Greedy
Approximation
Potential Benefit: Latency reduction
IonBall
Ex
Let's
Golf
3
Metro-Y
outu
beMail
Peop
leMap
s02468
1012141618
Regular LaunchPrelaunched
Laun
ch L
aten
cy (
s)
Potential Cost:Energy wasted
IonBall
Ex
Let's
Golf
3
Metro-Y
outu
beMail
Peop
leMap
s0
200
400
600
800
1000
1200
Laun
ch E
nerg
y (u
Ah)
Runtime Example
10
Phone SMS Email AngryBirds
Weather
Memory
Trigger Follower Cost/Benefit Rank
SMS WordsWithFriends 1
SMS Facebook 2SMS AngryBirds 3SMS NeedForSpeed 4SMS Twitter 5
Apps likely @ Current Location and BurstingWordsWithFriendsAngryBirdsFacebookNeedForSpeed…
WordsWFriends
TriggerPrelaunched FollowersDecision
Engine
Energy Budget
11
FALCON Architecture & Prototype
Date/Time
Apps Used
Geo Coords
Context Source
Manager
…
DispatcherFeature Extracto
rs
Decision
Engine
Launch Predictor
Server-based Model Trainer
Model Trainer
Proc TrackerKernel
Memory Manager (not
FALCON)
…App
1App
2 AppN
User
Kernel
FALCONcomponentsshown
Context• Trigger• Location• Burst
• Inference• Cost-
Benefit Analysis
FALCON UI
Windows Phone 7.5 OS mod
2MB main memory; negligible processing & energy overheadsee paper for details
12
Evaluation: FALCON vs. LRU
Reduced from 9s to 6s
Results for Games & Entertainment
appssimilar results for all
apps
13
Evaluation: Time-Since-Last-Update
Email Time-Since-Last-Update (minutes)
Reduced from 30min to 3min
FALCON outperforms
polling most of the time
FALCON
Polling (30 mins)
No Prefetching
14
Evaluation: Cost-Benefit Analysis
6s latency reduction for 2% energy budget
15
ConclusionFALCON: Fast App Launching with ContextWhich app to prelaunch?
Context clues indicate predictable app usage
patterns
Data insights shed light on informative context
At what cost and benefit?
Cost: energy, memory
Benefit: latency reduction
Problem formulation efficiently provides
optimal solution
Requiring what systems support?
FALCON’s scheduling and memory management complement kernel’s
Windows Phone OS mod prototype implementation
Insightful Context: Trigger, Location,
BurstCost-Benefit
Decision Engine (see paper)
inference optimization systems
Backup Slides
16
Evaluation: Micro-benchmarks
17
Sally
's Sa
lon
Sonic
the H
edge
Tent
acles
Doodle
Jump
Mon
opoly
Beard
s & B
eaks
IonBall
Ex
Let's
Golf
3
Metr
o-You
tube
Peop
leM
aps
0
5
10
15
20
25
Regular Launch
Prelaunched
Laun
ch L
aten
cy (
s)
Sally
's Sa
lon
Sonic
the H
edge
Tent
acles
Doodle
Jump
Monop
oly
Beard
s & Bea
ks
IonBall
Ex
Let's
Golf
3
Metro-Y
outu
beMail
Peop
leMap
s0
200400600800
1000120014001600
Laun
ch E
nerg
y (u
Ah)
benefit: latency reduction if predictions always right
cost: energy expenditure if predictions always wrong
Popular & 1st Party Apps
Launch Predictor Bootstrap & Training
18
Context Acquisition Cost• App History is free
• Trigger Context• Burst Context
• Location can be cheap• Coarse-grained location is cheap (base station id, Wi-Fi AP id)• Location Service cache amortizes fine-grained location cost
across apps
19