Unfortunately i had an old FPGA project from a guy who no longer works here dropped in my lap. It has some stability issues with it that need fixing and some of it is quite a mess.
Its running on a Lattice MachXO2 (And its pretty full too) with Symplify Pro in VHDL2008
So so after a bit of timing tweaking didn't fix it i decided to take a deeper look using a logic analyzer. The juicy stuff is burred down in the hierarchy of submodules, so i needed a way to easily get one of those signals out to a IO pin. And so the adventure begins...
1) Just use a IDE tool:
Altera has this nice tool in the IDE where you just add signals to a list and it then muxes this big list of signals out to a set of IO pins by JTAG commands... bish bosh add a few signals to a list, compile it and away we go... well.... Lattice Diamond IDE has no such tool. It can only build a logic analyzer on the FPGA using memory blocks, but my FPGA is close to full already. And that tool sucks anyway even when it does work (Altera SignalTap works way better).
2) Do it in VHDL code:
I barely even know any VHDL (I always used Verilog) but how hard can it be?
Cool there is a thing called hierarchical references (just like in Verilog):
val <= <<signal .top.cpu.alu.val : busType>>;
Well.. nope. The compiler throws its arms up as soon as it gets to the "<<" part even tho it is in VHDL2008 mode and this is a VHDL2008 feature. Turns out not everyone supports this
3) Fine i will do it in Verilog instead!
SystemVerilog is supported. Hierarchical references are also a pretty standard part of the feature set here in Verilog land so they do actually work in compilers. And i get to work with a language i actually know how to use. Perfect! So i add a new .sv source file, connect it up into the VHDL top level file, and now just wire the .sv file to my DUT.
Well... Noooope. Turns out Verilog hierarchical references only work on modules coded in Verilog.
At this point i have been at it for hours and am finding it rather ridiculous how hard it is to just simply get a random burried signal out to a pin. I can do it in Altera tools easy, i can do it in Verilog easy. But HOW does one do this in VHDL on Lattice Diamond + Synplify.