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

Register Variable

hi
i want to migrate from arm compiler 5 to 6

compiler 5 uses for following local variable a register (e.g. r0) register unsigned long len;

compiler 6 does not
why?
which keyword should i use therefore

Parents
  • That is almost certainly due to problems in your source code.

    "my source is already optimized"

    You can't really optimise a HLL at the source level - certainly not to the point of dictating specific register usage.

    If you've tried to do stuff like that at the HLL source lever, it is quite likely counter-productive

    You should write the HLL source to be clear & maintainable, and let the compiler do the optimisation.

Reply
  • That is almost certainly due to problems in your source code.

    "my source is already optimized"

    You can't really optimise a HLL at the source level - certainly not to the point of dictating specific register usage.

    If you've tried to do stuff like that at the HLL source lever, it is quite likely counter-productive

    You should write the HLL source to be clear & maintainable, and let the compiler do the optimisation.

Children