Xref: utzoo comp.unix.questions:28027 comp.unix.wizards:23847 gnu.g++.help:325 comp.unix:803 comp.lang.c++:11119 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!think.com!snorkelwacker.mit.edu!ai-lab!ai.mit.edu!gnulists From: wilson@mimsy.umd.edu (Anne Wilson) Newsgroups: comp.unix.questions,comp.unix.wizards,gnu.g++.help,comp.unix,comp.lang.c++ Subject: Interrupt handlers - how are they different? Keywords: interrupts, interrupt handlers, system call, C++, BSD Message-ID: <28937@mimsy.umd.edu> Date: 5 Jan 91 21:53:39 GMT Reply-To: wilson@mimsy.umd.edu (Anne Wilson) Followup-To: comp.lang.c++ Organization: U of Maryland, Dept. of Computer Science, Coll. Pk., MD 20742 Lines: 34 Approved: info-gnu@prep.ai.mit.edu To: gnu-g++-bug@uunet.uu.net --text follows this line-- (Because I don't know the best place to post this, I am posting to a bunch of groups. My apologies if this message is either posted to an inappropriate group, or you've seen it too many times!) I have a C++ program which creates several "concurrently" running processes. They communicate via pipes and interrupts. I have designated a particular routine to be the interrupt handler for these communications. I have defined a class called Message. One of the members of the class message is the function recv_Message, which I have designated as the interrupt handler. My question is this: how is this interrupt handler different than other C++ routines with respect to its environment/context? I understand that this handler is called by the system rather than by the compiler. I am concerned about passing information to the handler. Apparently, I can't pass any arguments to the handler. Additionally, when the handler is invoked by the system it doesn't know the current values of other members of its own class, ie. the values of those members are garbage. The only way I have found to communinicate information to this handler is through a global variable. This is barely acceptable and unsatisfying. I am running GNU g++ V1.37.1 on BSD Unix on a VAX. Any comments or suggestions would be appreciated. Please email to me directly. Thanks tons in advance. Anne Wilson wilson@mimsy.cs.umd.edu