I'll send new patches as a reply. Eric Botcazou wrote: > [CCing David Miller, the SPARC binutils maintainer] > OK, so you're proposing a new 'leon' sub-architecture for binutils.
Yes. > >> The appended 2 patches do: >> 1. 0001-sparc-leon-Use-Aleon-assembler-switch-for-mcpu-leon-.patch >> Append "-Aleon" to the assembler > > This looks incomplete. Don't you also want to enable the instructions? The [casa,smac,umac] are used as inline assembler only. > >> 2. 0001-sparc-leon-add-leon-architecture-to-GAS.patch >> Define new "leon" processor type in GAS + enable for "leon" >> umac/smac and "casa". > > The configure.tgt change looks useless to me. I have removed it, if gcc's "-Aleon" would be added it is not needed. > > Other nits: > > @@ -1668,9 +1671,8 @@ EFPOP2_2 ("efcmpes", 0x055, "e,f"), > { "cpop2", F3(2, 0x37, 0), F3(~2, ~0x37, ~1), "[1+2],d", F_ALIAS, v6notv9 > }, > > /* sparclet specific insns */ > - > -COMMUTEOP ("umac", 0x3e, sparclet), > -COMMUTEOP ("smac", 0x3f, sparclet), > +COMMUTEOP ("umac", 0x3e, sparclet|MASK_LEON), > +COMMUTEOP ("smac", 0x3f, sparclet|MASK_LEON), > COMMUTEOP ("umacd", 0x2e, sparclet), > COMMUTEOP ("smacd", 0x2f, sparclet), > COMMUTEOP ("umuld", 0x09, sparclet), > > sparclet|leon > > -{ "casa", F3(3, 0x3c, 0), F3(~3, ~0x3c, ~0), "[1]A,2,d", 0, v9 }, > -{ "casa", F3(3, 0x3c, 1), F3(~3, ~0x3c, ~1), "[1]o,2,d", 0, v9 }, > +{ "casa", F3(3, 0x3c, 0), F3(~3, ~0x3c, ~0), "[1]A,2,d", 0, v9|MASK_LEON > }, > +{ "casa", F3(3, 0x3c, 1), F3(~3, ~0x3c, ~1), "[1]o,2,d", 0, v9|MASK_LEON > }, > > v9|leon > > +{ "cas", F3(3, 0x3c, 0)|ASI(0x80), F3(~3, ~0x3c, ~0)|ASI(~0x80), > "[1],2,d", > F_ALIAS, v9|MASK_LEON }, /* casa [rs1]ASI_P,rs2,rd */ > +{ "casl", F3(3, 0x3c, 0)|ASI(0x88), F3(~3, ~0x3c, ~0)|ASI(~0x88), > "[1],2,d", > F_ALIAS, v9|MASK_LEON }, /* casa [rs1]ASI_P_L,rs2,rd */ > > Likewise. > I fixed that.