Subject: Re: Floating Point Instruction Register And As
To: None <andyf@vei.net, port-mac68k@netbsd.org>
From: Ken Nakata <knakata@itpjp.co.jp>
List: port-mac68k
Date: 06/23/1999 10:50:44
On Tue, 22 Jun 1999 17:50:36 -0400, Andy Finnell <andyf@vei.net> wrote:
> I'm having a little trouble referencing the floating point instruction
> register when using as.  According to Motorola's 68k PM, the register is
> called fpiar, and can be read and written to using the fmovel
> instruction.  However when I try to do this (either read or write), as
> complains that there is a instruction/operand mismatch.  I soon found
> that the assembler doesn't recongize fpiar as a fp register.  Does
> anyone know what as calls the floating point instruction register?  I
> can't think of any C code I could compile down that would modify the
> fpiar explicitly.

And I wrote:
> I know, but I forgot (DUH).  Well, seriously, I'd suggest that you
> read the info file that comes with gas.  It has a section for assembly
> syntax of each processor architecture gas supports.

OK, I lied.  I checked the current src/gnu/dist/gas directory, and the 
texinfo files in there don't have detailed opcode syntax.

However, you can see how they are actually used by reading
src/sys/arch/mac68k/mac68k/locore.s.  For instance, the file has the
following two instructions:

	fmovem	fp0-fp7,a2@(216)	| save FP general registers
	fmovem	fpcr/fpsr/fpi,a2@(312)	| save FP control registers

"fpi" here is your "fpiar", I think.

Hope it helps,

Ken