Deleted Added
sdiff udiff text old ( 9987:7efa5d115a4e ) new ( 10000:99bd071911cf )
full compact
1/*
2 * Copyright (c) 2012-2013 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software
9 * licensed hereunder. You may use the software subject to the license
10 * terms below provided that you ensure that this notice is replicated

--- 19 unchanged lines hidden (view full) ---

30 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
31 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
32 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
33 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36 *
37 * Authors: Andreas Hansson
38 */
39
40/**
41 * @file
42 * ClockedObject declaration and implementation.
43 */
44
45#ifndef __SIM_CLOCKED_OBJECT_HH__

--- 67 unchanged lines hidden (view full) ---

113
114 /**
115 * Create a clocked object and set the clock domain based on the
116 * parameters.
117 */
118 ClockedObject(const ClockedObjectParams* p) :
119 SimObject(p), tick(0), cycle(0), clockDomain(*p->clk_domain)
120 {
121 }
122
123 /**
124 * Virtual destructor due to inheritance.
125 */
126 virtual ~ClockedObject() { }
127
128 /**

--- 6 unchanged lines hidden (view full) ---

135 Cycles elapsedCycles(divCeil(curTick(), clockPeriod()));
136 cycle = elapsedCycles;
137 tick = elapsedCycles * clockPeriod();
138 }
139
140 public:
141
142 /**
143 * Determine the tick when a cycle begins, by default the current
144 * one, but the argument also enables the caller to determine a
145 * future cycle.
146 *
147 * @param cycles The number of cycles into the future
148 *
149 * @return The tick when the clock edge occurs
150 */

--- 49 unchanged lines hidden ---