Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!ames!oliveb!sun!gorodish!guy From: guy@gorodish.UUCP Newsgroups: comp.arch Subject: Re: Interrupt vectors. Message-ID: <20461@sun.uucp> Date: Fri, 5-Jun-87 14:53:30 EDT Article-I.D.: sun.20461 Posted: Fri Jun 5 14:53:30 1987 Date-Received: Sat, 6-Jun-87 20:02:54 EDT References: <7408@boring.cwi.nl> <438@winchester.UUCP> Sender: news@sun.uucp Lines: 40 In article <7408@boring.cwi.nl> jack@cwi.nl (Jack Jansen) writes: > Now, given most modern operating systems, this is exactly what you > *don't* want. If you want to handle interrupts in a high-level > language, you want all interrupts to jump to the same routine, and > have the interrupt number handy somewhere. Operating Systems I'm > familiar with all simulate this by either stealing a couple of bits > in the PSR and go through pains to extract them again in the common > interrupt routine, or, even worse, provide lots and lots of twisty little > routines, all slightly different In the OSes I'm familiar with, all interrupts *for a given type of device* ultimately end up calling the same routine, providing a unit number as an argument, but interrupts for two different devices end up calling two different routines. I presume you're talking about the initial trap, though; the code invoked by that trap could figure out both which interrupt routine to call (i.e., which type of device is interrupting) and what unit number to pass as an argument (i.e., which of those devices is interrupting). In article <438@winchester.UUCP>, mash@mips.UUCP (John Mashey) writes: > Sure. The MIPS R2000 has 3 vectors: RESET, User TLBMISS (software handler > for TLBmisses for the most frequent case, i.e., frequency makes it > the only one worth a special case), and everything else. It does > what you say. The diagram in "Operating System Support on a RISC" shows both the Status and Cause registers. The Cause register includes a 6-bit ExtInt field, which I presume is a bitset indicating which of the 6 external interrupts are pending. To what do these 6 interrupts correspond? Do they correspond to classes of devices? I presume you are not limited to 6 different devices attached to a system containing an R2000, so you would "double up" on external interrupts as necessary. If so, how are the devices distinguished? Is this done with polled interrupts, or is some code provided in one of the other special registers? Guy Harris {ihnp4, decvax, seismo, decwrl, ...}!sun!guy guy@sun.com