Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!clyde!cuae2!ltuxa!cuuxb!wbp From: wbp@cuuxb.UUCP (Walt Pesch) Newsgroups: comp.lang.c,comp.unix.wizards Subject: Re: who called a C routine - get it from the stack frame Message-ID: <965@cuuxb.UUCP> Date: Mon, 8-Dec-86 13:58:33 EST Article-I.D.: cuuxb.965 Posted: Mon Dec 8 13:58:33 1986 Date-Received: Tue, 9-Dec-86 03:48:16 EST References: <810@hropus.UUCP> <961@cuuxb.UUCP> <1502@ulysses.UUCP> <963@cuuxb.UUCP> Reply-To: wbp@cuuxb.UUCP (Walt Pesch) Distribution: comp Organization: AT&T-IS, Customer Support, Lisle, Il. Lines: 17 Xref: mnetor comp.lang.c:311 comp.unix.wizards:295 This is what I get for looking at too many 3B crash dumps - it gets to you after a while. Y'all are right, the stack frame is not only dependant on the OS but also very much machine specific. For AT&T SV releases on the 3B line, the Stack Frame does look like what I showed, and it does grow downwards in memory (i.e. the stack pointer is incremented in a push operation). For the AT&T System V on the Vax, it still looks the same but grows upwards in memory (i.e. the stack pointer is decremented in a puch operation). For anything else, my advice would be to get into crash and dump the stack for a couple of procs and figure it out yourself. If you're lucky, the stack dump will also contain a pretty picture showing yoy exactly what to look for. Walt Pesch {ihnp4,akgua,et al}!cuuxb!wbp cuuxb!wbp@lll-crg