StateMachine.py (11084:ee2fcca7b58a) | StateMachine.py (11095:12c36d719139) |
---|---|
1# Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 2# Copyright (c) 2009 The Hewlett-Packard Development Company 3# Copyright (c) 2013 Advanced Micro Devices, Inc. 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 --- 182 unchanged lines hidden (view full) --- 191 self.table = table 192 193 # determine the port->msg buffer mappings 194 def getBufferMaps(self, ident): 195 msg_bufs = [] 196 port_to_buf_map = {} 197 in_msg_bufs = {} 198 for port in self.in_ports: | 1# Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 2# Copyright (c) 2009 The Hewlett-Packard Development Company 3# Copyright (c) 2013 Advanced Micro Devices, Inc. 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 --- 182 unchanged lines hidden (view full) --- 191 self.table = table 192 193 # determine the port->msg buffer mappings 194 def getBufferMaps(self, ident): 195 msg_bufs = [] 196 port_to_buf_map = {} 197 in_msg_bufs = {} 198 for port in self.in_ports: |
199 buf_name = "m_%s_ptr" % port.buffer_expr.name | 199 buf_name = "m_%s_ptr" % port.pairs["buffer_expr"].name |
200 msg_bufs.append(buf_name) 201 port_to_buf_map[port] = msg_bufs.index(buf_name) 202 if buf_name not in in_msg_bufs: 203 in_msg_bufs[buf_name] = [port] 204 else: 205 in_msg_bufs[buf_name].append(port) 206 return port_to_buf_map, in_msg_bufs, msg_bufs 207 --- 1346 unchanged lines hidden --- | 200 msg_bufs.append(buf_name) 201 port_to_buf_map[port] = msg_bufs.index(buf_name) 202 if buf_name not in in_msg_bufs: 203 in_msg_bufs[buf_name] = [port] 204 else: 205 in_msg_bufs[buf_name].append(port) 206 return port_to_buf_map, in_msg_bufs, msg_bufs 207 --- 1346 unchanged lines hidden --- |