chore: organize repository build entry points and workflow docs

This commit is contained in:
Yaossg 2026-10-11 12:30:09 +08:00
parent 69f7f7a34b
commit 0751449021
2 changed files with 92 additions and 6 deletions

View file

@ -1,10 +1,41 @@
all: slime slime-cuda
CXX ?= g++
NVCC ?= nvcc
CXXFLAGS ?= -O3 -std=c++17
NVCCFLAGS ?= -O3 -std=c++17
# Keep the original default build compatible; use `make bench` for the current CLI.
.PHONY: all legacy bench research show tools test test-gpu clean help
all: legacy
legacy: slime slime-cuda
slime: slime.cpp
g++ -o slime slime.cpp -O3 -std=c++17
$(CXX) $(CXXFLAGS) $< -o $@
slime-cuda: slime.cu
nvcc -o slime-cuda slime.cu -O3 -std=c++17
$(NVCC) $(NVCCFLAGS) $< -o $@
bench:
$(MAKE) -C bench
research:
$(MAKE) -C research
show:
$(MAKE) -C show
tools:
$(MAKE) -C tools
test:
$(MAKE) -C bench test
test-gpu:
$(MAKE) -C bench test-gpu
clean:
rm -f slime slime-cuda
rm -f slime slime-cuda sliming
$(MAKE) -C bench clean
$(MAKE) -C research clean
$(MAKE) -C codex clean
$(MAKE) -C show clean
$(MAKE) -C tools clean
help:
@echo 'make bench Build the current CUDA benchmark CLI'
@echo 'make test Run CLI host-side checks (nvcc required, GPU not required)'
@echo 'make test-gpu Run CLI GPU integration checks'
@echo 'make legacy Build the original CPU/CUDA brute-force programs (default)'
@echo 'make research Build research prototypes'
@echo 'make show Build teaching examples'
@echo 'make tools Build the single-chunk checker'
@echo 'make clean Remove compiled outputs; retain reports and datasets'