[comp.sys.ibm.pc] Interrupt handlers in MSC-V5

philip@amdcad.AMD.COM (Philip Freidin) (01/03/88)

I have seen some vague mention of the ability to write interrupt handlers
in msc v5.0. I have exhaustively searched (RTFFFFFFM) the docs, and none
of the table of contents, or indexes seem to have anything relevant to my
search. 
Well hidden in the library manual, are the routines:
	_enable
	_disable
	_dos_getvect
	_dos_setvect
	_dos_keep
	_chain_intr

discreatly embedded in these descriptions, are lines like

interrupt far *target;		(page 155, 206, 224)

which looks like a reserved word (interrupt) used to trigger the compiler
to use a RETI rather than a RET or RETF instruction. 

WHY CANT I FIND ANY DOCUMENTATION ON THIS RESERVED WORD??????????

If anyone has found (and dare I hope.... USED ) the documentation, please
tell me where I should be looking.

GRIPE ON

MS generates reasonably good tools and documentation, but the INDEXes STINK

GRIPE OFF

Philip Freidin @ AMD SUNYVALE on {favorite path!amdcad!philip)
Section Manager of Product Planning for Microprogrammable Processors
(you know.... all that 2900 stuff...)
"We Plan Products; not lunches" (a quote from a group that has been standing
				 around for an hour trying to decide where
				 to go for lunch)

ddl@husc6.harvard.edu (Dan Lanciani) (01/04/88)

In article <19793@amdcad.AMD.COM>, philip@amdcad.AMD.COM (Philip Freidin) writes:
| I have seen some vague mention of the ability to write interrupt handlers
| in msc v5.0. I have exhaustively searched (RTFFFFFFM) the docs, and none
| of the table of contents, or indexes seem to have anything relevant to my
| search. 
| ...
| WHY CANT I FIND ANY DOCUMENTATION ON THIS RESERVED WORD??????????

	Most notably missing from the reserved word list...

| If anyone has found (and dare I hope.... USED ) the documentation, please
| tell me where I should be looking.

	Documentation on this advanced feature is found in supplementary
material available from Borland :->  Unfortunately, you must buy TurboC
to get it...  (Yes, it seems to do more-or-less what you would think,
saving registers and using iret's.)

					Dan Lanciani
					ddl@harvard.*

mason@tc.fluke.COM (Nick Mason) (01/04/88)

In article <3704@husc6.harvard.edu> ddl@husc6.harvard.edu (Dan Lanciani) writes:
>In article <19793@amdcad.AMD.COM>, philip@amdcad.AMD.COM (Philip Freidin) writes:
>| I have seen some vague mention of the ability to write interrupt handlers
>| in msc v5.0. I have exhaustively searched (RTFFFFFFM) the docs, and none
>| of the table of contents, or indexes seem to have anything relevant to my
>| search. 
>| ...
>| WHY CANT I FIND ANY DOCUMENTATION ON THIS RESERVED WORD??????????
>
>	Most notably missing from the reserved word list...
>
>| If anyone has found (and dare I hope.... USED ) the documentation, please
>| tell me where I should be looking.
>

 Its in the readme.doc file on the distribution disks.  On about page 6.


Nick Mason/ms272G/John Fluke Mfg Co/Box C9090/Everett WA 98206 USA
   mason@tc.fluke.COM
UUCP:
   {{cornell,decvax,ihnp4,sdcsvax,tektronix,utcsrgv}!uw-beaver} \
{allegra,microsoft,gatech!sb1,hplabs!lbl-csam,decwrl!sun,sunup} - !fluke!mason
 {ssc-vax,hplsla,wavetek,physio,uw-vlsi,cae780,tikal,telematic} /
ARPA: fluke!mason@uw-beaver.ARPA
BITNET: "fluke!mason@uw-beaver.ARPA"@wiscvm.bitnet
"Avoid the Dull and Ignorant"

robf2@pyuxf.UUCP (robert fair) (01/05/88)

] Well hidden in the library manual, are the routines:
] (...) 
] discreatly embedded in these descriptions, are lines like
] 
] interrupt far *target;		(page 155, 206, 224)
] 
] which looks like a reserved word (interrupt) used to trigger the compiler
] to use a RETI rather than a RET or RETF instruction. 
] 
] WHY CANT I FIND ANY DOCUMENTATION ON THIS RESERVED WORD??????????
] 
] If anyone has found (and dare I hope.... USED ) the documentation, please
] tell me where I should be looking.

Check the README file on the main distribution disk, it describes "interrupt"
as well as lots of other goodies, including more optimization flags (-On),
linker flags (-NOE), programs for compressing codeview debug code in files
and on and on and on. There are several other README files as well
throughout the package for things like creating quicklibraries, handling
floating point errors etc. 

Always check for a README file with any package - lots of vendors use them.

(BTW, I get the distinct feeling the MSC 5.0 packing was put together in 
a big hurry ! ;-) )

Rob Fair
Currently at:
Bellcore/CHC
ihnp4!pyuxww!pyuxf!robf2

kworrell@ccvaxa.UUCP (01/05/88)

I had some difficulty with this as well.

For documentation, read through the README file on one of the
disks you got.

Interrupt is indeed a reserved word.  It just
tells the compiler to save all the registers on entry, restore
on exit, and use iret instead of ret.

Be careful using any of the MSC library functions which could in
any way shape or form issue system calls.  I used the list, in one
of the appendixes, which described what things you could/couldn't use
for ROMable code.  Read the warnings in that section closely!

Another thing, be sure to use the stack check pragma or the -Gs
option or any routines you call from inside your handler will give
you an error like 'R6000 Stack Overflow.'

Some of the routines you cited are used for TSR's rather than just
interrupt handling.  You don't necessarily need to write interrupt
handlers as TSR's.


Why don't you post or mail me other responses you recieve.  I'm
always interested what others find out (why reinvent the wheel!).

Kurt.


------------------------------------------------------------------------
Kurt J. Worrell	                 USEnet:  ihnp4!uiucdcs!ccvaxa!kworrell
Gould CSD-Urbana                 ARPAnet: kworrell@gswd-vms.arpa
1101 E. University               BELLnet: (217) 384-8500, x740
Urbana, IL 61801

steven@uicsgva.UUCP (01/05/88)

It must not have made it into the printers in time ...

Look in the readme.doc on your setup disk.  'Interrupt' does indeed
cause the generation of an IRET instead of a RET.  Its all described
in the readme.

steven
steven%polaris@uxc.cso.uiuc.edu

kevin@trsvax.UUCP (01/06/88)

The "interrupt" keyword doesn't seem to be documented anywhere except in
the README file on the installation diskettes.  On every release of MSC
so far (from 3.0 on), there's been at least one feature not mentioned
*anywhere* in the printed document.  This is just the latest one.

It not only generates an IRET instead of a return, it saves all registers,
and if you have suitable parameter declarations, you can change the registers
that get restored to the caller.  The order of parameters is documented in
the README file (I think it's called README.DOC but I'm not positive -- it's
on the setup diskette, though).

hope this helps...

				kevin dack

				kevin@trsvax.Tandy.COM
					-or-
				...!ihnp4!sys1!hal6000!trsvax!kevin

Standard disclaimers apply.

Usenet_area_"Cs.I.Pc"@watmath.waterloo.edu (01/07/88)

From Usenet: ninja!sys1!trsvax!kevin
From: kevin@trsvax.UUCP
Newsgroups: comp.sys.ibm.pc
Subject: Re: Interrupt handlers in MSC-V5
Message-ID: <216100014@trsvax>
Date: 5 Jan 88 19:22:00 GMT
References: <19793@amdcad.AMD.COM>
Lines: 21
Nf-ID: #R:amdcad.AMD.COM:19793:trsvax:216100014:000:762
Nf-From: trsvax.UUCP!kevin    Jan  5 13:22:00 1988


The "interrupt" keyword doesn't seem to be documented anywhere except in
the README file on the installation diskettes.  On every release of MSC
so far (from 3.0 on), there's been at least one feature not mentioned
*anywhere* in the printed document.  This is just the latest one.

It not only generates an IRET instead of a return, it saves all registers,
and if you have suitable parameter declarations, you can change the registers
that get restored to the caller.  The order of parameters is documented in
the README file (I think it's called README.DOC but I'm not positive -- it's
on the setup diskette, though).

hope this helps...

				kevin dack

				kevin@trsvax.Tandy.COM
					-or-
				...!ihnp4!sys1!hal6000!trsvax!kevin

Standard disclaimers apply.

--- via UGate v1.6
 * Origin: watmath (221/163)