eventq.cc (5695:82f3a613cc58) eventq.cc (5768:ba6f2477d870)
1/*
2 * Copyright (c) 2000-2005 The Regents of The University of Michigan
3 * Copyright (c) 2008 The Hewlett-Packard Development Company
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are
8 * met: redistributions of source code must retain the above copyright

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

52// cycle, before the pipeline simulation is performed.
53//
54EventQueue mainEventQueue("Main Event Queue");
55
56#ifndef NDEBUG
57Counter Event::instanceCounter = 0;
58#endif
59
1/*
2 * Copyright (c) 2000-2005 The Regents of The University of Michigan
3 * Copyright (c) 2008 The Hewlett-Packard Development Company
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are
8 * met: redistributions of source code must retain the above copyright

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

52// cycle, before the pipeline simulation is performed.
53//
54EventQueue mainEventQueue("Main Event Queue");
55
56#ifndef NDEBUG
57Counter Event::instanceCounter = 0;
58#endif
59
60Event::~Event()
61{
62}
63
64const std::string
65Event::name() const
66{
67#ifndef NDEBUG
68 return csprintf("Event_%d", instance);
69#else
70 return csprintf("Event_%x", (uintptr_t)this);
71#endif
72}
73
74
60Event *
61Event::insertBefore(Event *event, Event *curr)
62{
63 // Either way, event will be the top element in the 'in bin' list
64 // which is the pointer we need in order to look into the list, so
65 // we need to insert that into the bin list.
66 if (!curr || *event < *curr) {
67 // Insert the event before the current list since it is in the future.

--- 322 unchanged lines hidden ---
75Event *
76Event::insertBefore(Event *event, Event *curr)
77{
78 // Either way, event will be the top element in the 'in bin' list
79 // which is the pointer we need in order to look into the list, so
80 // we need to insert that into the bin list.
81 if (!curr || *event < *curr) {
82 // Insert the event before the current list since it is in the future.

--- 322 unchanged lines hidden ---