Mykland
Mykland

Reputation: 155

Recommended Java/Scala settings for Chisel

Recently, I've been learning Chisel from the top down, having had no previous exposure to Scala and only passing exposure to Java. As I have attempted larger and larger hardware constructs, I'm starting to generate cryptic errors from Java that I've determined are related to the resources Java thinks it has. I've determined this by running identical Chisel code on different machines and coming up with either success or a range of Java errors ranging from cryptic "next on empty iterator" to explicit "GC overhead limit exceeded" or Java stack space or heap space errors. I expect, though I'm not certain, that there are ways to configure Java and/or Scala/Chisel to open up the limitations I'm running into in some environments. I've searched Chisel documentation for minimum and/or recommended settings and ways to determine these limits and establish new ones to no avail.

It would be great if we could capture some wisdom regarding this probably common newbie difficulty. What Java/Scala settings do I care about? How do I find out what they are? How do I change them? Thanks in advance for your insight.

Also, it would be great for us to start compiling a "hit list" of cryptic Java/Scala errors that can be resource related. The "next on empty iterator" one really had me grasping at straws.

Upvotes: 0

Views: 218

Answers (1)

Ben
Ben

Reputation: 324

Usually I can defeat these sorts of errors by adjusting the arguments passed to java (sometimes grouped in an SBT_OPTS variable). Here are the settings I've cobbled together:

-Xmx4G -Xss4M -XX:MaxPermSize=4G -XX:ReservedCodeCacheSize=64M

Increasing the Xmx and MaxPermSize variables generally seems to the be the most helpful.

Upvotes: 1

Related Questions