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

Visualizer for Pipelined CPU's #124

Merged
merged 5 commits into from
Feb 27, 2020

Conversation

klanmiko
Copy link
Contributor

This visualizer was written in scala-swing and the goal is to display the modules used in the pipelined CPU design and their relative location between the pipeline registers. The visualization should reflect the value of I/O on the modules and update every cycle.

Features:

  • Designed with an MVC architecture based on a simplified circuit module and description of the pipelined CPU.
  • Loads LowFIRRTL through some AST parsing
  • Automatically places instances of modules to their correct pipeline register by running a DFS on the node graph to find modules connected to each pipeline register
  • Uses Treadle's peek() call to load values at ports.

Copy link
Contributor

@powerjg powerjg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very cool! I'm super excited to use this next quarter!

You should make sure your name is attached to this with more than just the commit message. I would suggest adding an "about" dialog or putting "By Kaelan..." in one of the bottom corners.

build.sbt Outdated
@@ -92,7 +95,7 @@ lazy val root = (project in file("."))
libraryDependencies += scalatest % Lab4,
testOptions in TestAll := Seq(Tests.Filter(allFilter)),
// CHANGE THE LINE BELOW FOR EACH LAB!!!! Use the matching filter
testOptions in Test := Seq(Tests.Filter(allFilter)),
testOptions in Test := Seq(Tests.Filter(lab3Filter)),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change should be reverted :)

Copy link
Contributor

@powerjg powerjg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a couple of files got added accidentally on this commit :).

@powerjg
Copy link
Contributor

powerjg commented Feb 26, 2020

I just tried to run this and got the following error:

> singularity exec library://jlowepower/default/dinocpu sbt "runMain dinocpu.visualize multiply.riscv" 
java.lang.UnsatisfiedLinkError: /usr/local/openjdk-8/jre/lib/amd64/libawt_xawt.so: libXext.so.6: cannot open shared object file: No such file or directory

It looks like I might need to update the singularity container to have some other dependency installed. Do you know what the dependencies are for this?

@powerjg
Copy link
Contributor

powerjg commented Feb 26, 2020

I figured it out. The following needs to be added to the dinocpu.def:

%post
    curl -L -o sbt-1.3.4.deb https://dl.bintray.com/sbt/debian/sbt-1.3.4.deb && \
    dpkg -i sbt-1.3.4.deb && \
    rm sbt-1.3.4.deb && \
    apt-get update -y && \
    apt-get install sbt libxext6 libfontconfig1 libxrender1 libxtst6 -y

@klanmiko
Copy link
Contributor Author

I figured it out. The following needs to be added to the dinocpu.def:

Ah. I never tested in the singularity container as I have sbt on my local development environment. I guess the old container didn't have awt and dependencies.

Copy link
Contributor

@powerjg powerjg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! There's a lot that could be improved, but it's a really solid addition. Thanks!

@powerjg powerjg merged commit 2c87904 into jlpteaching:master Feb 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants