aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2020-05-02 08:01:22 +0200
committerTristan Gingold <tgingold@free.fr>2020-05-02 08:01:22 +0200
commit8c2dc4b2082ec2bf6f28f44218521f4fbe9bf9d7 (patch)
tree8f84001aef5120c9dafbc5cc4ec54694e44a357b
parentaeb47655ddfed9d3fd85c4986d21a60f83b9a8c6 (diff)
downloadghdl-8c2dc4b2082ec2bf6f28f44218521f4fbe9bf9d7.tar.gz
ghdl-8c2dc4b2082ec2bf6f28f44218521f4fbe9bf9d7.tar.bz2
ghdl-8c2dc4b2082ec2bf6f28f44218521f4fbe9bf9d7.zip
synth-context: remove unused bit0/bit1 nets.
-rw-r--r--src/synth/synth-context.adb20
-rw-r--r--src/synth/synth-context.ads8
2 files changed, 2 insertions, 26 deletions
diff --git a/src/synth/synth-context.adb b/src/synth/synth-context.adb
index 430489729..822acd731 100644
--- a/src/synth/synth-context.adb
+++ b/src/synth/synth-context.adb
@@ -46,9 +46,7 @@ package body Synth.Context is
Base := new Base_Instance_Type'(Builder => Build_Context,
Top_Module => Top_Module,
- Cur_Module => No_Module,
- Bit0 => No_Net,
- Bit1 => No_Net);
+ Cur_Module => No_Module);
Res := new Synth_Instance_Type'(Max_Objs => Global_Info.Nbr_Objects,
Is_Const => False,
@@ -124,16 +122,12 @@ package body Synth.Context is
begin
Base := new Base_Instance_Type'(Builder => Prev_Base.Builder,
Top_Module => Prev_Base.Top_Module,
- Cur_Module => M,
- Bit0 => No_Net,
- Bit1 => No_Net);
+ Cur_Module => M);
Builders.Set_Parent (Base.Builder, M);
Self_Inst := Create_Self_Instance (M);
pragma Unreferenced (Self_Inst);
- Base.Bit0 := Build_Const_UB32 (Base.Builder, 0, 1);
- Base.Bit1 := Build_Const_UB32 (Base.Builder, 1, 1);
Inst.Base := Base;
end Set_Instance_Module;
@@ -173,16 +167,6 @@ package body Synth.Context is
return Inst.Base.Builder;
end Get_Build;
- function Get_Inst_Bit0 (Inst : Synth_Instance_Acc) return Net is
- begin
- return Inst.Base.Bit0;
- end Get_Inst_Bit0;
-
- function Get_Inst_Bit1 (Inst : Synth_Instance_Acc) return Net is
- begin
- return Inst.Base.Bit1;
- end Get_Inst_Bit1;
-
function Get_Instance_Const (Inst : Synth_Instance_Acc) return Boolean is
begin
return Inst.Is_Const;
diff --git a/src/synth/synth-context.ads b/src/synth/synth-context.ads
index ca15a6c66..6196257b8 100644
--- a/src/synth/synth-context.ads
+++ b/src/synth/synth-context.ads
@@ -80,12 +80,6 @@ package Synth.Context is
function Get_Instance_Module (Inst : Synth_Instance_Acc) return Module;
pragma Inline (Get_Instance_Module);
- -- Each base instance creates bit0 and bit1, which are used for control
- -- flow.
- function Get_Inst_Bit0 (Inst : Synth_Instance_Acc) return Net;
- function Get_Inst_Bit1 (Inst : Synth_Instance_Acc) return Net;
- pragma Inline (Get_Inst_Bit0, Get_Inst_Bit1);
-
-- Start the definition of module M (using INST).
procedure Set_Instance_Module (Inst : Synth_Instance_Acc; M : Module);
@@ -172,8 +166,6 @@ private
Top_Module : Module;
Cur_Module : Module;
- Bit0 : Net;
- Bit1 : Net;
end record;
type Base_Instance_Acc is access Base_Instance_Type;