System and method for block-based concurrentization of software code
First Claim
1. A computer-implemented method, comprising:
- automatically marking a plurality blocks of code in an application coded for sequential execution to provide a marked code, wherein said marking comprises inserting a marker at each of the blocks to suggest that block for potential concurrent execution with other parts of the code, wherein each of the markers comprises a block duration weight for estimating an execution time of the corresponding block, wherein the block duration weight indicates a predetermined approximate execution duration for the corresponding block;
generating concurrent code from the marked code, wherein said generating comprises;
analyzing the marked code, according to at least the corresponding block duration weight of one or more of the marked blocks, to estimate performance benefits of concurrently executing the marked blocks of code and determining which marked blocks would meet a performance benefit threshold if executed concurrently; and
transforming two or more of the marked blocks into corresponding concurrently executable tasks, wherein one of the marked blocks is not transformed into one of the concurrently executable tasks if said analyzing indicates that the performance benefit threshold would not be met for that block; and
scheduling two or more of the concurrently executable tasks for concurrent multi-threaded execution, wherein a thread for one of the two or more concurrently executable tasks executes concurrently with a thread for another of the two or more concurrently executable tasks corresponding to a different one of the blocks.
2 Assignments
0 Petitions
Accused Products
Abstract
A method for inducing multi-threading in software code may use blocks of code as the basis for scheduling and to suggest concurrent execution for each block. The method may comprise marking one or more blocks of code in an application coded for sequential execution to generate marked code. The marking may comprise inserting a marker at each of the one or more blocks to suggest that block for potential concurrent execution. Concurrent code may be generated from the marked code. Generating the concurrent code may comprise analyzing the marked code to estimate performance benefits of concurrently executing the marked blocks of code and determine which marked blocks would meet a performance benefit threshold if executed concurrently. Generating the concurrent code may also comprise transforming one or more of the marked blocks into corresponding concurrently executable tasks. The method may include scheduling one or more of the concurrently executable tasks.
-
Citations
37 Claims
-
1. A computer-implemented method, comprising:
-
automatically marking a plurality blocks of code in an application coded for sequential execution to provide a marked code, wherein said marking comprises inserting a marker at each of the blocks to suggest that block for potential concurrent execution with other parts of the code, wherein each of the markers comprises a block duration weight for estimating an execution time of the corresponding block, wherein the block duration weight indicates a predetermined approximate execution duration for the corresponding block; generating concurrent code from the marked code, wherein said generating comprises; analyzing the marked code, according to at least the corresponding block duration weight of one or more of the marked blocks, to estimate performance benefits of concurrently executing the marked blocks of code and determining which marked blocks would meet a performance benefit threshold if executed concurrently; and transforming two or more of the marked blocks into corresponding concurrently executable tasks, wherein one of the marked blocks is not transformed into one of the concurrently executable tasks if said analyzing indicates that the performance benefit threshold would not be met for that block; and scheduling two or more of the concurrently executable tasks for concurrent multi-threaded execution, wherein a thread for one of the two or more concurrently executable tasks executes concurrently with a thread for another of the two or more concurrently executable tasks corresponding to a different one of the blocks. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)
-
-
14. A system, comprising:
-
one or more processors; a memory coupled to the one or more processors, wherein the memory is configured to store program instructions executable by the one or more processors to implement a framework for suggestive multi-threading, wherein the framework comprises; an automated code marker tool configured to receive the sequential code;
analyze the sequential code to identify potential concurrently executable blocks of the sequential code; and
insert a plurality of markers into the sequential code to suggest the identified blocks for concurrent execution;a concurrent code generator configured to receive marked code comprising sequential code having a plurality of markers inserted in the sequential code to suggest blocks of code for concurrent execution with other parts of the code, wherein each of the markers comprises a block duration weight for estimating an execution time for the corresponding block, wherein the block duration weight indicates a predetermined approximate execution duration for the corresponding block, wherein the concurrent code generator is configured to; perform an analysis of the marked code, according to at least the corresponding block duration weight of one or more of the marked blocks, to estimate performance benefits of concurrently executing the marked blocks of code and determine which marked blocks would meet a performance benefit threshold if executed concurrently; and transform two or more of the marked blocks into corresponding concurrently executable tasks, wherein one of the marked blocks is not transformed into one of the concurrently executable tasks if the analysis indicates that the performance benefit threshold would not be met for that block; and a scheduler configured to schedule two or more of the tasks for concurrent multi-threaded execution, wherein a thread for one of the two or more concurrently executable tasks executes concurrently with a thread for another of the two or more concurrently executable tasks corresponding to a different one of the blocks. - View Dependent Claims (15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25)
-
-
26. A computer accessible storage medium comprising program instructions, wherein the program instructions are executable to implement a framework for suggestive multi-threading, wherein the framework comprises:
-
an automated code marker tool configured to receive the sequential code;
analyze the sequential code to identify potential concurrently executable blocks of the sequential code; and
insert two or more markers into the sequential code to suggest the identified blocks for concurrent execution;a concurrent code generator configured to receive marked code comprising sequential code having a plurality of markers inserted in the sequential code to suggest blocks of code for concurrent execution with other parts of the code, wherein each of the markers comprises a block duration weight for estimating an execution time for the corresponding block, wherein the block duration weight indicates a predetermined approximate execution duration for the corresponding block, wherein the concurrent code generator is configured to; perform an analysis of the marked code, according to at least the corresponding block duration weight of one or more of the marked blocks, to estimate performance benefits of concurrently executing the marked blocks of code and determine which marked blocks would meet a performance benefit threshold if executed concurrently; and transform two or more of the marked blocks into corresponding concurrently executable tasks, wherein one of the marked blocks is not transformed into one of the concurrently executable tasks if the analysis indicates that the performance benefit threshold would not be met for that block; and a scheduler configured to schedule two or more of the tasks for concurrent multi-threaded execution, wherein a thread for one of the two or more concurrently executable tasks executes concurrently with a thread for another of the two or more concurrently executable tasks corresponding to a different one of the blocks. - View Dependent Claims (27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37)
-
Specification