From owner-freebsd-stable Mon Nov 25 11:11:20 2002 Delivered-To: freebsd-stable@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3A24437B401 for ; Mon, 25 Nov 2002 11:11:19 -0800 (PST) Received: from mtiwmhc14.worldnet.att.net (mtiwmhc14.worldnet.att.net [204.127.131.114]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7E31D43E88 for ; Mon, 25 Nov 2002 11:11:18 -0800 (PST) (envelope-from cswiger@mac.com) Received: from prime ([12.88.90.11]) by mtiwmhc14.worldnet.att.net (InterMail vM.5.01.05.12 201-253-122-126-112-20020820) with SMTP id <20021125191117.SOWH21264.mtiwmhc14.worldnet.att.net@prime> for ; Mon, 25 Nov 2002 19:11:17 +0000 Message-ID: <004b01c294b6$6e371ea0$0301a8c0@prime> From: "Charles Swiger" To: References: <3DE149C7.2030607@math.missouri.edu> <3DE14D21.8070905@math.missouri.edu> <3DE248AC.8C54C273@softweyr.com> <3DE2662D.3070404@math.missouri.edu> Subject: Re: running many programs on multiprocessor system Date: Mon, 25 Nov 2002 14:11:16 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Stephen Montgomery-Smith wrote: [ ... ] > In the mean time, can anyone tell me or point to me documentation > telling me any kind of rules that assembler functions called from C > programs have to obey? (And maybe vice versa.) Whether a given chunk of code was orignally written in assembler or in C doesn't matter, since C programs usually get translated into assembly by the compiler. Regardless of the origin, the code needs to follow the calling conventions of the platform, as well as the interfaces defined by the C header files; see a K&R, or "man elf" and the references from there: Hewlett Packard, Elf-64 Object File Format. Santa Cruz Operation, System V Application Binary Interface. Unix System Laboratories, "Object Files", Executable and Linking Format (ELF). In practice, compiling a small program in C and taking a look at the corresponding assembly via "cc -S" will probably be fairly helpful as well. -Chuck To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message