nextpnr/himbaechel/uarch/gowin
YRabbit c565e364bc
Gowin. Add the ability to place registers in IOB (#1403)
* Gowin. Add the ability to place registers in IOB

IO blocks have registers: for input, for output and for OutputEnable
signal - IREG, OREG and TREG respectively.

Each of the registers has one implicit non-switched wire, which one
depends on the type of register (IREG has a Q wire, OREG has a D wire).
Although the registers can be activated independently of each other they
share the CLK, ClockEnable and LocalSetReset wires and this places
restrictions on the possible combinations of register types in a single
IO.

Register placement in IO blocks is enabled by specifying the command
line keys --vopt ireg_in_iob, --vopt oreg_in_iob, or --vopt ioreg_in_iob.

It should be noted that specifying these keys leads to attempts to place
registers in IO blocks, but no errors are generated in case of failure.

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>

* Gowin. Registers in IO

Check for unconnected ports.

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>

* Gowin. IO regs. Verbose warnings.

If an attempt to place an FF in an IO block fails, issue a warning
detailing the reason for the failure, whether it is a register type
conflict, a network requirement violation, or a control signal conflict.

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>

* Gowin. BUGFIX. Fix FFs compatibility.

Flipflops with a fixed ClockEnable input cannot coexist with flipflops
with a variable one.

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>

* Gowin. FFs in IO.  Changing diagnostic messages.

Placement modes are still specified by the command line keys
ireg_in_iob/oreg_in_iob/ioreg_in_iob, but also introduces more granular
control in the form of attributes at I/O ports:

  (* NOIOBFF *) - registers are never placed in this IO,

  (* IOBFF *) - registers must be placed in this IO, in case of failure
  a warning (not an error) with the reason for nonplacement is issued,

  _attribute_absence_ - no diagnostics will be issued: managed to place - good, failed - not bad either.

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>

* Gowin. Registers in IO.

Change the logic for handling command line keys and attributes -
attributes allow routines to be placed in IO regardless of global mode.

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>

* Gowin. Registers in IO. Fix style.

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>

---------

Signed-off-by: YRabbit <rabbit@yrabbit.cyou>
2025-01-01 13:11:57 +01:00
..
CMakeLists.txt gowin: Himbaechel. Add GW1NZ-1 BSRAM. 2023-11-26 13:08:09 +01:00
constids.inc Gowin. Add the ability to place registers in IOB (#1403) 2025-01-01 13:11:57 +01:00
cst.cc apicula: add support for magic sip pins (#1370) 2024-10-09 15:16:36 +02:00
cst.h gowin: Himbaechel. Add constraint file processing. 2023-08-31 08:28:09 +02:00
globals.cc Gowin. BUGFIX. Global clock routing. (#1410) 2024-12-31 10:31:03 +01:00
globals.h gowin: Himbaechel. Add a clock router. 2023-08-31 08:28:09 +02:00
gowin_arch_gen.py Gowin. Add Input Edge Monitor (#1396) 2024-11-27 09:57:34 +01:00
gowin_utils.cc Gowin. FFs placement. (#1386) 2024-10-22 12:49:44 +02:00
gowin_utils.h Gowin. FFs placement. (#1386) 2024-10-22 12:49:44 +02:00
gowin.cc Gowin. Add the ability to place registers in IOB (#1403) 2025-01-01 13:11:57 +01:00
gowin.h Gowin. Add the ability to place registers in IOB (#1403) 2025-01-01 13:11:57 +01:00
pack.cc Gowin. Add the ability to place registers in IOB (#1403) 2025-01-01 13:11:57 +01:00
pack.h gowin: Himbaechel. Add ALU. 2023-08-31 08:28:09 +02:00