aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2020-02-29 21:36:09 +0100
committerTristan Gingold <tgingold@free.fr>2020-02-29 21:36:42 +0100
commit1d622ed329ba0dfb6a23f4dd487c08e8bb2544db (patch)
treeb001df70786ff749b0230bbec85d9b088dad191c /src/synth
parentd6f06fcd8eadbfa7f7065e29b4650093570c80b6 (diff)
downloadghdl-1d622ed329ba0dfb6a23f4dd487c08e8bb2544db.tar.gz
ghdl-1d622ed329ba0dfb6a23f4dd487c08e8bb2544db.tar.bz2
ghdl-1d622ed329ba0dfb6a23f4dd487c08e8bb2544db.zip
synth-insts: add comments, minor refactoring.
Diffstat (limited to 'src/synth')
-rw-r--r--src/synth/synth-insts.adb7
-rw-r--r--src/synth/synth-insts.ads7
-rw-r--r--src/synth/synthesis.adb1
3 files changed, 6 insertions, 9 deletions
diff --git a/src/synth/synth-insts.adb b/src/synth/synth-insts.adb
index f700e0168..d871b1a11 100644
--- a/src/synth/synth-insts.adb
+++ b/src/synth/synth-insts.adb
@@ -1205,6 +1205,8 @@ package body Synth.Insts is
begin
Root_Instance := Global_Instance;
+ Insts_Interning.Init;
+
if Flags.Flag_Debug_Init then
Synth.Debugger.Debug_Init;
end if;
@@ -1456,9 +1458,4 @@ package body Synth.Insts is
Idx := Idx + 1;
end loop;
end Synth_All_Instances;
-
- procedure Init is
- begin
- Insts_Interning.Init;
- end Init;
end Synth.Insts;
diff --git a/src/synth/synth-insts.ads b/src/synth/synth-insts.ads
index e4ac187f2..91608ff62 100644
--- a/src/synth/synth-insts.ads
+++ b/src/synth/synth-insts.ads
@@ -23,14 +23,15 @@ with Vhdl.Nodes; use Vhdl.Nodes;
with Synth.Context; use Synth.Context;
package Synth.Insts is
- procedure Init;
- procedure Synth_All_Instances;
-
+ -- Create the declaration of the top entity.
procedure Synth_Top_Entity (Global_Instance : Synth_Instance_Acc;
Arch : Node;
Config : Node;
Inst : out Synth_Instance_Acc);
+ -- Synthesize the top entity and all the sub-modules.
+ procedure Synth_All_Instances;
+
-- Apply block configuration CFG to BLK.
-- Must be done before synthesis of BLK.
-- The synthesis of BLK will clear all configuration of it.
diff --git a/src/synth/synthesis.adb b/src/synth/synthesis.adb
index 6583460cf..742f2e8b4 100644
--- a/src/synth/synthesis.adb
+++ b/src/synth/synthesis.adb
@@ -53,7 +53,6 @@ package body Synthesis is
Global_Instance := Make_Base_Instance;
Synth.Values.Init;
- Synth.Insts.Init;
Synth_Top_Entity (Global_Instance, Arch, Config, Inst);
Synth_All_Instances;