aboutsummaryrefslogtreecommitdiff
path: root/IncompletelySpecifiedBehavior.md
diff options
context:
space:
mode:
authorDan Gohman <sunfish@mozilla.com>2015-06-02 02:09:41 -0700
committerDan Gohman <sunfish@mozilla.com>2015-06-03 13:37:04 -0700
commiteac29775795b034a65724b1de71d2db31f91a1cd (patch)
tree90db23e6859819e211c221bff77b91de0720596b /IncompletelySpecifiedBehavior.md
parentde455af1cd7e94e5940262f1511b1be5fc8dc1a3 (diff)
downloadnanowasm-design-eac29775795b034a65724b1de71d2db31f91a1cd.tar.gz
Add a paragraph describing about control flow properties.
Diffstat (limited to 'IncompletelySpecifiedBehavior.md')
-rw-r--r--IncompletelySpecifiedBehavior.md2
1 files changed, 2 insertions, 0 deletions
diff --git a/IncompletelySpecifiedBehavior.md b/IncompletelySpecifiedBehavior.md
index 2bdf9d2..4d82de3 100644
--- a/IncompletelySpecifiedBehavior.md
+++ b/IncompletelySpecifiedBehavior.md
@@ -2,6 +2,8 @@
WebAssembly is a sandboxed platform. Applications can't access data outside the sandbox without going through appropriate APIs, or otherwise escape the sandbox, even if the behavior inside the sandbox should ever be unspecified in any way.
+WebAssembly always maintains valid callstacks. Return addresses are stored on the trusted stack and can't be clobbered by the application. And, WebAssembly ensures that calls and branches always have valid destinations.
+
Beyond that, WebAssembly minimizes observable differences between implementations, to reduce the risk of applications becoming dependent on any particular implementation's behavior. However, occasionally compromises are made due to performance concerns, listed below.
In particular, WebAssembly has no [nasal demons](https://en.wikipedia.org/w/index.php?title=Nasal_demons), since they are an extreme on the spectrum of observable differences, and since they make it difficult to reason about what state an application might be in. WebAssembly prefers to [trap](AstSemantics.md) when feasible, and otherwise it permits a specific set of possible conforming behaviors.