commit | 6cc20110913878ddb1a917f5aca03f648ce3f056 | [log] [tgz] |
---|---|---|
author | Rupert Swarbrick <rswarbrick@lowrisc.org> | Fri Apr 24 09:44:35 2020 +0100 |
committer | weicaiyang <49293026+weicaiyang@users.noreply.github.com> | Mon Apr 27 10:34:44 2020 -0700 |
tree | b98c9fe5f6c90461eb1ee41fb43f310cdfd0b0b2 | |
parent | ec62b3e078e437e9c2c5c9ae20276a89681dd156 [diff] |
[dvsim] PEP8 fixes in dvsim These should cause no functional change. Detailed list of code changes: - Get rid of 'import *': this defeats static analysis tools. Don't do it. - Add newline after colon in "if foo: bar" - Use 'is' to check for equality with boolean literals - Don't catch exceptions when running os.system in Deploy.py: the os.system function returns the program's exit code. - Delete some variables that are written but not read. - Minor whitespace changes (missing blank lines between functions; weird indentation; missing space after '#') - Delete autogenerated module docstrings (they didn't contain any information. Maybe it would be good to have a docstring, but at the moment it's just noise). - Don't use \ as a line continuation character. Use parentheses if necessary. - Replace code like "foo" + \ "bar" with just "foo" "bar" (Python concatenates adjacent string literals just like C). (I didn't do this everywhere, but it happened a lot next to the backslash continuations, so I got rid of the unnecessary '+' then). - Replace "not foo in bar" with "foo not in bar" - Use raw strings for regexes with backslashes (r'a\+', not 'a\+') With these changes, you can run: find util/dvsim -name '*.py' | xargs flake8 and see no errors. Signed-off-by: Rupert Swarbrick <rswarbrick@lowrisc.org>
OpenTitan is an open source silicon Root of Trust (RoT) project. OpenTitan will make the silicon RoT design and implementation more transparent, trustworthy, and secure for enterprises, platform providers, and chip manufacturers. OpenTitan is administered by lowRISC CIC as a collaborative project to produce high quality, open IP for instantiation as a full-featured product. See the OpenTitan site and OpenTitan docs for more information about the project.
This repository contains hardware, software and utilities written as part of the OpenTitan project. It is structured as monolithic repository, or “monorepo”, where all components live in one repository. It exists to enable collaboration across partners participating in the OpenTitan project.
The project contains comprehensive documentation of all IPs and tools. You can either access it online or build it locally by following the steps below.
$ sudo apt install curl python3 python3-pip $ pip3 install --user -r python-requirements.txt
$ ./util/build_docs.py --preview
This compiles the documentation into ./build/docs
and starts a local server, which allows you to access the documentation at http://127.0.0.1:1313.
Have a look at CONTRIBUTING for guidelines on how to contribute code to this repository.
Unless otherwise noted, everything in this repository is covered by the Apache License, Version 2.0 (see LICENSE for full text).