From owner-freebsd-alpha Tue Feb 11 14: 2:24 2003 Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C243637B401 for ; Tue, 11 Feb 2003 14:02:22 -0800 (PST) Received: from imul.math.uni.lodz.pl (imul.math.uni.lodz.pl [212.191.65.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 94B9F43F85 for ; Tue, 11 Feb 2003 14:02:21 -0800 (PST) (envelope-from mg@fork.pl) Received: from fork.pl (imul.math.uni.lodz.pl [212.191.65.2]) by imul.math.uni.lodz.pl (Mail Transport Agent) with ESMTP id 650911F18 for ; Tue, 11 Feb 2003 22:58:43 +0100 (CET) Message-ID: <3E4972B9.5060102@fork.pl> Date: Tue, 11 Feb 2003 23:01:29 +0100 From: Marcin Gryszkalis Organization: fork.pl User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3b) Gecko/20030208 X-Accept-Language: en-us, en, pl MIME-Version: 1.0 To: alpha@FreeBSD.ORG Subject: Re: Open Watcom compiler References: <20030211003353.GA12187@athlon.pn.xcllnt.net> <15945.1278.292937.743702@grasshopper.cs.duke.edu> <20030211192217.GD2881@dhcp01.pn.xcllnt.net> <20030211214435.GI1877@gsmx07.alcatel.com.au> In-Reply-To: <20030211214435.GI1877@gsmx07.alcatel.com.au> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-freebsd-alpha@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org > I don't know what the OW support for inline assember is. There's Watcom FAQ made by Paul Hsieh, go to http://www.azillionmonkeys.com/qed/watfaq.shtml#27 for more information on inline assembly in watcom. In short, it's usually (always?) function-based mode but you can specify which registers are parameters, which are modified (so the compiler know) and which is return value. eg. void DWORDCopy(long *Source, long *Destination, int Length); #pragma aux DWORDCopy = " rep movsd " parm [ESI] [EDI] [ECX] modify [ESI EDI ECX]; or double RDTSC(void); #pragma aux RDTSC = " .586 " \ " rdtsc " \ " push edx " \ " push eax " \ " fild qword [esp] " \ " pop eax " \ " pop edx " \ modify [eax edx] value [8087]; (I have no idea what it does, just copy-n-paste :) ) -- Marcin Gryszkalis http://fork.pl <>< To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-alpha" in the body of the message