diff options
author | Xavier Leroy <xavier.leroy@inria.fr> | 2015-01-27 16:57:20 +0100 |
---|---|---|
committer | Xavier Leroy <xavier.leroy@inria.fr> | 2015-01-27 16:57:20 +0100 |
commit | e096fa7aa6161e1f5a74001185eb3873a684c48d (patch) | |
tree | ca928bcb3f7b6b2237a626fbb1dbc1ce62b2e5d1 /cparser/Cutil.mli | |
parent | f00b70b6a17fdfb4e8606df891f6becc8102ef12 (diff) | |
download | compcert-kvx-e096fa7aa6161e1f5a74001185eb3873a684c48d.tar.gz compcert-kvx-e096fa7aa6161e1f5a74001185eb3873a684c48d.zip |
ABI compatibility for struct/union function arguments passed by value.
The passing of struct/union arguments by value implemented in the verified
part of CompCert is not compatible with the ARM, PowerPC and x86 ABI.
Here we enrich the StructReturn source-to-source emulation pass
so that it implements the calling conventions defined in these ABIs.
Plus: for x86, implement the returning of struct/union results by value
in a way compatible with the ABI.
Diffstat (limited to 'cparser/Cutil.mli')
-rw-r--r-- | cparser/Cutil.mli | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/cparser/Cutil.mli b/cparser/Cutil.mli index b90dc897..deee9f08 100644 --- a/cparser/Cutil.mli +++ b/cparser/Cutil.mli @@ -210,6 +210,8 @@ val eassign : exp -> exp -> exp (* Expression for [e1 = e2] *) val ecomma : exp -> exp -> exp (* Expression for [e1, e2] *) +val ecommalist : exp list -> exp -> exp + (* Expression for [e1, ..., eN, e] *) val sskip: stmt (* The [skip] statement. No location. *) val sseq : location -> stmt -> stmt -> stmt @@ -232,3 +234,10 @@ val formatloc: Format.formatter -> location -> unit val default_init: Env.t -> typ -> init (* Return a default initializer for the given type (with zero numbers, null pointers, etc). *) + +(* Substitution of variables by expressions *) + +val subst_expr: exp IdentMap.t -> exp -> exp +val subst_init: exp IdentMap.t -> init -> init +val subst_decl: exp IdentMap.t -> decl -> decl +val subst_stmt: exp IdentMap.t -> stmt -> stmt |