Processor scoreboard under a VLIW architecture, processor and electronic device

By dynamically managing the instruction execution state through a dual-layer scoreboard structure, the design challenges of the scoreboard in the VLIW architecture are solved, improving the processor's hardware efficiency and instruction execution throughput, and optimizing the detection and scheduling of multi-instruction dependencies in out-of-order execution.

CN120909656BActive Publication Date: 2026-01-02CIX TECH (SHANGHAI) CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511440302.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-10
Publication Date
2026-01-02
Estimated Expiration
2045-10-10

AI Technical Summary

Technical Problem

In the VLIW architecture, designing an efficient and accurate scoreboard to manage instruction scheduling and track data correlations is a challenge.

Method used

A two-layer scoring board structure is adopted, including a first scoring board and a second scoring board. The number of cycles of pipeline instructions in the execution unit is dynamically represented by the table entry number, and the write-back information is dynamically updated to manage hazard information and indefinite cycle instructions.

Benefits of technology

It simplifies hardware logic, improves instruction execution throughput and processor operating efficiency, reduces register resource conflicts, and optimizes multi-instruction dependency detection and scheduling in out-of-order execution scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120909656B_ABST
    Figure CN120909656B_ABST
Patent Text Reader

Abstract

The application provides a processor scoreboard under a VLIW architecture, a processor and an electronic device, after entering a current clock cycle, the first scoreboard is used for writing the hazard information sent by an n-th decoding slot received in a previous clock cycle into an n-th record entry in a target table item, and marking the n-th record entry as an effective state; after entering the current clock cycle, the first scoreboard is also used for moving the record entry in a k-th table item in the effective state to a corresponding record entry in a k-1-th table item, and marking the corresponding record entry as the effective state. The number of table items is used to dynamically represent the number of execution cycles of the pipelined instruction in the execution unit, the execution state of the instruction is efficiently tracked and the write-back information is dynamically updated, the hardware logic is significantly simplified, the execution management of the indefinite cycle instruction and the pipelined instruction is supported, and the hardware efficiency and the instruction execution throughput are improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of semiconductor, in particular to a processor scoreboard under VLIW architecture, a processor and an electronic device. BACKGROUND

[0002] In computer processor architecture, Very Long Instruction Word (VLIW) is a kind of Explicit Parallel Instruction Computing (EPIC) architecture. Unlike traditional processors, VLIW architecture transfers the discovery and scheduling of instruction-level parallelism from hardware to compiler, and implements instruction-level parallelism by packing multiple instructions that can be executed in parallel into a very long instruction word at compile time.

[0003] In VLIW architecture, a VLIW corresponds to multiple operation slots, and each operation slot can independently execute a basic operation. These operation slots usually include integer operation units, floating point operation units, load / store units, branch jump units, etc.

[0004] Scoreboard technology is a kind of dynamic scheduling algorithm, which is used to track data dependencies between instructions and perform instruction scheduling. How to design a scoreboard that can run efficiently and accurately under VLIW architecture has become a difficult problem for those skilled in the art. SUMMARY

[0005] The present application aims to provide a processor scoreboard under VLIW architecture, a processor and an electronic device to improve the above problems.

[0006] In order to achieve the above purpose, the technical solutions adopted by the embodiments of the present application are as follows:

[0007] In the first aspect, the embodiments of the present application provide a processor scoreboard under VLIW architecture, which comprises a first scoreboard, and the first scoreboard comprises K+1 table entries, and each table entry comprises N record entries.

[0008] After entering the current clock cycle, the first scoreboard is configured to write the hazard information sent by the nth decoding slot in the last clock cycle into the nth record entry in the target table entry, and mark it as valid.

[0009] The hazard information includes the execution period of microcode instructions, execution unit identifier, forwarding function identifier and destination register identifier. When the execution period of microcode instructions is X, the target table entry is the X+1 table entry, and X is less than or equal to K.

[0010] After entering the current clock cycle, the first scoreboard is further configured to move the record entry in the kth table entry in the active state to the corresponding record entry in the k-1th table entry, and mark it as active.

[0011] Optionally, the processor scoreboard further comprises a second scoreboard, and the second scoreboard comprises state mark bits of each destination register.

[0012] When it is determined that the microcode instruction corresponding to the ith record entry in the kth table entry in the active state is an indefinite period instruction, the second scoreboard is further configured to modify the state mark bit of the destination register corresponding to the ith record entry in the kth table entry to the occupied state; and the first scoreboard is further configured to erase the ith record entry in the kth table entry.

[0013] The second scoreboard is configured to modify the state mark bit of the destination register corresponding to the completed indefinite period instruction to the idle state when receiving the indefinite period instruction completion indication.

[0014] The first scoreboard is configured to write the adventure information corresponding to the completed indefinite period instruction into the ith record entry in the first table entry, where I represents the decoding slot number corresponding to the indefinite period instruction.

[0015] Optionally, after entering the current clock cycle, the first scoreboard is further configured to erase all record entries in the first table entry.

[0016] In a second aspect, an embodiment of the present application provides a processor under a VLIW architecture, which comprises N decoding slots, an execution unit, and the above processor scoreboard.

[0017] When the nth decoding slot obtains valid decoding information in the current clock, the nth decoding slot is configured to estimate whether the nth record entry in the target table entry is in the occupied state in the next clock cycle, and determine whether there is an adventure conflict.

[0018] If the nth record entry in the target table entry is in the idle state in the next clock cycle, and there is no adventure conflict, the nth decoding slot is configured to send the valid decoding information to the back end for calling by the execution unit, and send the adventure information in the valid decoding information to the first scoreboard.

[0019] Optionally, when the target table entry is the k+1th table entry, the nth decoding slot is configured to determine that the nth record entry in the target table entry is in the idle state in the next clock cycle.

[0020] When the target entry is the jth entry, the nth decoding slot is further configured to determine that the nth record entry in the jth entry is in an occupied state in a next clock cycle when the nth record entry in the j+1th entry in a current clock cycle is in the occupied state; and determine that the nth record entry in the jth entry is in an idle state in the next clock cycle when the nth record entry in the j+1th entry in the current clock cycle is in the idle state, 2≤j≤K.

[0021] Optionally, the nth decoding slot is further configured to determine whether source registers and destination registers in the valid decoding information are the same as occupied registers recorded in the processor scoreboard, and determine that there is an hazard conflict if there is any same.

[0022] Optionally, the nth decoding slot is further configured to determine whether an execution unit in the valid decoding information is the same as an occupied execution unit recorded in the processor scoreboard, and determine that there is an hazard conflict if the same.

[0023] Optionally, the execution unit is configured to send a first type of state modification instruction to a second scoreboard in the processor scoreboard and send an erase instruction to the first scoreboard when it is determined that the microcode instruction corresponding to the ith record entry in the kth entry in the valid state is an indefinite period instruction.

[0024] The second scoreboard is configured to modify a state flag corresponding to a destination register in the ith record entry in the kth entry to the occupied state when the first type of state modification instruction is received.

[0025] The first scoreboard is further configured to erase the ith record entry in the kth entry when the erase instruction is received.

[0026] Optionally, the execution unit is configured to send an indefinite period instruction completion indication to the second scoreboard in a current clock cycle when the ith record entry in the second entry is in the idle state in the current clock cycle after the indefinite period instruction is completed.

[0027] The second scoreboard is configured to modify a state flag corresponding to a destination register in the indefinite period instruction completion indication received in a previous clock cycle to the idle state.

[0028] The first scoreboard is configured to write hazard information corresponding to the indefinite period instruction completion indication received in the previous clock cycle into the ith record entry in the first entry, where I represents a decoding slot number corresponding to the indefinite period instruction.

[0029] In a third aspect, an electronic device is provided, which includes the processor described above.

[0030] With respect to the prior art, the processor scoreboard under the VLIW architecture and the processor and the electronic device provided by the embodiment of the present application, the processor scoreboard comprises a first scoreboard, the first scoreboard comprises K+1 table entries, each table entry comprises N record entries, after entering a current clock cycle, the first scoreboard is used for writing the hazard information sent by the nth decoding slot received in a previous clock cycle into the nth record entry in a target table entry, and marking the nth record entry as an effective state, 1≤n≤N; wherein, the hazard information comprises an execution cycle of a microcode instruction, an execution unit identifier, a forwarding function identifier and a destination register identifier, when the execution cycle of the microcode instruction is X, the target table entry is the (X+1)th table entry, and X is less than or equal to K; after entering the current clock cycle, the first scoreboard is further used for moving the record entry in the kth table entry in the effective state to the corresponding record entry in the (k-1)th table entry, and marking the record entry as the effective state. The number of table entries is used to dynamically represent the number of execution cycles of the pipelined instruction in the execution unit. The design can efficiently track the execution state of the instruction and dynamically update the write-back information. This is the core of the scoreboard design, which significantly simplifies the hardware logic, supports the execution management of the indefinite period instruction and the pipelined instruction, and improves the hardware efficiency and the instruction execution throughput. The hazard information is managed by the first scoreboard, which is convenient, fast and accurate, and is beneficial to the efficient operation of the processor.

[0031] In order to make the above-mentioned purpose, features and advantages of the present application more obvious and easy to understand, the following preferred embodiments are specifically described below, and the accompanying drawings are used for detailed description. BRIEF DESCRIPTION OF DRAWINGS

[0032] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments. It should be understood that the following drawings only show some embodiments of the present application, and therefore should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.

[0033] Figure 1 One of the architecture schematic diagrams of the processor scoreboard provided by the embodiment of the present application.

[0034] Figure 2 The second architecture schematic diagram of the processor scoreboard provided by the embodiment of the present application.

[0035] Figure 3 The third architecture schematic diagram of the processor scoreboard provided by the embodiment of the present application.

[0036] Figure 4 The fourth architecture schematic diagram of the processor scoreboard provided by the embodiment of the present application. DETAILED DESCRIPTION

[0037] In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some but not all of the embodiments of the present application. The components of the embodiments of the present application described and shown in the drawings can be arranged and designed in various different configurations.

[0038] Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the claimed application, but merely represents selected embodiments of the application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work are within the scope of protection of the present application.

[0039] It should be noted that: similar reference numerals and letters represent similar items in the following drawings, therefore, once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. Meanwhile, in the description of the present application, the terms "first", "second" and the like are only used to distinguish description, and cannot be understood as indicating or implying relative importance.

[0040] It should be noted that: similar reference numerals and letters represent similar items in the following drawings, therefore, once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. Meanwhile, in the description of the present application, the terms "first", "second" and the like are only used to distinguish description, and cannot be understood as indicating or implying relative importance.

[0041] In the description of the present application, it should be noted that the terms "upper", "lower", "inner", "outer" and the like indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, or the orientation or positional relationship commonly placed when the product of the present application is used, and are only for the convenience of describing the present application and simplifying the description, and therefore cannot be understood as indicating or implying that the indicated device or element must have a particular orientation, be constructed and operated in a particular orientation, and therefore cannot be understood as limiting the present application.

[0042] In the description of the present application, it is also necessary to explain that, unless otherwise explicitly specified and limited, the terms "set", "connected" should be understood broadly, for example, can be fixedly connected, or can be detachably connected, or integrally connected; can be mechanically connected, or can be electrically connected; can be directly connected, or can be indirectly connected through an intermediate medium, or can be the communication inside two elements. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific circumstances.

[0043] Some embodiments of the present application will be described in detail below with reference to the accompanying drawings. The following examples and features in the examples can be combined with each other without conflict.

[0044] Please refer to Figure 1 and Figure 2 , Figure 1 One of the architecture schematic diagrams of the processor scoreboard provided by the embodiments of the present application, Figure 2 The architecture schematic diagram two of the processor scoreboard provided by the embodiments of the present application. The processor scoreboard under the VLIW architecture includes a first scoreboard (also referred to as a main scoreboard), which includes K+1 table entries (K is the maximum execution period of pipelined instructions), and each table entry includes N groups of record entries, and N is the total number of decode slots in the processor.

[0045] In the drawings provided by the embodiments of the present application, K=2 and N equal to 4 are taken as examples for description, but this is not a limitation.

[0046] After entering the current clock cycle, the first scoreboard is used to write the hazard information sent by the nth decode slot received in the last clock cycle into the nth record entry in the target table entry, and mark it as valid, 1≤n≤N.

[0047] Wherein, the hazard information includes the execution period of the microcode instruction decoded by the nth decode slot in the last clock cycle, the execution unit identifier, the forwarding function identifier (whether it has forwarding capability) and the destination register identifier, when the execution period of the microcode instruction is X, the target table entry is the X+1 table entry, and X is less than or equal to K.

[0048] Please refer to Figure 1 The execution period in the hazard information sent by the third decode slot is 1, so the corresponding target table entry is the second table entry. The execution period in the hazard information sent by the first decode slot, the second decode slot and the third decode slot is 2, so the corresponding target table entry is the third table entry.

[0049] It should be noted that when the operation result corresponding to the microcode instruction has forwarding capability, the forwarding function identifier indicates that it can be forwarded, and when the operation result corresponding to the microcode instruction does not have forwarding capability, the forwarding function identifier indicates that it cannot be forwarded, for example, it is empty.

[0050] Optionally, the n-th decoding slot has determined that the n-th record entry in the target entry is in an idle state and there is no conflict in the microcode instruction in the next clock cycle (i.e. the current clock cycle) of the last clock cycle when sending the conflict information in the last clock cycle.

[0051] After entering the current clock cycle, the first scoreboard is further configured to move the record entry in the k-th entry in an active state to the corresponding record entry in the k-1-th entry and mark it as an active state.

[0052] Optionally, the record entry in the k-th entry in an active state is moved to the corresponding record entry in the k-1-th entry through a shift register. The n-th record entry in the k-th entry corresponds to the n-th record entry in the k-1-th entry, and 2≤k≤K+1. Optionally, the K entries can be moved synchronously, or starting from k=2 to k=K+1.

[0053] As shown in Figure 2 , Figure 2 The corresponding last clock cycle is Figure 1 As shown, in the current clock cycle, the record entry in the 3-rd entry in an active state can be moved to the corresponding record entry in the 2-nd entry, and the record entry in the 2-nd entry in an active state can be moved to the corresponding record entry in the 1-st entry. Meanwhile, the conflict information sent by the n-th decoding slot received in the last clock cycle can be written into the n-th record entry in the target entry. As shown in Figure 2 The execution cycle of the conflict information sent by the n-th decoding slot received in the last clock cycle corresponds to 2, so it is written into the 4 groups of record entries in the 3-rd entry.

[0054] In the processor scoreboard under the VLIW architecture provided in the embodiments of the present application, the number of periods of the flow instruction executed in the execution unit is dynamically represented by the entry number. The design can efficiently track the execution state of the instruction and dynamically update the write-back information. This is the core of the scoreboard design, which significantly simplifies the hardware logic, supports the execution management of indefinite period instructions and flow instructions, and improves the hardware efficiency and instruction execution throughput. The first scoreboard is used to manage the conflict information, which is convenient, fast and accurate, and is conducive to the efficient operation of the processor.

[0055] Please refer to Figure 3 , Figure 3 for the third architecture diagram of the processor scoreboard provided in the embodiments of the present application. As shown in Figure 3 The processor scoreboard further includes a second scoreboard (also referred to as an indefinite period instruction scoreboard), and the second scoreboard includes state marking bits of each destination register. Figure 3Take M destination registers as an example for description.

[0056] When it is determined that the microcode instruction corresponding to the i-th record entry in the k-th table entry in the active state is an indefinite period instruction, the second score board is further configured to modify the state mark bit corresponding to the destination register in the i-th record entry in the k-th table entry to the occupied state; and the first score board is further configured to delete (or modify to the invalid state) the i-th record entry in the k-th table entry, 1≤i≤N.

[0057] Please refer to Figure 4 , Figure 4 The fourth architecture schematic diagram of the processor score board provided by the embodiment of the present application. Figure 4 With Figure 2 The microcode instruction corresponding to the 2nd record entry in the 3rd table entry in the active state is an indefinite period instruction, for example. After the hazard information sent by the n-th decoding slot received in the last clock cycle is written into the n-th record entry in the target table entry, the first score board deletes (or modifies to the invalid state) the 2nd record entry in the 3rd table entry. The second score board is further configured to modify the state mark bit corresponding to the destination register in the 2nd record entry in the 3rd table entry to the occupied state.

[0058] In an optional implementation, the second score board is configured to modify the state mark bit of the destination register corresponding to the indefinite period instruction that has been completed to the idle state when receiving the indefinite period instruction completion indication.

[0059] The first score board is configured to write the hazard information corresponding to the indefinite period instruction that has been completed into the I-th record entry in the 1st table entry when receiving the indefinite period instruction completion indication, wherein I represents the decoding slot number corresponding to the indefinite period instruction.

[0060] In an optional implementation, after entering the current clock cycle, the first score board is further configured to delete (or modify to the invalid state) all the record entries in the 1st table entry. After deletion, the active record entries in the 2nd table entry can be moved to the 1st table entry, and the 1st table entry is deleted as the earliest action after the current clock cycle.

[0061] In the embodiment of the present application, the first score board (main score board) and the second score board (non-periodic instruction score board) work together to improve the instruction correlation detection capability. Specifically, the double-layer structure design of the main score board and the non-periodic instruction score board is adopted. When the instruction cannot be confirmed as a non-periodic instruction at the decoding time, it is first recorded in the main score board; after the execution stage is confirmed, it is transferred to the non-periodic instruction score board, and then returned to the main score board until the end of execution. This dynamic instruction life cycle management method realizes accurate detection of instruction correlation. The processing of non-periodic instructions is more flexible, effectively solving the execution delay problem caused by the inability to distinguish non-periodic instructions in the traditional scheme. It reduces the conflict risk of register resource occupation and optimizes the pipeline performance. It enhances the support capability of multi-instruction correlation detection and scheduling in the out-of-order execution scenario. It solves the problem of non-periodic instruction and pipeline instruction correlation detection, dynamically adjusts the instruction scheduling process, and reduces the performance loss caused by conflicts.

[0062] The embodiment of the present application also provides a processor under a VLIW architecture, which comprises N decoding slots, an execution unit and the processor score board.

[0063] When the nth decoding slot obtains valid decoding information at the current clock, the nth decoding slot is used to estimate whether the nth record entry in the target table entry is in an occupied state at the next clock period, and determine whether there is an adventure conflict (including read-after-write conflict, write-after-write conflict and execution unit conflict).

[0064] If the nth record entry in the target table entry is in an idle state at the next clock period, and there is no adventure conflict, the nth decoding slot is used to send the valid decoding information to the back end for calling by the execution unit, and send the adventure information in the valid decoding information to the first score board.

[0065] If the nth record entry in the target table entry is in an occupied state at the next clock period, or there is an adventure conflict, the nth decoding slot will not send the valid decoding information to the back end, nor send the adventure information in the valid decoding information to the first score board, and it needs to be cached until the corresponding condition is met.

[0066] Optionally, the nth decoding slot is used to determine that the nth record entry in the target table entry is in an idle state at the next clock period when the target table entry is the K+1 table entry.

[0067] When the target entry is the jth entry, the nth decoding slot is further configured to determine that the nth record entry in the jth entry is in an occupied state in the next clock cycle when the nth record entry in the jth+1 entry in the current clock cycle is in the occupied state, and determine that the nth record entry in the jth entry is in an idle state in the next clock cycle when the nth record entry in the jth+1 entry in the current clock cycle is in the idle state, 2≤j≤K.

[0068] Optionally, the nth decoding slot is further configured to determine whether the source register and the destination register in the valid decoding information are the same as the occupied registers recorded in the processor scoreboard, and determine that there is an hazard conflict (read-after-write conflict or write-after-write conflict) if there is any same.

[0069] Optionally, the nth decoding slot is further configured to determine whether the execution unit in the valid decoding information is the same as the occupied execution unit recorded in the processor scoreboard, and determine that there is an hazard conflict (execution unit conflict) if the same.

[0070] In the embodiment of the present application, the number of register file read ports can be 8, but this structure can also be applied to larger register file read ports such as 10, 12, etc. The number of register file write ports is 4, but this structure can also be applied to larger register file read ports such as 6, 8, etc.

[0071] The processor provided by the embodiment of the present application can optimize the register conflict detection mechanism, and jointly judge the read-after-write conflict and the write-after-write conflict through the register numbers in the main scoreboard and the indefinite period instruction scoreboard. The mechanism of judging the register resource conflict based on the valid signal is adopted, and the new instruction can quickly judge whether there is a register conflict by querying the valid signal of the corresponding entry in the main scoreboard and the related information in the indefinite period instruction scoreboard. The number of pipeline stalls is reduced, and the instruction execution efficiency is improved. The performance loss caused by the register conflict is significantly reduced. The accuracy and real-time performance of instruction scheduling in out-of-order execution are improved.

[0072] In an optional implementation, the execution unit is configured to, when determining that the microcode instruction corresponding to the ith record entry in the kth entry in an effective state is an indefinite period instruction, send a first type of state modification instruction (specifically, to the state mark bit corresponding to the destination register in the ith record entry in the kth entry) to a second scoreboard in the processor scoreboard, and send an erase instruction (including the identification of the ith record entry in the kth entry) to a first scoreboard.

[0073] The second scoreboard is configured to, when receiving the first type of state modification instruction, modify the state mark bit corresponding to the destination register in the ith record entry in the kth entry to the occupied state.

[0074] The first scoreboard is also configured to delete (or modify to an invalid state) the i-th record entry in the k-th table entry when a delete instruction is received.

[0075] Optionally, the execution unit is configured to, when the i-th record entry in the second table entry is in an idle state at a current clock cycle, send a non-deterministic period instruction completion indication (indicating that the operation result of the instruction has been obtained, but has not been written back to the corresponding destination register) to the second scoreboard at the current clock cycle when the non-deterministic period instruction operation is completed.

[0076] The second scoreboard is configured to modify the state flag bit of the destination register corresponding to the non-deterministic period instruction completion indication (completed non-deterministic period instruction) received in the last clock cycle to an idle state.

[0077] The first scoreboard is configured to write the hazard information corresponding to the non-deterministic period instruction completion indication (completed non-deterministic period instruction) received in the last clock cycle into the i-th record entry in the first table entry, where i represents the decode slot number corresponding to the non-deterministic period instruction.

[0078] Optionally, the processor under the VLIW architecture is provided with four decode slots, and the front-end module splits the VLIW into four microcode instructions and sends them to the corresponding decode slots.

[0079] The embodiment of the present application also provides an electronic device comprising the processor.

[0080] In summary, the processor scoreboard, the processor and the electronic device provided by the embodiment of the present application are described as follows: the processor scoreboard comprises a first scoreboard, the first scoreboard comprises K+1 table entries, each table entry comprises N record entries; after entering a current clock cycle, the first scoreboard is configured to write the hazard information sent by the n-th decode slot in the last clock cycle into the n-th record entry in the target table entry and mark it as an effective state, 1≤n≤N; wherein the hazard information comprises an execution period of a microcode instruction, an execution unit identifier, a forwarding function identifier and a destination register identifier, the target table entry is the X+1 table entry when the execution period of the microcode instruction is X, and X is less than or equal to K; after entering the current clock cycle, the first scoreboard is also configured to move the record entry in the k-th table entry in the effective state to the corresponding record entry in the k-1 table entry and mark it as an effective state. The number of the table entry is used to dynamically represent the number of periods in which the pipeline instruction is executed in the execution unit. The design can efficiently track the execution state of the instruction and dynamically update the write-back information. This is the core of the scoreboard design, which significantly simplifies the hardware logic, supports the execution management of non-deterministic period instructions and pipeline instructions, and improves the hardware efficiency and the instruction execution throughput. The hazard information is managed by the first scoreboard, which is convenient, fast and accurate, and is conducive to the efficient operation of the processor.

[0081] The above description is only preferred embodiments of the present application and is not used to limit the present application. The present application can have various modifications and changes for those skilled in the art. Any modification, equivalent replacement, improvement, etc. within the spirit and principle of the present application shall be included in the protection scope of the present application.

[0082] It is obvious for those skilled in the art that the present application is not limited to the details of the above exemplary embodiments, and the present application can be implemented in other specific forms without departing from the spirit or essential characteristics of the present application. Therefore, the embodiments should be regarded as exemplary and non-limiting, the scope of the present application is defined by the appended claims rather than the above description, and all changes falling within the meaning and scope of the equivalent elements of the claims are intended to be included in the present application. Any reference signs in the claims should not be regarded as limiting the involved claims.

Claims

1. A processor scoreboard under a VLIW architecture, characterized in that, The processor scoreboard includes a first scoreboard, which includes K+1 entries. Each entry includes N sets of record entries, where K is the maximum execution cycle of the pipelined instruction and N is the total number of decoding slots in the processor. Upon entering the current clock cycle, the first scoreboard is used to write the hazard information received from the nth decoder slot in the previous clock cycle into the nth record entry in the target table and mark it as valid. The hazard information includes the execution cycle of the microcode instruction, the execution unit identifier, the forwarding function identifier, and the destination register identifier. When the execution cycle of the microcode instruction is X, the target entry is the (X+1)th entry, where X is less than or equal to K. After entering the current clock cycle, the first scoreboard is also used to move the record entry in the k-th entry that is in a valid state to the corresponding record entry in the (k-1)-th entry and mark it as valid, 2≤k≤K+1.

2. The processor scoreboard under the VLIW architecture as described in claim 1, characterized in that, The processor scoreboard also includes a second scoreboard, which includes status flag bits for each destination register; When it is determined that the microcode instruction corresponding to the i-th record entry in the k-th entry is an indefinite periodic instruction, the second scoring board is also used to modify the status flag bit corresponding to the destination register in the i-th record entry in the k-th entry to the occupied state; the first scoring board is also used to erase the i-th record entry in the k-th entry. The second scoring board is used to modify the status flag bit of the destination register corresponding to the completed indefinite period instruction to the idle state when it receives the indefinite period instruction completion indication; The first scoreboard is used to write the hazard information corresponding to the completed indefinite periodic instruction into the I record entry in the first table entry, where I represents the decoding slot number corresponding to the indefinite periodic instruction.

3. The processor scoreboard under the VLIW architecture as described in claim 1, characterized in that, Upon entering the current clock cycle, the first scoreboard is also used to erase all entries recorded in the first table entry.

4. A processor based on a VLIW architecture, characterized in that, The processor includes N decoding slots, an execution unit, and a processor scoreboard as described in any one of claims 1-3; When the nth decoding slot obtains valid decoding information in the current clock, the nth decoding slot is used to estimate whether the nth record entry in the target table will be occupied in the next clock cycle, and to determine whether there is a risk conflict. If the nth record entry in the estimated target table is idle in the next clock cycle and there is no hazard conflict, the nth decoding slot is used to send the valid decoding information to the backend for the execution unit to call, and to send the hazard information in the valid decoding information to the first scoreboard.

5. The processor under the VLIW architecture as described in claim 4, characterized in that, The nth decoding slot is used to determine that the nth record entry in the target table is in an idle state in the next clock cycle when the target table entry is the (K+1)th table entry. When the target entry is the j-th entry, the n-th decoding slot is also used to determine that the n-th record entry in the j+1-th entry of the current clock cycle is occupied, and that the n-th record entry in the j-th entry is occupied in the next clock cycle; and when the n-th record entry in the j+1-th entry of the current clock cycle is idle, to determine that the n-th record entry in the j-th entry is idle in the next clock cycle, where 2≤j≤K.

6. The processor under the VLIW architecture as described in claim 4, characterized in that, The nth decoding slot is also used to determine whether the source register and destination register in the valid decoding information are the same as the occupied registers recorded in the processor scoreboard. If either is the same, a hazard conflict is determined to exist.

7. The processor under the VLIW architecture as described in claim 4, characterized in that, The nth decoding slot is also used to determine whether the execution unit in the valid decoding information is the same as the occupied execution unit recorded in the processor scoreboard. If they are the same, it is determined that there is a risk conflict.

8. The processor under the VLIW architecture as described in claim 4, characterized in that, The execution unit is used to send a first type of state modification instruction to the second scoreboard in the processor scoreboard and send an erase instruction to the first scoreboard when it is determined that the microcode instruction corresponding to the i-th record entry that is in a valid state in the k-th entry is an indefinite periodic instruction. The second scoring board is used to modify the status flag bit corresponding to the destination register in the i-th record entry of the k-th table entry to the occupied state when the first type of status modification instruction is received; The first scoreboard is also used to erase the i-th record entry in the k-th entry when the erase instruction is received.

9. The processor under the VLIW architecture as described in claim 8, characterized in that, The execution unit is used to send an indeterminate instruction completion indication to the second scoreboard in the current clock cycle if the first record entry in the second table is idle in the current clock cycle when the indeterminate instruction operation is completed. The second scoreboard is used to modify the status flag bit of the destination register corresponding to the completion indication of the indeterminate period instruction received in the previous clock cycle to the idle state; The first scoring board is used to write the hazard information corresponding to the indeterminate period instruction completion indication received in the previous clock cycle into the I record entry in the first table entry, where I represents the decoding slot number corresponding to the indeterminate period instruction.

10. An electronic device, characterized in that, The processor included in any one of claims 4-9.

Citation Information

Patent Citations

  • Software-based instruction scoreboard for arithmetic logic units

    CN116830145A

  • Instruction processing method, device, circuit, transmitter, chip, medium and product

    CN116991480A