|
|
1
2
|
\begin{abstract}
|
|
|
3
|
One of the reasons programming mobile systems is so hard is the wide variety
|
|
|
4
5
6
7
|
of environments a typical app encounters at runtime. As a result, in many
cases only post-deployment user testing can determine the right algorithm to
use, the rate at which something should happen, or when an app should attempt
to conserve energy. Programmers should not be forced to make these choices at
|
|
|
8
9
|
development time. Unfortunately, languages leave no way for programmers to
express and structure uncertainty about runtime conditions, forcing them to
|
|
|
10
|
adopt ineffective or fragile ad-hoc solutions.
|
|
|
11
|
|
|
|
12
|
\sloppypar{We introduce a new approach based on \textit{structured uncertainty}
|
|
|
13
|
through a new language construct: the \texttt{maybe} statement.
|
|
|
14
|
\texttt{maybe} statements allow programmers to defer choices about app
|
|
|
15
|
behavior that cannot be made at development time, while providing enough
|
|
|
16
17
|
structure to allow a system to later adaptively choose from multiple
alternatives. Eliminating the uncertainty introduced by \texttt{maybe}
|
|
|
18
|
statements can be done in a large variety of ways: through simulation, split
|
|
|
19
|
testing, user configuration, temporal adaptation, or machine learning
|
|
|
20
|
techniques, depending on the type of adaptation appropriate for each
|
|
|
21
22
|
situation. Our paper motivates the \texttt{maybe} statement, presents its
syntax, and describes a complete system for testing and choosing from
|
|
|
23
|
\texttt{maybe} alternatives.}
|
|
|
24
25
|
\end{abstract}
|