Deleted Added
sdiff udiff text old ( 7566:6919df046bba ) new ( 7567:238f99c9f441 )
full compact
1# Copyright (c) 1999-2008 Mark D. Hill and David A. Wood
2# Copyright (c) 2009 The Hewlett-Packard Development Company
3# All rights reserved.
4#
5# Redistribution and use in source and binary forms, with or without
6# modification, are permitted provided that the following conditions are
7# met: redistributions of source code must retain the above copyright
8# notice, this list of conditions and the following disclaimer;

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

233 $c_ident(const Params *p);
234 static int getNumControllers();
235 void init();
236 MessageBuffer* getMandatoryQueue() const;
237 const int & getVersion() const;
238 const std::string toString() const;
239 const std::string getName() const;
240 const MachineType getMachineType() const;
241 void initNetworkPtr(Network* net_ptr) { m_net_ptr = net_ptr; }
242 void print(std::ostream& out) const;
243 void printConfig(std::ostream& out) const;
244 void wakeup();
245 void printStats(std::ostream& out) const;
246 void clearStats();
247 void blockOnQueue(Address addr, MessageBuffer* port);
248 void unblock(Address addr);

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

275int m_buffer_size;
276int m_recycle_latency;
277std::map<std::string, std::string> m_cfg;
278NodeID m_version;
279Network* m_net_ptr;
280MachineID m_machineID;
281bool m_is_blocking;
282std::map<Address, MessageBuffer*> m_block_map;
283static ${ident}_ProfileDumper s_profileDumper;
284${ident}_Profiler m_profiler;
285static int m_num_controllers;
286
287// Internal functions
288''')
289
290 for func in self.functions:

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

373{
374 m_version = p->version;
375 m_transitions_per_cycle = p->transitions_per_cycle;
376 m_buffer_size = p->buffer_size;
377 m_recycle_latency = p->recycle_latency;
378 m_number_of_TBEs = p->number_of_TBEs;
379 m_is_blocking = false;
380''')
381 code.indent()
382
383 #
384 # After initializing the universal machine parameters, initialize the
385 # this machines config parameters. Also detemine if these configuration
386 # params include a sequencer. This information will be used later for
387 # contecting the sequencer back to the L1 cache controller.
388 #

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

616
617const MachineType
618$c_ident::getMachineType() const
619{
620 return MachineType_${ident};
621}
622
623void
624$c_ident::blockOnQueue(Address addr, MessageBuffer* port)
625{
626 m_is_blocking = true;
627 m_block_map[addr] = port;
628}
629
630void
631$c_ident::unblock(Address addr)

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

752 code.indent()
753 code.indent()
754
755 # InPorts
756 #
757 for port in self.in_ports:
758 code.indent()
759 code('// ${ident}InPort $port')
760 code('${{port["c_code_in_port"]}}')
761 code.dedent()
762
763 code('')
764
765 code.dedent()
766 code.dedent()
767 code('''

--- 568 unchanged lines hidden ---