[CCing David Miller, the SPARC binutils maintainer] > I want to once again ask for write credentials so that > I can submit patches for the sparc-leon architecture: > The first patch is for the 'gcc' repository while the > second patch is for the 'binutils' repository. They are both > related so I think it makes sense to send them together. > I dont have write access to binutils eather so, I thought you > might be able to apply them on both. > Some background: Leon supports the umac/smac instructions. > The Leon3-Ft and Leon4 also support the SMP compare-and-swap (casa)
OK, so you're proposing a new 'leon' sub-architecture for binutils. > 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? > 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. 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. -- Eric Botcazou