Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 76 lines (62 sloc) 2.072 kb
8f68a07 Add support for delayed non-blocking assignments.
steve authored
1 #ifndef __PDelays_H
2 #define __PDelays_H
3 /*
13fb07d @caryr Add support for only two variable delays and add delay checks.
caryr authored
4 * Copyright (c) 1999-2010 Stephen Williams (steve@icarus.com)
8f68a07 Add support for delayed non-blocking assignments.
steve authored
5 *
6 * This source code is free software; you can redistribute it
7 * and/or modify it in source code form under the terms of the GNU
8 * General Public License as published by the Free Software
9 * Foundation; either version 2 of the License, or (at your option)
10 * any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
f5aafc3 @arunpersaud updated FSF-address
arunpersaud authored
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
8f68a07 Add support for delayed non-blocking assignments.
steve authored
20 */
21
22 # include "svector.h"
23 # include <string>
cced1e7 @steveicarus Remove some uses of the svector template.
authored
24 # include <list>
4f0ffa2 Compiler portability.
steve authored
25 # include <iostream>
65020bc Use the iosfwd header if available.
steve authored
26
4f0ffa2 Compiler portability.
steve authored
27 #ifdef __GNUC__
28 #if __GNUC__ > 2
29 using namespace std;
30 #endif
65020bc Use the iosfwd header if available.
steve authored
31 #endif
32
8f68a07 Add support for delayed non-blocking assignments.
steve authored
33 class Design;
82831ea Use NetScope instead of string for scope path.
steve authored
34 class NetScope;
58f182a Node delays can be more general expressions in structural contexts.
steve authored
35 class NetExpr;
8f68a07 Add support for delayed non-blocking assignments.
steve authored
36 class PExpr;
37
38 /*
39 * Various PForm objects can carry delays. These delays include rise,
40 * fall and decay times. This class arranges to carry the triplet.
41 */
42 class PDelays {
43
44 public:
45 PDelays();
46 ~PDelays();
47
000d187 Do not delete delay expressions of UDP instances.
steve authored
48 /* Set the delay expressions. If the delete_flag is true, then
49 this object takes ownership of the expressions, and will
50 delete it in the destructor. */
8f68a07 Add support for delayed non-blocking assignments.
steve authored
51 void set_delay(PExpr*);
cced1e7 @steveicarus Remove some uses of the svector template.
authored
52 void set_delays(const list<PExpr*>*del, bool delete_flag=true);
8f68a07 Add support for delayed non-blocking assignments.
steve authored
53
13fb07d @caryr Add support for only two variable delays and add delay checks.
caryr authored
54 unsigned delay_count() const;
55
82831ea Use NetScope instead of string for scope path.
steve authored
56 void eval_delays(Design*des, NetScope*scope,
58f182a Node delays can be more general expressions in structural contexts.
steve authored
57 NetExpr*&rise_time,
58 NetExpr*&fall_time,
368c27c Handle complex net node delays.
steve authored
59 NetExpr*&decay_time,
60 bool as_nets_flag =false) const;
8f68a07 Add support for delayed non-blocking assignments.
steve authored
61
62 void dump_delays(ostream&out) const;
63
64 private:
65 PExpr* delay_[3];
000d187 Do not delete delay expressions of UDP instances.
steve authored
66 bool delete_flag_;
8f68a07 Add support for delayed non-blocking assignments.
steve authored
67
68 private: // not implemented
69 PDelays(const PDelays&);
70 PDelays& operator= (const PDelays&);
71 };
72
73 ostream& operator << (ostream&o, const PDelays&);
74
75 #endif
Something went wrong with that request. Please try again.