Skip to content

Commit

Permalink
Merge pull request #7 from fwsGonzo/CIbuild
Browse files Browse the repository at this point in the history
Add Engine CI build
  • Loading branch information
fwsGonzo authored Jan 13, 2024
2 parents f2b1b60 + b94ae30 commit de4c0f7
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 4 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/engine.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Build Engine w/scripts

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:
runs-on: ubuntu-latest

strategy:
matrix:
compiler: [ {cpp: g++-12, c: gcc-12}, {cpp: clang++-17, c: clang-17} ]

defaults:
run:
working-directory: ${{github.workspace}}/engine

steps:
- uses: actions/checkout@v2

- name: Install dependencies
run: |
sudo apt update
sudo apt install -y ninja-build ccache cmake build-essential libglew-dev libglfw3-dev \
gcc-12 g++-12 g++-12-riscv64-linux-gnu
git submodule update --init ${{github.workspace}}/tests/Catch2
git submodule update --init --recursive ${{github.workspace}}/ext/nanogui
git submodule update --init --recursive ${{github.workspace}}/ext/library
git submodule update --init ${{github.workspace}}/ext/libriscv
git submodule update --init ${{github.workspace}}/programs/micro/ext
- name: Install newer Clang
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x ./llvm.sh
sudo ./llvm.sh 17
- name: Configure
env:
CC: ${{ matrix.compiler.c }}
CXX: ${{ matrix.compiler.cpp }}
run: cmake -B ${{github.workspace}}/engine/build -DCMAKE_BUILD_TYPE=Release

- name: Build the engine
run: cmake --build ${{github.workspace}}/engine/build --parallel 4
2 changes: 1 addition & 1 deletion .github/workflows/unittests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
sudo apt install -y ninja-build ccache cmake libglew-dev libglfw3-dev g++-12-riscv64-linux-gnu
git submodule update --init ${{github.workspace}}/tests/Catch2
git submodule update --init --recursive ${{github.workspace}}/ext/nanogui
git submodule update --init ${{github.workspace}}/ext/library
git submodule update --init --recursive ${{github.workspace}}/ext/library
git submodule update --init ${{github.workspace}}/ext/libriscv
git submodule update --init ${{github.workspace}}/programs/micro/ext
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

RVScript is a game engine oriented scripting system backed by a [low latency RISC-V emulator](https://github.com/fwsGonzo/libriscv). By using a fast virtual machine with low call overhead and memory usage, combined with modern programming techniques we can have a type-safe and memory-safe script that is able to call billions of functions within a limited frame budget.

[![Unit Tests](https://github.com/fwsGonzo/rvscript/actions/workflows/unittests.yml/badge.svg)](https://github.com/fwsGonzo/rvscript/actions/workflows/unittests.yml)
[![Build Engine w/scripts](https://github.com/fwsGonzo/rvscript/actions/workflows/engine.yml/badge.svg)](https://github.com/fwsGonzo/rvscript/actions/workflows/engine.yml) [![Unit Tests](https://github.com/fwsGonzo/rvscript/actions/workflows/unittests.yml/badge.svg)](https://github.com/fwsGonzo/rvscript/actions/workflows/unittests.yml)

This project aims to change how scripting is done in game engines. Lua, LuaJIT and even Luau have fairly substantial overheads when calling into the script, especially when many arguments are involved. The same is true for some WebAssembly emulators that I have measured, eg. wasmtime. As a result, script functions are thought of as expensive to call often, and that changes thinking and design in projects accordingly. RVScript makes the game script ultra-low latency, so that even automation games where interactions between complex machinery requires billions of guest function calls, can still be achieved with RVScript.

Expand Down
2 changes: 1 addition & 1 deletion engine/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ if (USE_MOLD)
else()
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fuse-ld=/usr/local/bin/mold")
endif()
else()
elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fuse-ld=lld")
endif()

Expand Down
2 changes: 1 addition & 1 deletion ext/library
Submodule library updated 279 files

0 comments on commit de4c0f7

Please sign in to comment.