Re: [PATCH RFC 12/67] MIPS: asm: asmmacro: Replace add instructions with "addui"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 13 Jan 2015, Markos Chandras wrote:

> >> What ADDU macro?
> > 
> >  This:
> > 
> > {"addu",		"t,r,I",	0,    (int) M_ADDU_I,	INSN_MACRO,		0,		I1,		0,	0 },
> > 
> > (from opcodes/mips-opc.c).
> 
> I see your point about having 32-bit offsets supported here but it's not
> obvious that addu would simply accept this format without looking at the
> binutils sources.

 All MIPS assemblers support it AFAIK, including SGI's MIPSpro and the 
original MIPS Co. assembler.

 You will have it documented in any reasonable MIPS assembly language 
manual, and other books on the MIPS architecture will have it too.  All 
MIPS ALU operations have a corresponding macro that handles an arbitrary 
third argument, including 32-bit immediates, e.g. AND, NOR, SUBU, etc.  
Some branches and other operations are macros too.

 If you have been unaware of this fact, then I suggest you that you have a 
look at a MIPS assembly book, e.g. the book I started with had all the 
macros and what they actually expand to listed, in addition to true 
hardware instructions up to MIPS IV.

  Maciej




[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux