Add loongarch64 support.

Signed-off-by: Guoqi Chen <chenguoqi@loongson.cn>
This commit is contained in:
Guoqi Chen 2024-04-19 15:23:28 +08:00
parent 18cdded900
commit c34c0783f2
1 changed files with 18 additions and 8 deletions

View File

@ -14944,7 +14944,8 @@ typedef INT16_TYPE LogEst;
# elif defined(i386) || defined(__i386__) || defined(_M_IX86) || \
defined(__x86_64) || defined(__x86_64__) || defined(_M_X64) || \
defined(_M_AMD64) || defined(_M_ARM) || defined(__x86) || \
defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) || \
defined(__loongarch_lp64)
# define SQLITE_BYTEORDER 1234
# elif defined(sparc) || defined(__ARMEB__) || defined(__AARCH64EB__)
# define SQLITE_BYTEORDER 4321
@ -36480,6 +36481,14 @@ SQLITE_PRIVATE int sqlite3VListNameToNum(VList *pIn, const char *zName, int nNam
return retval;
}
#elif !defined(__STRICT_ANSI__) && (defined(__GNUC__) && defined(__loongarch_lp64))
__inline__ sqlite_uint64 sqlite3Hwtime(void){
unsigned long long retval;
__asm__ __volatile__ ("rdtime.d %0, $r0": "=r" (retval));
return (sqlite_uint64)retval;
}
#else
/*
@ -208952,7 +208961,8 @@ struct RtreeMatchArg {
# elif defined(i386) || defined(__i386__) || defined(_M_IX86) || \
defined(__x86_64) || defined(__x86_64__) || defined(_M_X64) || \
defined(_M_AMD64) || defined(_M_ARM) || defined(__x86) || \
defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64)
defined(__ARMEL__) || defined(__AARCH64EL__) || defined(_M_ARM64) || \
defined(__loongarch_lp64)
# define SQLITE_BYTEORDER 1234
# elif defined(sparc) || defined(__ARMEB__) || defined(__AARCH64EB__)
# define SQLITE_BYTEORDER 4321