aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/loadext.c1
-rw-r--r--src/resolve.c2
-rw-r--r--src/sqliteInt.h12
-rw-r--r--src/table.c2
4 files changed, 12 insertions, 5 deletions
diff --git a/src/loadext.c b/src/loadext.c
index 6011fd2bf..3296be60d 100644
--- a/src/loadext.c
+++ b/src/loadext.c
@@ -18,7 +18,6 @@
#endif
#include "sqlite3ext.h"
#include "sqliteInt.h"
-#include <string.h>
#ifndef SQLITE_OMIT_LOAD_EXTENSION
/*
diff --git a/src/resolve.c b/src/resolve.c
index dac73e5fa..7d89b6fec 100644
--- a/src/resolve.c
+++ b/src/resolve.c
@@ -15,8 +15,6 @@
** table and column.
*/
#include "sqliteInt.h"
-#include <stdlib.h>
-#include <string.h>
/*
** Walk the expression tree pExpr and increase the aggregate function
diff --git a/src/sqliteInt.h b/src/sqliteInt.h
index d5ac957d2..6344cac5f 100644
--- a/src/sqliteInt.h
+++ b/src/sqliteInt.h
@@ -512,6 +512,18 @@
#include <stddef.h>
/*
+** Use a macro to replace memcpy() if compiled with SQLITE_INLINE_MEMCPY.
+** This allows better measurements of where memcpy() is used when running
+** cachegrind. But this macro version of memcpy() is very slow so it
+** should not be used in production. This is a performance measurement
+** hack only.
+*/
+#ifdef SQLITE_INLINE_MEMCPY
+# define memcpy(D,S,N) {char*xxd=(char*)(D);const char*xxs=(const char*)(S);\
+ int xxn=(N);while(xxn-->0)*(xxd++)=*(xxs++);}
+#endif
+
+/*
** If compiling for a processor that lacks floating point support,
** substitute integer for floating-point
*/
diff --git a/src/table.c b/src/table.c
index a50d83ce6..c79255f99 100644
--- a/src/table.c
+++ b/src/table.c
@@ -17,8 +17,6 @@
** if they are not used.
*/
#include "sqliteInt.h"
-#include <stdlib.h>
-#include <string.h>
#ifndef SQLITE_OMIT_GET_TABLE