yosys/kernel
Jannis Harder d8687e87b1 kernel: Avoid including files outside include guards
This adjusts the way the headers kernel/{yosys,rtlil,register,log}.h
include each other to avoid the need of including headers outside of
include guards as well as avoiding the inclusion of rtlil.h in the
middle of yosys.h with rtlil.h depending on the prefix of yosys.h, and
the suffix of yosys.h depending on rtlil.h.

To do this I moved some of the declaration in yosys.h into a new header
yosys_common.h. I'm not sure if that is strictly necessary.

Including any of these files still results in the declarations of all
these headers being included, so this shouldn't be a breaking change for
any passes or external plugins.

My main motivation for this is that ccls's (clang based language server)
include guard handling gets confused by the previous way the includes
were done. It often ends up treating the include guard as a generic
disabled preprocessor conditional, breaking navigation and highlighting
for the core RTLIL data structures.

Additionally I think avoiding cyclic includes in the middle of header
files that depend on includes being outside of include guards will also
be less confusing for developers reading the code, not only for tools
like ccls.
2024-04-02 16:53:56 +02:00
..
binding.cc Generate an RTLIL representation of bind constructs 2021-08-13 17:11:35 -06:00
binding.h Generate an RTLIL representation of bind constructs 2021-08-13 17:11:35 -06:00
bitpattern.h Fixing old e-mail addresses and deadnames 2021-06-08 00:39:36 +02:00
calc.cc Add bitwise `$bweqx` and `$bwmux` cells 2022-11-30 18:24:35 +01:00
cellaigs.cc cellaigs: Drop initializer list in call to `IdString::in` 2023-08-14 11:42:19 +02:00
cellaigs.h Fixing old e-mail addresses and deadnames 2021-06-08 00:39:36 +02:00
celledges.cc celledges: Register async FF paths 2024-03-11 10:45:36 +01:00
celledges.h Fixing old e-mail addresses and deadnames 2021-06-08 00:39:36 +02:00
celltypes.h Add builtin celltype $scopeinfo 2024-02-06 17:51:24 +01:00
consteval.h Remove set but unused variable 2022-05-27 12:37:03 +02:00
constids.inc Add new `$check` cell to represent assertions with a message. 2024-02-01 20:10:39 +01:00
cost.h Fixing old e-mail addresses and deadnames 2021-06-08 00:39:36 +02:00
driver.cc driver: Fix crashes on missing cli arguments 2024-02-12 14:56:23 +01:00
ff.cc Add the $anyinit cell and the formalff pass 2022-08-16 13:37:30 +02:00
ff.h Add the $anyinit cell and the formalff pass 2022-08-16 13:37:30 +02:00
ffinit.h Add new helper class for merging FFs into cells, use for memory_dff. 2021-05-23 14:46:59 +02:00
ffmerge.cc Fix a regression from #3035. 2021-10-08 15:44:07 +02:00
ffmerge.h Add new helper class for merging FFs into cells, use for memory_dff. 2021-05-23 14:46:59 +02:00
fmt.cc fmt: if enabled, group padding zeroes. 2024-04-02 12:13:22 +02:00
fmt.h fmt,cxxrtl: add option to group digits in numbers. 2024-04-02 12:13:22 +02:00
fstdata.cc Fixes for some of clang scan-build detected issues 2023-01-17 12:58:08 +01:00
fstdata.h Start restoring memory state from VCD/FST 2022-05-04 10:41:04 +02:00
hashlib.h hashlib: Add missing `stdint.h` include 2024-02-08 14:27:12 +00:00
json.cc Support for BTOR witness to Yosys witness conversion 2023-01-11 18:07:16 +01:00
json.h Support for BTOR witness to Yosys witness conversion 2023-01-11 18:07:16 +01:00
log.cc change verific log callback api 2023-11-01 08:13:27 +01:00
log.h kernel: Avoid including files outside include guards 2024-04-02 16:53:56 +02:00
macc.h Fixing old e-mail addresses and deadnames 2021-06-08 00:39:36 +02:00
mem.cc mem: only import attributes from ports if the memory doesn't have them yet 2023-10-30 16:31:53 +01:00
mem.h Add proc_rom pass. 2022-05-13 00:37:14 +02:00
modtools.h remove template declaration that stops function from being used 2023-01-11 16:09:05 +01:00
qcsat.cc Add $bmux and $demux cells. 2022-01-28 23:34:41 +01:00
qcsat.h Refactor common parts of SAT-using optimizations into a helper. 2021-08-09 16:54:35 +02:00
register.cc Merge branch 'origin/master' into krys/docs 2024-03-18 10:39:30 +13:00
register.h kernel: Avoid including files outside include guards 2024-04-02 16:53:56 +02:00
rtlil.cc Add builtin celltype $scopeinfo 2024-02-06 17:51:24 +01:00
rtlil.h kernel: Avoid including files outside include guards 2024-04-02 16:53:56 +02:00
satgen.cc Add builtin celltype $scopeinfo 2024-02-06 17:51:24 +01:00
satgen.h sat: Add -set-def-formal option to force defined $any* outputs 2022-11-28 14:50:52 +01:00
scopeinfo.cc Add scopeinfo index/lookup utils 2024-02-06 18:01:26 +01:00
scopeinfo.h Add scopeinfo index/lookup utils 2024-02-06 18:01:26 +01:00
sigtools.h Fixing old e-mail addresses and deadnames 2021-06-08 00:39:36 +02:00
timinginfo.h sta: very crude static timing analysis pass 2021-11-25 17:20:27 +01:00
utils.h utils: Save detected loops with their nodes in-order 2024-03-11 10:43:49 +01:00
yosys.cc Tweak the FreeBSD version of proc_self_dirname() to work on NetBSD use it. 2024-03-03 07:54:39 -08:00
yosys.h kernel: Avoid including files outside include guards 2024-04-02 16:53:56 +02:00
yosys_common.h kernel: Avoid including files outside include guards 2024-04-02 16:53:56 +02:00
yw.cc Remove a statement without effect. 2023-04-17 10:53:05 -07:00
yw.h sim/formalff: Clock handling for yw cosim 2023-01-11 18:07:16 +01:00