ST20-C1 STMICROELECTRONICS [STMicroelectronics], ST20-C1 Datasheet - Page 142

no-image

ST20-C1

Manufacturer Part Number
ST20-C1
Description
Instruction Set Reference Manual
Manufacturer
STMICROELECTRONICS [STMicroelectronics]
Datasheet
signal
Code: 23 F5
Description: Perform the first par t of a semaphore signal (or V) on the semaphore
pointed to by Areg. If no process is waiting then the unsigned count is incremented. If
processes are waiting then the first process is removed from the queue and its
identifier placed in Breg ready to be run. The instruction returns a boolean value in
Areg stating whether a run process is required.
This instruction should be used in the following sequence: ld semptr; signal; cj
continue; run; continue :
Definition:
Status Register:
Comments:
See also: run wait
142/205
if (frontptr
{
}
else
{
}
Creg
where frontptr = word[Areg @ s.Front]
No effect
Secondary instruction.
The increment of the count is unchecked.
This instruction may require 4 accesses to memory. The semaphore structure
should be placed in on-chip memory if interrupt latency is critical.
Chapter 7 .
word [Areg @ s.Count]
Areg
Breg
if (frontptr = backptr)
else
Areg
Breg
word [Areg @ s.Front]
word [Areg @ s.Front]
backptr = word[Areg @ s.Back]
undefined
NotProcess)
false
undefined
true
frontptr
word[Areg @ s.Count] + 1
NotProcess
word[ frontptr @ pw.Link ]
-- queue empty
-- queue not empty
--
--
one process on queue
many processes on queue
signal

Related parts for ST20-C1