Skip to content

Commit

Permalink
Merge pull request #102 from permaweb/feat/dev_snp_nif
Browse files Browse the repository at this point in the history
feat: SNP validation NIF and BEAMR refactor
  • Loading branch information
samcamwilliams authored Jan 26, 2025
2 parents 2abfa6f + 4374380 commit b6d8954
Show file tree
Hide file tree
Showing 57 changed files with 4,917 additions and 1,823 deletions.
12 changes: 5 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,16 @@ rebar3.crashdump
*~

*.json
node_modules
!.vscode/*

*.bin
!.vscode/*
.vscode/c_cpp_properties.json

native/hb_beamr/*.o
native/hb_beamr/*.d

c_src/*.o
c_src/*.d
priv/*
.DS_STORE
TEST-data*
test-cache/*
TEST-cache-**

.githooks/_/.setup
TEST-cache**/**
4 changes: 0 additions & 4 deletions .gitpod.Dockerfile

This file was deleted.

16 changes: 0 additions & 16 deletions .gitpod.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
"editor.detectIndentation": false,
"editor.insertSpaces": false,
"editor.tabSize": 4
}
}
39 changes: 0 additions & 39 deletions DEPLOY-notes.md

This file was deleted.

35 changes: 35 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
FROM --platform=linux/amd64 ubuntu:22.04

RUN apt-get update && apt-get install -y \
build-essential \
cmake \
git \
pkg-config \
ncurses-dev \
libssl-dev \
sudo

RUN git clone https://github.com/erlang/otp.git && \
cd otp && \
git checkout maint-27 && \
./configure && \
make -j16 && \
sudo make install

RUN git clone https://github.com/erlang/rebar3.git && \
cd rebar3 && \
./bootstrap && \
sudo mv rebar3 /usr/local/bin/

RUN git clone https://github.com/rust-lang/rust.git && \
cd rust && \
./configure && \
make && \
sudo make install

COPY . /app

RUN cd /app && \
rebar3 compile

CMD ["/bin/bash"]
125 changes: 0 additions & 125 deletions GCP-notes.md

This file was deleted.

25 changes: 12 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,9 @@
compile:
rebar3 compile

WAMR_VERSION = 2.1.2
WAMR_VERSION = 2.2.0
WAMR_DIR = _build/wamr

# commented out to remove NFR blocking commits
# GITHOOKS_DIR = .githooks

ifdef HB_DEBUG
WAMR_FLAGS = -DWAMR_ENABLE_LOG=1 -DWAMR_BUILD_DUMP_CALL_STACK=1 -DCMAKE_BUILD_TYPE=Debug
else
Expand All @@ -30,8 +27,6 @@ else
WAMR_BUILD_TARGET = X86_64
endif

# githooks: $(GITHOOKS_DIR)/_/setup

wamr: $(WAMR_DIR)/lib/libvmlib.a

debug: debug-clean $(WAMR_DIR)
Expand All @@ -51,25 +46,29 @@ $(WAMR_DIR):
--single-branch

$(WAMR_DIR)/lib/libvmlib.a: $(WAMR_DIR)
sed -i '742a tbl_inst->is_table64 = 1;' ./_build/wamr/core/iwasm/aot/aot_runtime.c; \
cmake \
$(WAMR_FLAGS) \
-S $(WAMR_DIR) \
-B $(WAMR_DIR)/lib \
-DWAMR_BUILD_TARGET=$(WAMR_BUILD_TARGET) \
-DWAMR_BUILD_PLATFORM=$(WAMR_BUILD_PLATFORM) \
-DWAMR_BUILD_LIBC_WASI=0 \
-DWAMR_BUILD_MEMORY64=1 \
-DWAMR_DISABLE_HW_BOUND_CHECK=1 \
-DWAMR_BUILD_EXCE_HANDLING=1 \
-DWAMR_BUILD_SHARED_MEMORY=0 \
-DWAMR_BUILD_AOT=0 \
-DWAMR_BUILD_AOT=1 \
-DWAMR_BUILD_LIBC_WASI=0 \
-DWAMR_BUILD_FAST_INTERP=0 \
-DWAMR_BUILD_INTERP=1 \
-DWAMR_BUILD_JIT=0
make -C $(WAMR_DIR)/lib

# $(GITHOOKS_DIR)/_/setup:
# @sh ./$(GITHOOKS_DIR)/_/install.sh
-DWAMR_BUILD_JIT=0 \
-DWAMR_BUILD_FAST_JIT=0 \
-DWAMR_BUILD_DEBUG_AOT=1 \
-DWAMR_BUILD_TAIL_CALL=1 \
-DWAMR_BUILD_AOT_STACK_FRAME=1 \
-DWAMR_BUILD_MEMORY_PROFILING=1 \
-DWAMR_BUILD_DUMP_CALL_STACK=1
make -C $(WAMR_DIR)/lib -j8

clean:
rebar3 clean
Expand Down
Loading

0 comments on commit b6d8954

Please sign in to comment.