github.com/cloudwego/frugal@v0.1.15/Makefile (about) 1 .PHONY: all clean 2 3 C_SRC := native/skipping.c 4 GO_ASM := internal/binary/decoder/native_amd64.s 5 GO_PROTO := internal/binary/decoder/native_amd64.go 6 7 CFLAGS := -mavx 8 CFLAGS += -mno-bmi 9 CFLAGS += -mno-avx2 10 CFLAGS += -mno-red-zone 11 CFLAGS += -fno-asynchronous-unwind-tables 12 CFLAGS += -fno-stack-protector 13 CFLAGS += -fno-exceptions 14 CFLAGS += -fno-builtin 15 CFLAGS += -fno-rtti 16 CFLAGS += -nostdlib 17 CFLAGS += -O3 18 19 all: ${GO_ASM} 20 21 clean: 22 rm -vf ${GO_ASM} output/*.s 23 24 ${GO_ASM}: ${C_SRC} ${GO_PROTO} 25 mkdir -p output 26 clang ${CFLAGS} -S -o output/native.s ${C_SRC} 27 python3 tools/asm2asm/asm2asm.py ${GO_ASM} output/native.s 28 asmfmt -w ${GO_ASM}