Module Name:    src
Committed By:   rjs
Date:           Sun Aug 26 21:06:46 UTC 2018

Modified Files:
        src/sys/arch/evbarm/conf: files.generic64
        src/sys/arch/evbarm/include: sljit_machdep.h
Added Files:
        src/sys/arch/aarch64/include: sljit_machdep.h

Log Message:
Add SLJIT to aarch64.


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/sys/arch/aarch64/include/sljit_machdep.h
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/evbarm/conf/files.generic64
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/evbarm/include/sljit_machdep.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/evbarm/conf/files.generic64
diff -u src/sys/arch/evbarm/conf/files.generic64:1.3 src/sys/arch/evbarm/conf/files.generic64:1.4
--- src/sys/arch/evbarm/conf/files.generic64:1.3	Sat Jun 16 00:19:04 2018
+++ src/sys/arch/evbarm/conf/files.generic64	Sun Aug 26 21:06:46 2018
@@ -1,4 +1,4 @@
-#	$NetBSD: files.generic64,v 1.3 2018/06/16 00:19:04 jmcneill Exp $
+#	$NetBSD: files.generic64,v 1.4 2018/08/26 21:06:46 rjs Exp $
 #
 
 defparam opt_arm_debug.h	EARLYCONS
@@ -15,3 +15,9 @@ include "arch/arm/nvidia/files.tegra"
 include "arch/arm/rockchip/files.rockchip"
 include "arch/arm/sunxi/files.sunxi"
 include "arch/arm/virt/files.virt"
+
+#
+# Stack-less Just-In-Time compiler
+#
+
+include	"external/bsd/sljit/conf/files.sljit"

Index: src/sys/arch/evbarm/include/sljit_machdep.h
diff -u src/sys/arch/evbarm/include/sljit_machdep.h:1.1 src/sys/arch/evbarm/include/sljit_machdep.h:1.2
--- src/sys/arch/evbarm/include/sljit_machdep.h:1.1	Wed Jul 23 18:19:43 2014
+++ src/sys/arch/evbarm/include/sljit_machdep.h	Sun Aug 26 21:06:46 2018
@@ -1,3 +1,7 @@
-/*	$NetBSD: sljit_machdep.h,v 1.1 2014/07/23 18:19:43 alnsn Exp $	*/
+/*	$NetBSD: sljit_machdep.h,v 1.2 2018/08/26 21:06:46 rjs Exp $	*/
 
+#ifdef __aarch64__
+#include <aarch64/sljit_machdep.h>
+#else
 #include <arm/sljit_machdep.h>
+#endif

Added files:

Index: src/sys/arch/aarch64/include/sljit_machdep.h
diff -u /dev/null src/sys/arch/aarch64/include/sljit_machdep.h:1.1
--- /dev/null	Sun Aug 26 21:06:47 2018
+++ src/sys/arch/aarch64/include/sljit_machdep.h	Sun Aug 26 21:06:46 2018
@@ -0,0 +1,53 @@
+/*	$NetBSD: sljit_machdep.h,v 1.1 2018/08/26 21:06:46 rjs Exp $	*/
+
+/*-
+ * Copyright (c) 2014 Alexander Nasonov.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef _AARCH64_SLJITARCH_H
+#define _AARCH64_SLJITARCH_H
+
+#include <sys/cdefs.h>
+
+#ifdef _KERNEL
+#include <machine/types.h>
+#include <aarch64/cpufunc.h>
+#else
+#include <stddef.h>
+#include <stdint.h>
+#include <aarch64/sysarch.h>
+#endif
+
+#define SLJIT_CONFIG_ARM_64 1
+
+#ifdef _KERNEL
+#define SLJIT_CACHE_FLUSH(from, to) \
+	cpu_icache_sync_range((vaddr_t)(from), (vsize_t)((to) - (from)))
+#else
+#define SLJIT_CACHE_FLUSH(from, to) \
+	(void)aarch64_sync_icache((uintptr_t)(from), (size_t)((to) - (from)))
+#endif
+
+#endif

Reply via email to