发明名称 |
Multi-thread processors and methods for instruction execution and synchronization therein and computer program products thereof |
摘要 |
Methods for instruction execution and synchronization in a multi-thread processor are provided, wherein in the multi-thread processor, multiple threads are running and each of the threads can simultaneously execute a same instruction sequence. A source code or an object code is received and then compiled to generate the instruction sequence. Instructions for all of function calls within the instruction sequence are sorted according to a calling order. Each thread is provided a counter value pointing to one of the instructions in the instruction sequence. A main counter value is determined according to the counter values of the threads such that all of the threads simultaneously execute an instruction of the instruction sequence that the main counter value points to. |
申请公布号 |
US8838941(B2) |
申请公布日期 |
2014.09.16 |
申请号 |
US201113042996 |
申请日期 |
2011.03.08 |
申请人 |
Via Technologies, Inc. |
发明人 |
Zhang Yangang |
分类号 |
G06F7/38;G06F9/00;G06F9/44;G06F15/00;G06F9/38;G06F9/32 |
主分类号 |
G06F7/38 |
代理机构 |
McClure, Qualey & Rodack, LLP |
代理人 |
McClure, Qualey & Rodack, LLP |
主权项 |
1. A method for instruction execution and synchronization in a multi-thread processor, wherein multiple threads are running in the multi-thread processor and each of the threads can simultaneously execute a same instruction sequence, the method comprising:
receiving a source code or an object code; compiling the source code or the object code to generate the instruction sequence, wherein instructions for all of function calls within the instruction sequence are sorted according to a calling order; providing each thread a counter value, each counter value pointing to one of the instructions in the instruction sequence; and determining a main counter value according to the counter values of the threads such that all of the threads simultaneously execute the instruction of the instruction sequence that the main counter value points to. |
地址 |
New Taipei TW |