-
Notifications
You must be signed in to change notification settings - Fork 34
108 lines (92 loc) · 2.79 KB
/
codeql.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
name: CodeQL
on:
push:
branches:
- main
pull_request:
branches:
- main
paths:
- 'source/**'
- 'clik/**'
- 'modules/**'
- 'examples/**'
- 'cmake/**'
- 'hal/**'
- '.github/actions/do_build_ock/**'
- '.github/actions/setup_build/**'
- '.github/workflows/codeql.yml'
- 'CMakeLists.txt'
schedule:
- cron: '19 9 * * 3'
permissions: {}
jobs:
analyze-host-x86_64-release:
name: Analyze host x86_64 release
permissions:
# required for all workflows
security-events: write
# required to fetch internal or private CodeQL packs
packages: read
runs-on: ubuntu-22.04
steps:
- name: Checkout repo
uses: actions/checkout@v4
# installs tools, ninja and installs llvm (default 18, RelAssert) and sets up cache
- name: setup-ubuntu
uses: ./.github/actions/setup_build
with:
llvm_version: 18
llvm_build_type: RelAssert
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL (${{ matrix.name }})
uses: github/codeql-action/init@v3
with:
languages: c-cpp
build-mode: manual
- name: build host x86_64 release
uses: ./.github/actions/do_build_ock
with:
build_type: Release
build_targets:
- name: build host x86_64 offline
uses: ./.github/actions/do_build_ock
with:
build_type: Release
extra_flags: -DCA_RUNTIME_COMPILER_ENABLED=OFF -DCA_EXTERNAL_CLC=${{ github.workspace }}/build/bin/clc
build_dir: build_offline
assemble_spirv_ll_lit_test_offline: ON
build_targets:
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:c-cpp"
analyze-riscv-m1:
name: Analyze riscv m1
permissions:
# required for all workflows
security-events: write
# required to fetch internal or private CodeQL packs
packages: read
runs-on: ubuntu-22.04
steps:
- name: Checkout repo
uses: actions/checkout@v4
# installs tools, ninja and installs llvm (default 18, RelAssert) and sets up cache
- name: setup-ubuntu
uses: ./.github/actions/setup_build
with:
llvm_version: 18
llvm_build_type: RelAssert
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL (${{ matrix.name }})
uses: github/codeql-action/init@v3
with:
languages: c-cpp
build-mode: manual
- name: build riscv m1
uses: ./.github/actions/do_build_ock/do_build_m1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:c-cpp"