chipsalliance / rocket-chip

Rocket Chip Generator
Other
3.25k stars 1.13k forks source link

Unable to compile using make in vsim directory #21

Closed nitish2112 closed 8 years ago

nitish2112 commented 9 years ago

Hi,

I am trying to make vcs simulator but getting the following errors:

Warning-[ERASM] Argument size mismatch /ufs/vlsi/nks45/RISCV/rocket-chip/vsrc/rocketTestHarness.v, 396 "htif_fini(1'b1);" External routine argument size mismatch. Use +lint=ERASM-L for details.

50 modules and 2 UDPs read. However, due to incremental compilation, no re-compilation is necessary. make[1]: Entering directory /ufs/vlsi/nks45/RISCV/rocket-chip/vsim/csrc' make[1]: Warning: Filefilelist.cu' has modification time 2 s in the future ld -shared -o .//../simv-DefaultVLSIConfig.daidir//_csrc0.so objs/udps/zTfCi.o objs/udps/iMDw8.o rm -f _csrc0.so /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsGroupGetActive' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tomiHeapProf_init' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to printIclBeginMarker' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsCallocFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to executeTclProc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsCheckMallocFromGroupFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to waitForUserInput' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference tostoreSimLogFileHandle' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsSetOutOfMemoryRoutine' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference toregisterPreRestartFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to initNativeUcli' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsCheckReallocFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsNamedAllocateGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference toprintIclEndMarker' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsCallocFromGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsHighMemory' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsStrdupFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsCheckMallocFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsGetMemBytes' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsMallocFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsReallocFromGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsCheckCallocFromGroupFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to execMhpiTclCommand' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsMallocFromGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsSetHook' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsFreeFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsMemSetLogFileHandle' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsFreeGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsOutOfMem' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsNamedPushGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to miHeapOn' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference tosetIclCmd_ResVars' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to setEnvPair' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsLowMemory' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsCheckFreeFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference toregisterOutOfMemHandle' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to vcsRunUcliErrorScript' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference toshutDownNativeUcli' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsMemManagerIsActive' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsDoStackUnwind' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to breakNativeTclLoop' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsCheckCallocFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsNamedPopGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference tostoreMiscTfCb' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsCurrentGroup' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference toisUcliEngineStarted' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsPrintf' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsCheckStrdupFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsucli.so: undefined reference to execMhpiTclCommandNoPrint' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsGetHook' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference to snpsReallocFunc' /ufs/cad/synopsys/vcs-K-2015.09/linux64/lib/libvcsnew.so: undefined reference tosnpsGroupSize' collect2: error: ld returned 1 exit status make[1]: * [product_timestamp] Error 1 make[1]: Leaving directory `/ufs/vlsi/nks45/RISCV/rocket-chip/vsim/csrc' Make exited with status 2 make: * [simv-DefaultVLSIConfig] Error 2

palmer-dabbelt commented 8 years ago

We can build with VCS versions close to that one, so I think it's probably a configuration issue on your end. If you have more info, feel free to re-open this, but I think SolvNet might be the right place to get a fix.

kkiningh commented 7 years ago

I had a similar problem. The relevant Solvnet article suggested that I had conflicting versions of VCS installed, which was not a problem in my case.

The issue for me was that gcc by default uses slightly different linker options on Debian/Ubuntu than on Fedora (which is what VCS is tested on). To fix this it I added -LD_FLAGS -Wl,--no-as-needed to the list of vcs options. That means a full command would look something like

vcs -full64 +v2k top.v -LDFLAGS -Wl,--no-as-needed For more details on this see this SO post.