0

I am building arm-eabi-gcc with gcc 6.3.0 source, to target the Atmel AT91SAM9G45 processor.

What should I use for the cpu / arch / tune flags when configuring the gcc build?

Using --with-arch=armv9 returns Unknown arch used. It appears to accept --with-cpu=armv9, and not passing an arch flag, but I'm not sure if this is right for this particular CPU. It also accepts --with-cpu=arm9 and I'm not sure what the difference between the two is, or if either is right for my CPU.

Also, what should I use for the --with-fpu option? My software will not be using any floating point operations so I am using --with-float=hard, but I don't know what to do for the fpu option in this case.

M.M
  • 138,810
  • 21
  • 208
  • 365

1 Answers1

1

What should I use for the cpu / arch / tune flags when configuring the gcc build?

As can be seen from the datasheet, AT91SAM9G45 includes an old ARM926EJ-S core. It's supported by GCC via arm926ej-s name (search for supported -mtune values here). So I'd suggest to use --with-cpu=arm926ej-s.

As for distinction between --with-tune, --with-arch and --with-cpu, see this answer, TLDR is that --with-cpu is preferred).

Using --with-arch=armv9 returns Unknown arch used.

Don't confuse ARM9 and ARMv9 - they are totally different things.

Also, what should I use for the --with-fpu option?

I don't think ARM9 supports FP in hardware so you should use --with-float=soft.

Community
  • 1
  • 1
yugr
  • 19,769
  • 3
  • 51
  • 96