forked from IHP-GmbH/IHP-Open-PDK
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updating some LVS devices, Adding makefile for regression, Adding act…
…ions Signed-off-by: FaragElsayed2 <farag_agoor@mabrains.com>
- Loading branch information
1 parent
78e25cc
commit 599ba51
Showing
35 changed files
with
388 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
## Environment | ||
|
||
- Klayout Version: | ||
- OS/Platform: | ||
|
||
## Expected Behavior | ||
|
||
|
||
## Actual Behavior | ||
|
||
|
||
## Steps to Reproduce the Problem | ||
|
||
1. | ||
2. | ||
3. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
Fixes #<issue_number_goes_here> | ||
|
||
- [ ] Tests pass | ||
- [ ] Appropriate changes to README are included in PR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#========================================================================== | ||
# Copyright 2024 IHP PDK Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# https://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
#========================================================================== | ||
|
||
name: code linting | ||
on: | ||
pull_request: | ||
# push: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
lint_python: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: 'recursive' | ||
- name: Lint with flake8 | ||
run: | | ||
make lint_python |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
#========================================================================== | ||
# Copyright 2024 IHP PDK Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# https://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
#========================================================================== | ||
|
||
name: LVS regression testing | ||
|
||
# Prevent keeping resources busy when a branch/PR is updated | ||
# https://docs.github.com/en/actions/using-jobs/using-concurrency | ||
concurrency: | ||
group: ${{ github.repository }}-${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
on: | ||
# push: | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
lvs_switch: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: | ||
- { tool: klayout, part: lvs, test: switch } | ||
|
||
name: ${{ matrix.part }} | ${{ matrix.test }} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: 'recursive' | ||
- name: Testing ${{ matrix.part }} for ${{ matrix.test }} | ||
run: | | ||
make test-"$(python -c 'print("${{ matrix.part }}".upper())')"-${{ matrix.test }} | ||
build_lvs-matrix: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
lvs_table: ${{ steps.set-matrix.outputs.lvs_table }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- id: set-matrix | ||
run: | | ||
cd ihp-sg13g2/libs.tech/klayout/tech/lvs/rule_decks/ | ||
lvs_table=`echo '[' ; find -iname '*_extraction.lvs' | awk -F_ '{print $1}' | awk -F/ '{print $2}' | tr '[:lower:]' '[:upper:]' | tr '\n' ','|sed -e 's/^/\"/'| sed -e 's/,$/\"]/'|sed -e 's/,/\", \"/g'`; | ||
lvs_table=`echo $lvs_table | jq -c .` | ||
echo $lvs_table | ||
echo "lvs_table=$lvs_table" >>$GITHUB_OUTPUT | ||
lvs_regression: | ||
needs: build_lvs-matrix | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
part: [lvs] | ||
test: ${{ fromJson(needs.build_lvs-matrix.outputs.lvs_table) }} | ||
|
||
name: ${{ matrix.part }} | ${{ matrix.test }} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: 'recursive' | ||
- name: Testing ${{ matrix.part }} for ${{ matrix.test }} | ||
run: | | ||
make test-"$(python -c 'print("${{ matrix.part }}".upper())')"-${{ matrix.test }} | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
#========================================================================== | ||
# Copyright 2024 IHP PDK Authors | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# https://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
#========================================================================== | ||
|
||
# The top directory where environment will be created. | ||
TOP_DIR := $(realpath $(dir $(lastword $(MAKEFILE_LIST)))) | ||
VENV_RUN_COMMAND = $(TOP_DIR)/actions_venv/bin/activate | ||
|
||
# Path to regression | ||
KLAYOUT_LVS_TESTS := ihp-sg13g2/libs.tech/klayout/tech/lvs/testing | ||
|
||
# A pip `requirements.txt` file. | ||
# https://pip.pypa.io/en/stable/reference/pip_install/#requirements-file-format | ||
REQUIREMENTS_FILE := requirements.txt | ||
|
||
# ======================= | ||
# ------ ENV SETUP ------ | ||
# ======================= | ||
|
||
$(TOP_DIR)/actions_venv: | ||
@python3 -m venv $(TOP_DIR)/actions_venv | ||
|
||
# Install requirements | ||
env: $(TOP_DIR)/actions_venv | ||
@. $(VENV_RUN_COMMAND); pip install -r $(REQUIREMENTS_FILE) | ||
|
||
# ======================== | ||
# ----- LINTING TEST ----- | ||
# ======================== | ||
|
||
# Lint python code | ||
lint_python: env | ||
@echo "Running python linting for Klayout-tech directory" | ||
@. $(VENV_RUN_COMMAND); flake8 ihp-sg13g2/libs.tech/klayout/tech/ | ||
|
||
#================================= | ||
# ----- test-LVS_regression ------ | ||
#================================= | ||
|
||
.ONESHELL: | ||
test-LVS-main: env | ||
@. $(VENV_RUN_COMMAND); echo "Running Klayout-LVS regression for all devices" | ||
@. $(VENV_RUN_COMMAND); cd $(KLAYOUT_LVS_TESTS) && make test-LVS-main | ||
|
||
.ONESHELL: | ||
test-LVS-% : env | ||
@. $(VENV_RUN_COMMAND); echo "Running Klayout-LVS regression for $* device" | ||
@. $(VENV_RUN_COMMAND); cd $(KLAYOUT_LVS_TESTS) && make test-LVS-$* | ||
|
||
#================================= | ||
# -------- test-LVS-switch ------- | ||
#================================= | ||
|
||
test-LVS-switch: env | ||
@. $(VENV_RUN_COMMAND); echo "Running Klayout-LVS switch test" | ||
@. $(VENV_RUN_COMMAND); cd $(KLAYOUT_LVS_TESTS) && make test-LVS-switch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.