Operating System - OpenVMS
cancel
Showing results for 
Search instead for 
Did you mean: 

Interrupt delay in Pthreads

Elwin Tennant
Occasional Visitor

Interrupt delay in Pthreads

The attached C program writes 'ABCD' to the screen. However it shows a delay of about 1/5 second between characters !

The log file under VMS (Integrity) shows:
7.546: 'B' /C1 main: sending a character to tty
7.546: /55 clk: requesting interrupt
7.646: /55 clk: requesting interrupt
7.746: /A1 tty: received a command
7.746: 'B' /A2 tty: character written

Under Linux it shows:
13.469: 'C' /C1 main: sending a character to tty
13.469: /A1 tty: received a command
13.469: 'C' /A2 tty: character written

The delay may be in pthread_mutex_lock

Try it and see what you get !?
3 REPLIES
H.Becker
Honored Contributor

Re: Interrupt delay in Pthreads

Did you enable UPCALLS by linking with /threads=uppcalls or set image flag=upcalls?
Elwin Tennant
Occasional Visitor

Re: Interrupt delay in Pthreads

It certainly looks a lot better !! We will do some more tests. Many thanks.
Volker Halle
Honored Contributor

Re: Interrupt delay in Pthreads

Elwin,

welcome to the OpenVMS ITRC forum.

Here is a good explanation about DECthreads and 'upcalls':

http://h71000.www7.hp.com/wizard/wiz_0446.html

Volker.