This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

code compile using -mcpu for ARM platform

When using gcc to compile c code for ARM platform, we set object platform by using:

     -mcpu = xxxxxx

To what extent will that affect results of compiling ?

For example:

     -mcpu = cortex-a8

and

     -mcpu = cortex-a9

When I use results compiled with -mcpu=cortex-a8 to run on A9 platform, will it cause some problems?

Parents Reply Children
  • Hello jayzhao,

    It would be ok because the calling and receiving conventions for functions don't vary by the cpu specification option.

    However, as fot some options (e.g. -msingle-pic-base), linking of objects which will be compiled with or without them would fail.

    Best regards,

    Yasuhiko Koumoto.