Apparatus and method for efficient communication of producer/consumer buffer status
Abstract
An apparatus and method for efficient communication of producer/consumer buffer status are provided. With the apparatus and method, devices in a data processing system notify each other of updates to head and tail pointers of a shared buffer region when the devices perform operations on the shared buffer region using signal notification channels of the devices. Thus, when a producer device that produces data to the shared buffer region writes data to the shared buffer region, an update to the head pointer is written to a signal notification channel of a consumer device. When a consumer device reads data from the shared buffer region, the consumer device writes a tail pointer update to a signal notification channel of the producer device. In addition, channels may operate in a blocking mode so that the corresponding device is kept in a low power state until an update is received over the channel.
Claims
exact text as granted — not AI-modified1 . A method, in a data processing system, comprising:
performing, using a first device in the data processing system, an operation on a shared buffer region; writing a pointer update to a signal notification channel associated with a second device in the data processing system, wherein the pointer update is an update to one of a head pointer or a tail pointer of the shared buffer region; and updating a pointer stored in a local store of the second device based on the pointer update.
2 . The method of claim 1 , wherein the operation on the shared buffer region is a write operation for writing data to the shared buffer region, and wherein the pointer update is an update to a head pointer of the shared buffer region.
3 . The method of claim 1 , wherein the operation on the shared buffer region is a read operation for reading data from the shared buffer region, and wherein the pointer update is an update to a tail pointer of the shared buffer region.
4 . The method of claim 1 , wherein the signal notification channel is a memory mapped address region of a shared memory of the data processing system.
5 . The method of claim 1 , further comprising:
determining if the shared buffer region is full; and placing the second device in a low-power consumption waiting state waiting for a predetermined amount of storage space to be freed in the shared buffer region before additional data may be written to the shared buffer region.
6 . The method of claim 5 , wherein placing the second device in a low-power consumption waiting state comprises placing the notification channel in a blocking mode of operation in which the second device's normal operation is blocked and the second device waits in a low-power consumption state.
7 . The method of claim 6 , wherein the operation is a read operation for reading data from the shared buffer region, and wherein the notification channel exits the blocking mode of operation in response to the read operation.
8 . The method of claim 6 , wherein while in the blocking mode of operation, a channel interface of the second device periodically issues a read channel count instruction to the signal notification channel to determine a count associated with the notification channel.
9 . The method of claim 8 , wherein if the count associated with the notification channel is zero, then the notification channel remains in a blocking mode of operation.
10 . The method of claim 8 , wherein if the count associated with the notification channel is non-zero, then the notification channel exits the blocking mode of operation.
11 . The method of claim 10 , wherein, in response to the notification channel exiting the blocking mode of operation, the second device is awoken by issuing a read channel instruction to the notification channel and returning results of the read channel instruction to the second device.
12 . The method of claim 1 , wherein the second device is a synergistic processing unit and the shared buffer region is part of the local store associated with the synergistic processing unit.
13 . The method of claim 12 , wherein writing a pointer update is performed using a channel interface of a memory flow control unit associated with the synergistic processing unit.
14 . The method of claim 1 , wherein the first device and the second device are synergistic processing units of a multiprocessor system-on-a-chip.
15 . A computer program product comprising a computer usable medium having a computer readable program, wherein the computer readable program, when executed on a computing device, causes the computing device to:
perform, using a first device in the data processing system, an operation on a shared buffer region; write a pointer update to a signal notification channel associated with a second device in the data processing system, wherein the pointer update is an update to one of a head pointer or a tail pointer of the shared buffer region; and update a pointer stored in a local store of the second device based on the pointer update.
16 . The computer program product of claim 15 , wherein the operation on the shared buffer region is a write operation for writing data to the shared buffer region, and wherein the pointer update is an update to a head pointer of the shared buffer region.
17 . The computer program product of claim 15 , wherein the operation on the shared buffer region is a read operation for reading data from the shared buffer region, and wherein the pointer update is an update to a tail pointer of the shared buffer region.
18 . The computer program product of claim 15 , wherein the signal notification channel is a memory mapped address region of a shared memory of the data processing system.
19 . The computer program product of claim 15 , wherein the computer readable program further causes the computing device to:
determine if the shared buffer region is full; and place the second device in a low-power consumption waiting state waiting for a predetermined amount of storage space to be freed in the shared buffer region before additional data may be written to the shared buffer region.
20 . The computer program product of claim 19 , wherein the computer readable program causes the computing device to place the second device in a low-power consumption waiting state by placing the notification channel in a blocking mode of operation in which the second device's normal operation is blocked and the second device waits in a low-power consumption state.
21 . The computer program product of claim 20 , wherein the operation is a read operation for reading data from the shared buffer region, and wherein the notification channel exits the blocking mode of operation in response to the read operation.
22 . The computer program product of claim 20 , wherein while in the blocking mode of operation, a channel interface of the second device periodically issues a read channel count instruction to the signal notification channel to determine a count associated with the notification channel.
23 . The computer program product of claim 22 , wherein if the count associated with the notification channel is zero, then the notification channel remains in a blocking mode of operation.
24 . The computer program product of claim 22 , wherein if the count associated with the notification channel is non-zero, then the notification channel exits the blocking mode of operation.
25 . The computer program product of claim 24 , wherein, in response to the notification channel exiting the blocking mode of operation, the second device is awoken by issuing a read channel instruction to the notification channel and returning results of the read channel instruction to the second device.
26 . The computer program product of claim 15 , wherein the second device is a synergistic processing unit and the shared buffer region is part of the local store associated with the synergistic processing unit.
27 . The computer program product of claim 26 , wherein the computer readable program causes the computing device to write a pointer update by using a channel interface of a memory flow control unit associated with the synergistic processing unit.
28 . The computer program product of claim 15 , wherein the first device and the second device are synergistic processing units of a multiprocessor system-on-a-chip.
29 . A system, comprising:
a first processor; a second processor coupled to the first processor; and a local storage device coupled to the second processor, wherein the first processor performs an operation on a shared buffer region of the local storage device and writes a pointer update to a signal notification channel associated with the second processor, wherein the pointer update is an update to one of a head pointer or a tail pointer of the shared buffer region, and wherein the second processor updates a pointer stored in the local store of the second processor based on the pointer update.
30 . The system of claim 29 , wherein the operation on the shared buffer region is a write operation for writing data to the shared buffer region, and wherein the pointer update is an update to a head pointer of the shared buffer region.
31 . The system of claim 29 , wherein the operation on the shared buffer region is a read operation for reading data from the shared buffer region, and wherein the pointer update is an update to a tail pointer of the shared buffer region.
32 . The system of claim 29 , wherein the second processor determines if the shared buffer region is full and places itself in a low-power consumption waiting state waiting for a predetermined amount of storage space to be freed in the shared buffer region before additional data may be written to the shared buffer region.
33 . The system of claim 32 , wherein the second processor places itself in a low-power consumption waiting state by placing the notification channel in a blocking mode of operation in which the second processor's normal operation is blocked and the second processor waits in a low-power consumption state.
34 . The system of claim 33 , wherein the operation is a read operation for reading data from the shared buffer region, and wherein the notification channel exits the blocking mode of operation in response to the read operation.
35 . The system of claim 33 , wherein while in the blocking mode of operation, a channel interface of the second processor periodically issues a read channel count instruction to the signal notification channel to determine a count associated with the notification channel, and wherein if the count associated with the notification channel is non-zero, then the notification channel exits the blocking mode of operation.Cited by (0)
No later patents cite this yet.
References (0)
No backward citations on record.