OpenASIP 2.2
Loading...
Searching...
No Matches
CentralizedControlICGenerator.hh
Go to the documentation of this file.
1/*
2 Copyright (c) 2002-2009 Tampere University.
3
4 This file is part of TTA-Based Codesign Environment (TCE).
5
6 Permission is hereby granted, free of charge, to any person obtaining a
7 copy of this software and associated documentation files (the "Software"),
8 to deal in the Software without restriction, including without limitation
9 the rights to use, copy, modify, merge, publish, distribute, sublicense,
10 and/or sell copies of the Software, and to permit persons to whom the
11 Software is furnished to do so, subject to the following conditions:
12
13 The above copyright notice and this permission notice shall be included in
14 all copies or substantial portions of the Software.
15
16 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
19 THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21 FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22 DEALINGS IN THE SOFTWARE.
23 */
24/**
25 * @file CentralizedControlICGenerator.hh
26 *
27 * Declaration of CentralizedControlICGenerator class.
28 *
29 * @author Lasse Laasonen 2005 (lasse.laasonen-no.spam-tut.fi)
30 * @note rating: red
31 */
32
33#ifndef TTA_CENTRALIZED_CONTROL_IC_GENERATOR_HH
34#define TTA_CENTRALIZED_CONTROL_IC_GENERATOR_HH
35
36#include <string>
37#include <map>
38
39#include "Exception.hh"
40
41namespace ProGe {
42 class NetlistPort;
43}
44
45namespace TTAMachine {
46 class Socket;
47 class Bus;
48 class Port;
49 class Segment;
50}
51
53public:
56
57 ProGe::NetlistPort& simmDataPort(const std::string& busName) const;
58 ProGe::NetlistPort& simmCntrlPort(const std::string& busName) const;
60 const std::string& socketName) const;
62 const std::string& socketName) const;
63 bool hasGlockPort() const;
65
67 const TTAMachine::Socket& socket,
68 const TTAMachine::Segment& segment) const = 0;
69
71 const TTAMachine::Socket& socket,
72 const TTAMachine::Port& port) const = 0;
73
75 const TTAMachine::Socket& socket,
76 const TTAMachine::Segment& segment) const = 0;
77
78protected:
79 void mapSImmDataPort(const std::string& busName, ProGe::NetlistPort& port);
80 void mapSImmCntrlPort(const std::string& busName, ProGe::NetlistPort& port);
82 const std::string& socketName,
83 ProGe::NetlistPort& port);
85 const std::string& socketName,
86 ProGe::NetlistPort& port);
88
89private:
90 typedef std::map<std::string, ProGe::NetlistPort*> NetlistPortMap;
91
92 /// Maps the short immediate data ports for buses.
94 /// Maps the short immediate control ports for buses.
96 /// Maps the data ports of sockets.
98 /// Maps the bus control ports of sockets.
100 /// Maps the data control ports of sockets.
102 /// (optional) Glock port
104};
105
106#endif
virtual int inputSocketControlValue(const TTAMachine::Socket &socket, const TTAMachine::Segment &segment) const =0
ProGe::NetlistPort & busCntrlPortOfSocket(const std::string &socketName) const
ProGe::NetlistPort & simmCntrlPort(const std::string &busName) const
NetlistPortMap dataCntrlPortMap_
Maps the data control ports of sockets.
NetlistPortMap simmCntrlPortMap_
Maps the short immediate control ports for buses.
virtual int outputSocketDataControlValue(const TTAMachine::Socket &socket, const TTAMachine::Port &port) const =0
virtual int outputSocketCntrlPinForSegment(const TTAMachine::Socket &socket, const TTAMachine::Segment &segment) const =0
ProGe::NetlistPort & dataCntrlPortOfSocket(const std::string &socketName) const
NetlistPortMap busCntrlPortMap_
Maps the bus control ports of sockets.
void mapDataCntrlPortOfSocket(const std::string &socketName, ProGe::NetlistPort &port)
std::map< std::string, ProGe::NetlistPort * > NetlistPortMap
void setGlockPort(ProGe::NetlistPort &glockPort)
NetlistPortMap simmDataPortMap_
Maps the short immediate data ports for buses.
void mapSImmDataPort(const std::string &busName, ProGe::NetlistPort &port)
ProGe::NetlistPort & simmDataPort(const std::string &busName) const
void mapSImmCntrlPort(const std::string &busName, ProGe::NetlistPort &port)
NetlistPortMap socketDataPortMap_
Maps the data ports of sockets.
void mapBusCntrlPortOfSocket(const std::string &socketName, ProGe::NetlistPort &port)
ProGe::NetlistPort * glockPort_
(optional) Glock port
Definition FUGen.hh:54