From mboxrd@z Thu Jan 1 00:00:00 1970 From: cowan@mercury.ccil.org (John Cowan) Date: Mon, 4 Jan 2016 10:09:42 -0500 Subject: [TUHS] Early Unix function calls: expensive? In-Reply-To: <20160104015906.4BF9843F88@lignose.oclsc.org> References: <20160104015906.4BF9843F88@lignose.oclsc.org> Message-ID: <20160104150942.GA17115@mercury.ccil.org> Norman Wilson scripsit: > As late as 1990, every UNIX I knew of still used the > expensive calls/ret instructions for subroutine calls. Yes, it seems I was thinking of the Lisp calling convention. > It's possible that current UNIX-descended/cloned systems > that have VAX ports, like Linux or Open/Free/NetBSD, > have had a chance to start over and do better on > subroutine calls and system calls. Does anyone know? Easily determined. The vax.md (machine description) file uses CALLS, and in any case gcc runs on both Unix and VMS, so it has to be VMS-compatible, and there is no switch to use a different calling convention (the VAX port has few switches at all: there is one to use G-format floats instead of D-format). LLVM has no VAX support at all: the llvm-gcc compiler can compile for the VAX, but only as a cross compiler. -- John Cowan http://www.ccil.org/~cowan cowan at ccil.org It's the old, old story. Droid meets droid. Droid becomes chameleon. Droid loses chameleon, chameleon becomes blob, droid gets blob back again. It's a classic tale. --Kryten, Red Dwarf