diff options
author | Tristan Gingold <tgingold@free.fr> | 2019-06-07 06:24:57 +0200 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2019-06-07 07:55:43 +0200 |
commit | 42a04ac8722e89e4454f89ccf540599d10b418f0 (patch) | |
tree | 63421d6f853df90e384b6550b1e3af71e67a23e5 | |
parent | 81f1788b76c4ca8bc4c735754f1858cbb810cf32 (diff) | |
download | ghdl-42a04ac8722e89e4454f89ccf540599d10b418f0.tar.gz ghdl-42a04ac8722e89e4454f89ccf540599d10b418f0.tar.bz2 ghdl-42a04ac8722e89e4454f89ccf540599d10b418f0.zip |
synth: add comments.
-rw-r--r-- | src/synth/synth-context.ads | 9 | ||||
-rw-r--r-- | src/synth/synth-environment.ads | 9 |
2 files changed, 13 insertions, 5 deletions
diff --git a/src/synth/synth-context.ads b/src/synth/synth-context.ads index 660367f4b..1bc36301f 100644 --- a/src/synth/synth-context.ads +++ b/src/synth/synth-context.ads @@ -56,16 +56,21 @@ package Synth.Context is -- Global context. Build_Context : Netlists.Builders.Context_Acc; + -- Create and free the corresponding synth instance. function Make_Instance (Sim_Inst : Block_Instance_Acc) return Synth_Instance_Acc; procedure Free_Instance (Synth_Inst : in out Synth_Instance_Acc); + -- Build the value for object OBJ. + -- KIND must be Wire_Variable or Wire_Signal. procedure Make_Object (Syn_Inst : Synth_Instance_Acc; Kind : Wire_Kind; Obj : Iir); - function Get_Net (Val : Value_Acc) return Net; - + -- Get the value of OBJ. function Get_Value (Inst : Synth_Instance_Acc; Obj : Iir) return Value_Acc; + -- Get a net from a scalar/vector value. This will automatically create + -- a net for literals. + function Get_Net (Val : Value_Acc) return Net; end Synth.Context; diff --git a/src/synth/synth-environment.ads b/src/synth/synth-environment.ads index 6b5c4af31..ca1fcf709 100644 --- a/src/synth/synth-environment.ads +++ b/src/synth/synth-environment.ads @@ -41,9 +41,12 @@ package Synth.Environment is -- nature of a wire as the assignment semantic is not the same (a variable -- assignment overwrite the old value, while a signal assignment is -- effective at the next cycle). - type Wire_Kind is (Wire_None, - Wire_Signal, Wire_Variable, - Wire_Input, Wire_Output, Wire_Inout); + type Wire_Kind is + ( + Wire_None, + Wire_Signal, Wire_Variable, + Wire_Input, Wire_Output, Wire_Inout + ); type Assign is new Uns32; No_Assign : constant Assign := 0; |