Patent ID: 8677334

Claim:
A computer-implemented method of parallelizing a code configured by coupling a functional block having an internal state and a functional block without any internal state, said method comprising: creating and storing, in a memory of a computer, a graphical representation on which said functional blocks are chosen as nodes and connections between said functional blocks are chosen as links; visiting said nodes on said graphical representation sequentially; detecting inputs from said functional blocks without any internal state to functional blocks having an internal state and storing said functional blocks having said internal state in said memory as a set of use blocks, and detecting inputs from said functional blocks having an internal state to said functional blocks without any internal state and storing said functional blocks having said internal state in said memory as a set of definition blocks; and forming strands of functional blocks based on information on said set of use blocks and information on said set of definition blocks stored in association with said functional blocks, wherein said strands are formed according to the following conditions: (i) if the number of use blocks is 0 and the number of definition blocks is 0, assigning a corresponding functional block to a strand identical to that of adjacent blocks with the number of use blocks equal to 0 and the number of definition blocks equal to 0; (ii) if the number of use blocks is 0 and the number of definition blocks is 1, assigning said corresponding functional block to a strand identical to that of adjacent blocks with the number of use blocks equal to 0; (iii) if the number of use blocks is 0 and the number of definition blocks is greater than 1, assigning said corresponding functional block to a strand identical to that of adjacent blocks with the number of use blocks equal to 0; (iv) if the number of use blocks is 1 and the number of definition blocks is 0, assigning said corresponding functional block to a strand identical to that of adjacent blocks with the number of definition blocks equal to 0; and (v) if the number of use blocks is 1 and the number of definition blocks is 1, assigning said corresponding functional block to a strand identical to that of said definition block.