2 * Copyright 2018 Google, Inc.
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are
6 * met: redistributions of source code must retain the above copyright
7 * notice, this list of conditions and the following disclaimer;
8 * redistributions in binary form must reproduce the above copyright
9 * notice, this list of conditions and the following disclaimer in the
10 * documentation and/or other materials provided with the distribution;
11 * neither the name of the copyright holders nor the names of its
12 * contributors may be used to endorse or promote products derived from
13 * this software without specific prior written permission.
15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
16 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
17 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
18 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
19 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
21 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 #include "base/logging.hh"
31 #include "systemc/ext/channel/sc_clock.hh"
32 #include "systemc/ext/core/sc_module.hh" // for sc_gen_unique_name
37 sc_clock::sc_clock() :
38 sc_interface(), sc_signal
<bool>(sc_gen_unique_name("clock"))
40 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
43 sc_clock::sc_clock(const char *name
) : sc_interface(), sc_signal
<bool>(name
)
45 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
48 sc_clock::sc_clock(const char *name
, const sc_time
&period
,
49 double duty_cycle
, const sc_time
&start_time
,
52 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
55 sc_clock::sc_clock(const char *name
, double period_v
, sc_time_unit period_tu
,
58 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
61 sc_clock::sc_clock(const char *name
, double period_v
, sc_time_unit period_tu
,
62 double duty_cycle
, double start_time_v
,
63 sc_time_unit start_time_tu
, bool posedge_first
)
65 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
68 sc_clock::sc_clock(const char *name
, double period
, double duty_cycle
,
69 double start_time
, bool posedge_first
)
71 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
74 sc_clock::~sc_clock() {}
77 sc_clock::write(const bool &)
79 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
83 sc_clock::period() const
85 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
86 return *(const sc_time
*)nullptr;
90 sc_clock::duty_cycle() const
92 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
97 sc_clock::start_time() const
99 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
100 return *(const sc_time
*)nullptr;
104 sc_clock::posedge_first() const
106 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
111 sc_clock::time_stamp()
113 warn("%s not implemented.\n", __PRETTY_FUNCTION__
);
114 return *(const sc_time
*)nullptr;
117 const char *sc_clock::kind() const { return "sc_clock"; }
119 void sc_clock::before_end_of_elaboration() {}
121 } // namespace sc_core