summaryrefslogtreecommitdiff
path: root/cfrontend
diff options
context:
space:
mode:
authorGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2010-04-17 07:01:18 +0000
committerGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2010-04-17 07:01:18 +0000
commit59646439baa1b9cc6209b684e4ccf9aac908fdbc (patch)
tree55f0b7c0f82f9b0e32ba754dc129938ac1242cc9 /cfrontend
parent9e9853b79e652036c2e5c7af01d8ac9add0b8962 (diff)
Support __builtin_memcpy; use it for struct assignment
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1319 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'cfrontend')
-rw-r--r--cfrontend/C2Clight.ml13
1 files changed, 13 insertions, 0 deletions
diff --git a/cfrontend/C2Clight.ml b/cfrontend/C2Clight.ml
index 100c72b..614ad77 100644
--- a/cfrontend/C2Clight.ml
+++ b/cfrontend/C2Clight.ml
@@ -841,6 +841,19 @@ let builtins_generic = {
(TVoid [], [TPtr(TVoid [], []); TFloat(FDouble, [])], false);
"__builtin_volatile_write_pointer",
(TVoid [], [TPtr(TVoid [], []); TPtr(TVoid [], [])], false)
+ (* Block copy *)
+ "__builtin_memcpy",
+ (TPtr(TVoid [], []),
+ [TPtr(TVoid [], []);
+ TPtr(TVoid [AConst], []);
+ TInt(Cutil.size_t_ikind, [])],
+ false);
+ "__builtin_memcpy_words",
+ (TPtr(TVoid [], []),
+ [TPtr(TVoid [], []);
+ TPtr(TVoid [AConst], []);
+ TInt(Cutil.size_t_ikind, [])],
+ false)
]
}