Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!bbn!rochester!cornell!uw-beaver!uw-june!uw-entropy!quick!srg From: srg@quick.COM (Spencer Garrett) Newsgroups: comp.arch Subject: MIPS register handling question Message-ID: <166@quick.COM> Date: Sun, 15-Nov-87 04:25:51 EST Article-I.D.: quick.166 Posted: Sun Nov 15 04:25:51 1987 Date-Received: Mon, 16-Nov-87 04:13:19 EST Organization: Quicksilver Engineering, Seattle Lines: 18 I haven't seen one of these beasts, but I understand they have a single large register pool which their compiler allocates as needed to procedures. The idea sounded intriguing at first, but on closer examination I can't see how to avoid acting like a vax (i.e. - save the regs you're going to use at procedure entry and restore them at exit). Here are several specific questions I hope someone can answer, or maybe someone at MIPS could post a short "here's how we do it" article. 1) If you're going to have object libraries, then it would have to be the linker that really allocates the registers. How does it handle running out of registers? (since it's too late to generate code that uses fewer or saves the ones it needs) 2) How does the compiler deal with recursion? 3) How does the register allocator (compiler or linker) handle computed calls, since it can't generate a static call tree at all in this case? (i.e. - calls of the form (*pointer)(args); )