[llvm-commits] CVS: llvm/tools/lli/Interpreter/ExternalFunctions.cpp
Chris Lattner
lattner at cs.uiuc.edu
Wed Apr 23 15:24:01 PDT 2003
Changes in directory llvm/tools/lli/Interpreter:
ExternalFunctions.cpp updated: 1.46 -> 1.47
---
Log message:
Add memcpy
---
Diffs of the changes:
Index: llvm/tools/lli/Interpreter/ExternalFunctions.cpp
diff -u llvm/tools/lli/Interpreter/ExternalFunctions.cpp:1.46 llvm/tools/lli/Interpreter/ExternalFunctions.cpp:1.47
--- llvm/tools/lli/Interpreter/ExternalFunctions.cpp:1.46 Wed Apr 23 14:55:24 2003
+++ llvm/tools/lli/Interpreter/ExternalFunctions.cpp Wed Apr 23 15:23:16 2003
@@ -571,6 +571,12 @@
return PTOGV(memset(GVTOP(Args[0]), Args[1].IntVal, Args[2].UIntVal));
}
+// void *memcpy(void *Dest, void *src, size_t Size);
+GenericValue lle_X_memcpy(FunctionType *M, const vector<GenericValue> &Args) {
+ assert(Args.size() == 3);
+ return PTOGV(memcpy((char*)GVTOP(Args[0]), (char*)GVTOP(Args[1]),
+ Args[2].UIntVal));
+}
//===----------------------------------------------------------------------===//
// IO Functions...
@@ -798,6 +804,7 @@
FuncNames["lle_X_strcpy"] = lle_X_strcpy;
FuncNames["lle_X_strlen"] = lle_X_strlen;
FuncNames["lle_X_memset"] = lle_X_memset;
+ FuncNames["lle_X_memcpy"] = lle_X_memcpy;
FuncNames["lle_X_fopen"] = lle_X_fopen;
FuncNames["lle_X_fclose"] = lle_X_fclose;
More information about the llvm-commits
mailing list