102 lines
3.3 KiB
YAML
Raw Normal View History

2022-01-06 23:10:12 +08:00
name: CI——Benchmark
2021-10-06 22:37:29 +08:00
on:
push:
branches: [ master ]
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
jobs:
2021-10-09 01:22:48 +08:00
core:
2021-10-06 22:37:29 +08:00
# The CMake configure and build commands are platform agnostic and should work equally
# well on Windows or Mac. You can convert this to a matrix build if you need
# cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
2022-04-29 00:26:34 +08:00
runs-on: ubuntu-20.04
2021-10-06 22:37:29 +08:00
steps:
- uses: actions/checkout@v2
2022-04-08 11:26:38 +08:00
- name: INSTALL_PACKAGE
run: |
sudo apt install ninja-build
sudo apt install liblua5.3-dev
sudo apt install valgrind
2022-10-01 20:28:39 +08:00
sudo apt install upx
sudo apt install libmbedtls-dev
2022-01-04 00:39:30 +08:00
2022-02-11 02:01:20 +08:00
- name: install_google_benchmark
2022-02-14 19:15:10 +08:00
run: |
2022-04-29 00:26:34 +08:00
git clone https://github.com/google/benchmark.git
2022-02-14 19:15:10 +08:00
cd benchmark
cmake -E make_directory "build"
cmake -E chdir "build" cmake -DBENCHMARK_DOWNLOAD_DEPENDENCIES=on -DCMAKE_BUILD_TYPE=Release ../
2022-05-04 23:56:38 +08:00
cmake --build "build" --config Release -j
sudo cmake --build "build" --config Release --target install -j
2022-01-04 00:39:30 +08:00
2022-02-11 02:01:20 +08:00
- name: PULL_CORE
run: cd ${{github.workspace}}/port/linux && bash pull-core.sh
2021-10-06 22:46:11 +08:00
2022-02-11 02:01:20 +08:00
- name: INIT
run: cd ${{github.workspace}}/port/linux && bash init.sh
2021-10-06 22:37:29 +08:00
2022-02-11 02:01:20 +08:00
- name: TEST
# Build your program with the given configuration
run: cd ${{github.workspace}}/port/linux && bash gtest.sh
2022-07-21 21:28:56 +08:00
- name: VALGRIND
run: cd ${{github.workspace}}/port/linux && bash valgrind.sh
2022-01-04 00:56:04 +08:00
2022-02-11 02:01:20 +08:00
- name: BENCHMARK
run: cd ${{github.workspace}}/port/linux && bash ci_benchmark.sh
2022-01-04 09:10:59 +08:00
2022-02-11 02:01:20 +08:00
- name: CLEAR
run: cd ${{github.workspace}}/port/linux && rm *.sh
2022-01-05 10:30:01 +08:00
2022-02-11 02:01:20 +08:00
- name: Store benchmark result
uses: benchmark-action/github-action-benchmark@v1
with:
tool: 'googlecpp'
output-file-path: ${{github.workspace}}/port/linux/benchmark_result.json
github-token: ${{ secrets.GITHUB_TOKEN }}
auto-push: true
2021-10-08 10:45:36 +08:00
2022-04-15 15:02:32 +08:00
# - name: Filter for perfoment point
# run: |
# git clone -b gh-pages https://github.com/pikastech/pikascript ${{github.workspace}}/../pikapages
# cd ${{github.workspace}}/../pikapages/dev/bench
# git config --global user.email "liang6516@outlook.com"
# git config --global user.name "pikastech"
# git remote set-url origin https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
# git pull --rebase
# pip3 install matplotlib
# pip3 install numpy
# python3 filter.py
# git commit --allow-empty -a -m "update data_after.js"
# git push
2021-10-08 10:48:36 +08:00
2022-03-24 17:34:22 +08:00
# packageManager-windows:
# runs-on: windows-latest
# steps:
# - uses: actions/checkout@v2
# - name: PACKAGE_MANAGER
# run: cd ${{github.workspace}}/tools/pikaPackageManager && go run main.go
2022-03-24 17:53:51 +08:00
# bytecode-gen:
# runs-on: windows-latest
# steps:
# - uses: actions/checkout@v2
2022-03-24 17:34:22 +08:00
2022-03-24 17:53:51 +08:00
# - name: BYTECODE-GEN
# run: |
# cd ${{github.workspace}}/tools/pikaByteCodeGen
# cd pikascript
# ./pikaPackage.exe
# cd ..
# mkdir build
# cd build
# cmake ..