Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utcs!mnetor!seismo!columbia!topaz!ll-xn!cit-vax!nike!ucbcad!ucbvax!ucsfcgl!kneller From: kneller@ucsfcgl.UUCP Newsgroups: net.micro.pc Subject: Re: Interupt initiated user-defined functions in 'C' on IBM/XT Message-ID: <9918@cgl.ucsf.edu.ucsfcgl.UUCP> Date: Wed, 16-Jul-86 17:53:26 EDT Article-I.D.: cgl.9918 Posted: Wed Jul 16 17:53:26 1986 Date-Received: Fri, 18-Jul-86 00:54:54 EDT References: <938@isis.UUCP> Reply-To: kneller@cgl.ucsf.edu.UUCP (Don Kneller%Langridge) Organization: Computer Graphics Laboratory, UCSF Lines: 26 In article <938@isis.UUCP> ross@isis.UUCP (Ross McConnell) writes: >Currently, we have >troubles obtaining the segment:offset representation of the interrupt vector. >The seg:offset obtained by ANDing a long pointer (AZTEC compiler V2.0) with >0xFFFFL and ~0xFFFFL do not appear to correctly represent the location of the >function although AZTEC says the pointers are in 32-bit seg:offset formate. > >Any information will be appreciated and may be put on the network or sent to: I'm doing this from memory and my experience is with the Microsoft C compiler, but I think that addresses are stored in memory in order as: low-word high-word The pointer would thus have the order: offset segment Given a 32-bit function pointer funp, the offset should be *((unsigned int *) funp) and the segment should be *((unsigned int *) funp + 1) -- Don Kneller UUCP: ...ucbvax!ucsfcgl!kneller ARPA: kneller@ucsf-cgl.ARPA BITNET: kneller@ucsfcgl.BITNET