parser.py (8086:bf0335d98250) parser.py (8154:f3d1493787d4)
1# Copyright (c) 2009 The Hewlett-Packard Development Company
2# All rights reserved.
3#
4# Redistribution and use in source and binary forms, with or without
5# modification, are permitted provided that the following conditions are
6# met: redistributions of source code must retain the above copyright
7# notice, this list of conditions and the following disclaimer;
8# redistributions in binary form must reproduce the above copyright

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

155 'transition' : 'TRANS',
156 'structure' : 'STRUCT',
157 'external_type' : 'EXTERN_TYPE',
158 'enumeration' : 'ENUM',
159 'state_declaration' : 'STATE_DECL',
160 'peek' : 'PEEK',
161 'stall_and_wait' : 'STALL_AND_WAIT',
162 'wake_up_dependents' : 'WAKE_UP_DEPENDENTS',
1# Copyright (c) 2009 The Hewlett-Packard Development Company
2# All rights reserved.
3#
4# Redistribution and use in source and binary forms, with or without
5# modification, are permitted provided that the following conditions are
6# met: redistributions of source code must retain the above copyright
7# notice, this list of conditions and the following disclaimer;
8# redistributions in binary form must reproduce the above copyright

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

155 'transition' : 'TRANS',
156 'structure' : 'STRUCT',
157 'external_type' : 'EXTERN_TYPE',
158 'enumeration' : 'ENUM',
159 'state_declaration' : 'STATE_DECL',
160 'peek' : 'PEEK',
161 'stall_and_wait' : 'STALL_AND_WAIT',
162 'wake_up_dependents' : 'WAKE_UP_DEPENDENTS',
163 'wake_up_all_dependents' : 'WAKE_UP_ALL_DEPENDENTS',
164 'enqueue' : 'ENQUEUE',
165 'copy_head' : 'COPY_HEAD',
166 'check_allocate' : 'CHECK_ALLOCATE',
167 'check_stop_slots' : 'CHECK_STOP_SLOTS',
168 'static_cast' : 'STATIC_CAST',
169 'if' : 'IF',
170 'is_valid' : 'IS_VALID',
171 'is_invalid' : 'IS_INVALID',

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

577 def p_statement__stall_and_wait(self, p):
578 "statement : STALL_AND_WAIT '(' var ',' var ')' SEMI"
579 p[0] = ast.StallAndWaitStatementAST(self, p[3], p[5])
580
581 def p_statement__wake_up_dependents(self, p):
582 "statement : WAKE_UP_DEPENDENTS '(' var ')' SEMI"
583 p[0] = ast.WakeUpDependentsStatementAST(self, p[3])
584
163 'enqueue' : 'ENQUEUE',
164 'copy_head' : 'COPY_HEAD',
165 'check_allocate' : 'CHECK_ALLOCATE',
166 'check_stop_slots' : 'CHECK_STOP_SLOTS',
167 'static_cast' : 'STATIC_CAST',
168 'if' : 'IF',
169 'is_valid' : 'IS_VALID',
170 'is_invalid' : 'IS_INVALID',

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

576 def p_statement__stall_and_wait(self, p):
577 "statement : STALL_AND_WAIT '(' var ',' var ')' SEMI"
578 p[0] = ast.StallAndWaitStatementAST(self, p[3], p[5])
579
580 def p_statement__wake_up_dependents(self, p):
581 "statement : WAKE_UP_DEPENDENTS '(' var ')' SEMI"
582 p[0] = ast.WakeUpDependentsStatementAST(self, p[3])
583
585 def p_statement__wake_up_all_dependents(self, p):
586 "statement : WAKE_UP_ALL_DEPENDENTS '(' ')' SEMI"
587 p[0] = ast.WakeUpAllDependentsStatementAST(self)
588
589 def p_statement__peek(self, p):
590 "statement : PEEK '(' var ',' type pairs ')' statements"
591 p[0] = ast.PeekStatementAST(self, p[3], p[5], p[6], p[8], "peek")
592
593 def p_statement__copy_head(self, p):
594 "statement : COPY_HEAD '(' var ',' var pairs ')' SEMI"
595 p[0] = ast.CopyHeadStatementAST(self, p[3], p[5], p[6])
596

--- 168 unchanged lines hidden ---
584 def p_statement__peek(self, p):
585 "statement : PEEK '(' var ',' type pairs ')' statements"
586 p[0] = ast.PeekStatementAST(self, p[3], p[5], p[6], p[8], "peek")
587
588 def p_statement__copy_head(self, p):
589 "statement : COPY_HEAD '(' var ',' var pairs ')' SEMI"
590 p[0] = ast.CopyHeadStatementAST(self, p[3], p[5], p[6])
591

--- 168 unchanged lines hidden ---