1-- Std.Env package declaration. This file is part of GHDL. 2-- This file was written from the clause 14.3 of the VHDL LRM. 3-- Copyright (C) 2014 Tristan Gingold 4-- 5-- This program is free software: you can redistribute it and/or modify 6-- it under the terms of the GNU General Public License as published by 7-- the Free Software Foundation, either version 2 of the License, or 8-- (at your option) any later version. 9-- 10-- This program is distributed in the hope that it will be useful, 11-- but WITHOUT ANY WARRANTY; without even the implied warranty of 12-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13-- GNU General Public License for more details. 14-- 15-- You should have received a copy of the GNU General Public License 16-- along with this program. If not, see <gnu.org/licenses>. 17 18package body Env is 19 procedure control_simulation (Is_Stop : Boolean; 20 Has_Status : Boolean; 21 Status : Integer); 22 attribute foreign of control_simulation : procedure is "GHDL intrinsic"; 23 24 procedure control_simulation (Is_Stop : Boolean; 25 Has_Status : Boolean; 26 Status : Integer) is 27 begin 28 assert false report "must not be called" severity failure; 29 end control_simulation; 30 31 procedure Stop (Status : Integer) is 32 begin 33 control_simulation (True, True, Status); 34 end Stop; 35 36 procedure Stop is 37 begin 38 control_simulation (True, False, -1); 39 end Stop; 40 41 procedure Finish (status : integer) is 42 begin 43 control_simulation (False, True, Status); 44 end Finish; 45 46 procedure Finish is 47 begin 48 control_simulation (False, False, -1); 49 end Finish; 50 51 function Get_Resolution_Limit return Delay_Length; 52 attribute foreign of Get_Resolution_Limit : function is "GHDL intrinsic"; 53 54 function Get_Resolution_Limit return Delay_Length is 55 begin 56 assert false report "must not be called" severity failure; 57 end Get_Resolution_Limit; 58 59 function Resolution_Limit return Delay_Length is 60 begin 61 return Get_Resolution_Limit; 62 end Resolution_Limit; 63end package body Env; 64