Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable CI for yosys synthesis for monitoring resource usages #87

Merged
merged 9 commits into from Aug 18, 2019
@@ -9,9 +9,25 @@ pipeline {
}
}

stage("Yosys synthesis"){
steps {
sh 'docker run --rm -v $(pwd):/src -w /src librecores/librecores-ci:0.4.0 /bin/bash -c \
This conversation was marked as resolved by stffrdhrn

This comment has been minimized.

Copy link
@stffrdhrn

stffrdhrn Aug 18, 2019

Member

Here you use 0.4.0, but in dockerrun you are not using a version. Is that on purpose?

This comment has been minimized.

Copy link
@Nancy-Chauhan

Nancy-Chauhan Aug 18, 2019

Author Contributor

For librecores-ci-openrisc, currently, there is no version! currently picks up latest

"fusesoc library add mor1kx /src; \
fusesoc run --target=synth mor1kx; \
/test-scripts/extract-yosys-stats.py < build/mor1kx_*/synth-icestorm/yosys.log"'
}
}

stage('Resource Usage Report Generation') {
steps {
echo "-=- execute performance tests -=-"

This comment has been minimized.

Copy link
@stffrdhrn

stffrdhrn Aug 18, 2019

Member

You are still saying performance tests here.

This comment has been minimized.

Copy link
@Nancy-Chauhan

Nancy-Chauhan Aug 18, 2019

Author Contributor

I am sorry @stffrdhrn . But I will be changing this . I am working on jenkins shared library . Will send changes soon in PR with library for both or1k-marochinno and mor1kx .

perfReport 'output.csv'
}
}

This conversation was marked as resolved by Nancy-Chauhan

This comment has been minimized.

Copy link
@Nancy-Chauhan

Nancy-Chauhan Aug 1, 2019

Author Contributor

@oleg-nenashev can you please review the jenkinsfile

stage("Docker run") {
parallel {
stage("verilator") {
stage("verilator") {
environment{
JOB = 'verilator'
}
@@ -35,7 +51,7 @@ pipeline {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES="or1k-cy"
EXPECTED_FAILURES="or1k-cy"
EXTRA_CORE_ARGS="--feature_dmmu NONE"
}
steps {
@@ -44,10 +60,10 @@ pipeline {
}
stage("testing 3") {
environment {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy or1k-dsxinsn"
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy or1k-dsxinsn"
EXTRA_CORE_ARGS = "--feature_immu NONE"
}
steps {
@@ -56,10 +72,10 @@ pipeline {
}
stage("testing 4") {
environment {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy"
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy"
EXTRA_CORE_ARGS = "--feature_datacache NONE"
}
steps {
@@ -68,10 +84,10 @@ pipeline {
}
stage("testing 5") {
environment {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy"
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy"
EXTRA_CORE_ARGS = "--feature_instructioncache NONE"
}
steps {
@@ -80,10 +96,10 @@ pipeline {
}
stage("testing 6") {
environment {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy"
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy"
EXTRA_CORE_ARGS = "--feature_debugunit NONE"
}
steps {
@@ -92,10 +108,10 @@ pipeline {
}
stage("testing 7") {
environment {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy or1k-cmov"
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy or1k-cmov"
EXTRA_CORE_ARGS = "--feature_cmov NONE"
}
steps {
@@ -104,10 +120,10 @@ pipeline {
}
stage("testing 8") {
environment {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy or1k-ext"
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'CAPPUCCINO'
EXPECTED_FAILURES = "or1k-cy or1k-ext"
EXTRA_CORE_ARGS = "--feature_ext NONE"
}
steps {
@@ -116,9 +132,9 @@ pipeline {
}
stage("testing 9") {
environment {
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'ESPRESSO'
JOB = 'or1k-tests'
SIM = 'icarus'
PIPELINE = 'ESPRESSO'
}
steps {
script {
@@ -128,7 +144,7 @@ pipeline {
} catch (Exception e) {
echo "Allowed failure"
}
}
}
}
}
}
@@ -138,4 +154,4 @@ pipeline {

void dockerrun() {
sh 'docker run --rm -v $(pwd):/src -e "JOB=$JOB" -e "SIM=$SIM" -e "PIPELINE=$PIPELINE" -e "EXPECTED_FAILURES=$EXPECTED_FAILURES" -e "EXTRA_CORE_ARGS=$EXTRA_CORE_ARGS" librecores/librecores-ci-openrisc /src/.travis/test.sh'
}
}
@@ -163,12 +163,21 @@ Integration (CI) suite running in [travis ci](travis-ci.org). This currently co
caching, timers, interrupts and other features.

Status: [![Build Status](https://travis-ci.org/openrisc/mor1kx.svg?branch=master)](https://travis-ci.org/openrisc/mor1kx)


The or1k Continuous Integration (CI) suite is running in a librecores-ci-openrisc docker container in Travis CI. Parallel execution of tests runs in librecores-ci-openrisc docker environment.
- [librecores-ci-openrisc](https://github.com/librecores/docker-images/tree/master/librecores-ci-openrisc) docker image is based on the standard [librecores/librecores-ci](https://github.com/librecores/docker-images/tree/master/librecores-ci) docker image and it largely target the [FuseSoC](https://github.com/olofk/fusesoc) use cases.
- [librecores-ci-openrisc](https://github.com/librecores/docker-images/tree/master/librecores-ci-openrisc) docker image is based on the standard [librecores/librecores-ci](https://github.com/librecores/docker-images/tree/master/librecores-ci) docker image and it largely target the [FuseSoC](https://github.com/olofk/fusesoc) use cases.
- The base image includes installation of common EDA tools such as Icarus Verilog, Verilator and Yosys that is required by CI suite for testing. librecores/libreocres-ci-openrisc docker image gets the toolchain required, downloads and compiles the or1k-tests.


The Continous Integration suite also runs in [Jenkins](https://ci.librecores.org/) supported by [Librecores-CI](https://github.com/librecores/librecores-ci-jenkins-server). As similar to Travis, `mor1kx` pipelines are also constantly verified. In addition to that, it also supports:

- Yosys synthesis for monitoring resource usages. [Fusesoc](https://github.com/olofk/fusesoc/blob/master/doc/icestorm.adoc) provides the icestorm backend.
- [LibreCores CI](https://github.com/librecores/docker-images/tree/master/librecores-ci) Docker image provides Yosys synthesis metrics parser which outputs 'Printing Statistics'. Results are parsed to graphs with Performance Plugin, which can be seen at [ci.librecores.org](https://ci.librecores.org/job/Projects/job/OpenRISC/job/mor1kx/)
This conversation was marked as resolved by stffrdhrn

This comment has been minimized.

Copy link
@stffrdhrn

stffrdhrn Aug 18, 2019

Member

Is this actually the librecores-ci-openrisc image now?

This comment has been minimized.

Copy link
@Nancy-Chauhan

Nancy-Chauhan Aug 18, 2019

Author Contributor

No, I placed the yosys parser script to the standard librecores-ci image for general use, hence I have mentioned the standard image.



Status : [![Build Status](https://ci.librecores.org/job/Projects/job/OpenRISC/job/mor1kx/job/master/badge/icon)](https://ci.librecores.org/job/Projects/job/OpenRISC/job/mor1kx/job/master/)

In the future we are working on bringing more tests including:

- softfloat, fpu verification (may not be feasable in CI due to long run times)
@@ -187,4 +196,3 @@ Verification status of mor1kx pipelines:
|`ESPRESSO`|`linting` `or1k-tests` |Still many pipeline failures, see issue #71|
|`PRONTO_ESPRESSO`|`linting`|No toolchain support for no-delayslot c code|
|`MAROCCHINO`|`linting` `or1k-tests`|See [marocchino](https://github.com/openrisc/or1k_marocchino) project.|

@@ -87,3 +87,11 @@ targets:
- "tool_rivierapro? (monitor)"
- "tool_xsim? (monitor)"
parameters: [trace_enable, trace_to_screen]

synth:
default_tool : icestorm
filesets : [core , fpu]
tools:
icestorm:
pnr: none
toplevel : mor1kx
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.