summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorCliff Click <cliffc@acm.org>2026-08-10 11:11:18 -0700
committerCliff Click <cliffc@acm.org>2026-10-24 15:56:44 -0700
commit741d78b6e840c88b7b183010c812ad982b342da1 (patch)
tree84a75eb7ad351bffd20cd5fb152bab032b74271c /Makefile
parent8d90d2292bbdb23596849c3c3d1cda2f6cad783e (diff)
downloadSimple-741d78b6e840c88b7b183010c812ad982b342da1.tar.gz
Simple-741d78b6e840c88b7b183010c812ad982b342da1.zip
Chapter 28a: Modules and Lazy Class Initializationlinear-chapter28a
Co-authored-by: Hsiang-Ying Fu <66062782+fuhsnn@users.noreply.github.com> Co-authored-by: fuhsnn <66062782+fuhsnn@users.noreply.github.com> Co-authored-by: Symious <14933944+symious@users.noreply.github.com> Co-authored-by: Jun Kawasaki <jun784@gmail.com> Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile17
1 files changed, 16 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index e02c8096..e89e1bd7 100644
--- a/Makefile
+++ b/Makefile
@@ -68,7 +68,7 @@ include $(firstword $(wildcard ../graph/graph.mk graph/graph.mk))
include $(firstword $(wildcard ../print/print.mk print/print.mk))
include $(firstword $(wildcard ../isa/isa.mk isa/isa.mk))
test_classes := $(patsubst $(TST)/%java,$(CLZDIR)/test/%class,$(test_javas))
-test_cp := $(patsubst $(TST)/$(SIMPLE)/%.java,com.seaofnodes.simple.%,$(wildcard $(TST)/$(SIMPLE)/*Test.java)) com.seaofnodes.simple.codegen.X86EncodingTest
+test_cp := $(patsubst $(TST)/$(SIMPLE)/%.java,com.seaofnodes.simple.%,$(wildcard $(TST)/$(SIMPLE)/*Test.java))
classes = $(main_classes) $(test_classes)
# All the libraries
libs = $(wildcard lib/*jar)
@@ -184,3 +184,18 @@ spill-stats: $(CLZDIR)/main/.mtag $(CLZDIR)/test/.ttag
.PHONY: build
build: $(CLZDIR)/main/.mtag
+
+# The ABI shim gives standalone native tests the same entry contract as clients.
+CPU_PORT := x86_64_v2
+ifeq ($(OS),Windows_NT)
+CALL_CONV := win64
+NATIVE_ABI := ms_abi
+else
+CALL_CONV := SystemV
+NATIVE_ABI := sysv_abi
+endif
+runtime_obj := build/release/$(CPU_PORT)_$(CALL_CONV)/simple_crt.o
+$(runtime_obj): src/main/c/simple_crt.c Makefile
+ @mkdir -p $(dir $@)
+ gcc -c -O2 -DCALL_CONV=$(NATIVE_ABI) $< -o $@
+tests: $(runtime_obj)