StallAndWaitStatementAST.py (10308:8c0870dbae5c) | StallAndWaitStatementAST.py (11025:4872dbdea907) |
---|---|
1# Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 2# Copyright (c) 2009 The Hewlett-Packard Development Company 3# Copyright (c) 2010 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 --- 25 unchanged lines hidden (view full) --- 34 self.in_port = in_port 35 self.address = address 36 37 def __repr__(self): 38 return "[StallAndWaitStatementAst: %r]" % self.in_port 39 40 def generate(self, code, return_type): 41 self.in_port.assertType("InPort") | 1# Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 2# Copyright (c) 2009 The Hewlett-Packard Development Company 3# Copyright (c) 2010 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 --- 25 unchanged lines hidden (view full) --- 34 self.in_port = in_port 35 self.address = address 36 37 def __repr__(self): 38 return "[StallAndWaitStatementAst: %r]" % self.in_port 39 40 def generate(self, code, return_type): 41 self.in_port.assertType("InPort") |
42 self.address.assertType("Address") | 42 self.address.assertType("Addr") |
43 44 in_port_code = self.in_port.var.code 45 address_code = self.address.var.code 46 code(''' 47 stallBuffer(&($in_port_code), $address_code); 48 $in_port_code.stallMessage($address_code); 49 ''') | 43 44 in_port_code = self.in_port.var.code 45 address_code = self.address.var.code 46 code(''' 47 stallBuffer(&($in_port_code), $address_code); 48 $in_port_code.stallMessage($address_code); 49 ''') |