OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [orpsocv2/] [bench/] [sysc/] [include/] [TraceSC.h] - Blame information for rev 864

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 6 julius
// ----------------------------------------------------------------------------
2
 
3
// SystemC trace header
4
 
5
// Copyright (C) 2008  Embecosm Limited <info@embecosm.com>
6
 
7
// Contributor Jeremy Bennett <jeremy.bennett@embecosm.com>
8
 
9
// This file is part of the cycle accurate model of the OpenRISC 1000 based
10
// system-on-chip, ORPSoC, built using Verilator.
11
 
12
// This program is free software: you can redistribute it and/or modify it
13
// under the terms of the GNU Lesser General Public License as published by
14
// the Free Software Foundation, either version 3 of the License, or (at your
15
// option) any later version.
16
 
17
// This program is distributed in the hope that it will be useful, but WITHOUT
18
// ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
19
// FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
20
// License for more details.
21
 
22
// You should have received a copy of the GNU Lesser General Public License
23
// along with this program.  If not, see <http://www.gnu.org/licenses/>.
24
 
25
// ----------------------------------------------------------------------------
26
 
27
// $Id: TraceSC.h 302 2009-02-13 17:22:07Z jeremy $
28
 
29
// Drives the Verilator VCD trace interface
30
 
31
#ifndef TRACE_SC__H
32
#define TRACE_SC__H
33
 
34
#include "Vorpsoc_top.h"
35
 
36
#if VM_TRACE
37
#include <SpTraceVcdC.h>
38
#endif
39
 
40
//! Class to drive the Verilator VCD trace interface.
41
 
42
//! Substantive code is only implemented if trace is enabled.
43
 
44 462 julius
class TraceSC:public sc_core::sc_module {
45 6 julius
public:
46
 
47 462 julius
        // Constructor and destructor
48
        TraceSC(sc_core::sc_module_name name,
49
                Vorpsoc_top * _traceTarget, int argc, char *argv[]);
50
        ~TraceSC();
51 6 julius
 
52 462 julius
        // Method to drive the trace
53
        void driveTrace();
54 6 julius
 
55 462 julius
        // VCD dump controling vars
56
        int dump_start_delay, dump_stop_set;
57
        int dumping_now;
58
        sc_time dump_start, dump_stop;
59 6 julius
 
60 462 julius
        /* The port */
61
        //sc_in<bool>   clk;
62
 
63 6 julius
private:
64
 
65 462 julius
        //! The ORPSoC module we are tracing
66
        Vorpsoc_top * traceTarget;
67 6 julius
 
68
#if VM_TRACE
69 462 julius
        //! The System Perl Trace file
70
        SpTraceVcdCFile *spTraceFile;
71 6 julius
#endif
72
 
73 462 julius
        // Set the time resolution
74
        void setSpTimeResolution(sc_time t);
75 6 julius
 
76 462 julius
};                              // TraceSC ()
77 6 julius
 
78 462 julius
#endif // TRACE_SC__H

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.