aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth/elab-vhdl_context.ads
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2022-08-28 12:27:45 +0200
committerTristan Gingold <tgingold@free.fr>2022-09-02 02:31:06 +0200
commit8a8f3d867598a1f9e3125c9d0648ae20a7144253 (patch)
tree9802e5c0c5e68e92acbc5c41caf3025fbe1efe02 /src/synth/elab-vhdl_context.ads
parent91303467eac522662572d9106e2a3cb724b24a0d (diff)
downloadghdl-8a8f3d867598a1f9e3125c9d0648ae20a7144253.tar.gz
ghdl-8a8f3d867598a1f9e3125c9d0648ae20a7144253.tar.bz2
ghdl-8a8f3d867598a1f9e3125c9d0648ae20a7144253.zip
synth: use areapools
Diffstat (limited to 'src/synth/elab-vhdl_context.ads')
-rw-r--r--src/synth/elab-vhdl_context.ads13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/synth/elab-vhdl_context.ads b/src/synth/elab-vhdl_context.ads
index 404325742..e02ed714e 100644
--- a/src/synth/elab-vhdl_context.ads
+++ b/src/synth/elab-vhdl_context.ads
@@ -17,6 +17,7 @@
-- along with this program. If not, see <gnu.org/licenses>.
with Types; use Types;
+with Areapools;
with Vhdl.Annotations; use Vhdl.Annotations;
with Vhdl.Nodes; use Vhdl.Nodes;
@@ -145,10 +146,17 @@ package Elab.Vhdl_Context is
procedure Mutate_Object
(Syn_Inst : Synth_Instance_Acc; Decl : Node; Vt : Valtyp);
+ -- Save an areapool mark (likely the instance_pool).
+ -- Used by for-loop.
+ procedure Create_Object_Marker
+ (Syn_Inst : Synth_Instance_Acc; N : Node; Pool : Areapools.Areapool_Acc);
+
type Destroy_Type is limited private;
procedure Destroy_Init (D : out Destroy_Type;
Syn_Inst : Synth_Instance_Acc);
procedure Destroy_Object (D : in out Destroy_Type; Decl : Node);
+ procedure Destroy_Marker
+ (D : in out Destroy_Type; N : Node; Pool : Areapools.Areapool_Acc);
procedure Destroy_Finish (D : in out Destroy_Type);
-- Get the value of OBJ.
@@ -197,7 +205,8 @@ private
Obj_None,
Obj_Object,
Obj_Subtype,
- Obj_Instance
+ Obj_Instance,
+ Obj_Marker
);
type Obj_Type (Kind : Obj_Kind := Obj_None) is record
@@ -210,6 +219,8 @@ private
T_Typ : Type_Acc;
when Obj_Instance =>
I_Inst : Synth_Instance_Acc;
+ when Obj_Marker =>
+ M_Mark : Areapools.Mark_Type;
end case;
end record;