Patent ID: 7076775

Claim:
A method of reducing the power consumption of a microprocessor system which comprises a microprocessor and a memory connected by at least one bus, said microprocessor being arranged to execute a program stored in said memory, said method comprising optimising said program by carrying out the following steps: a) identifying those instructions of said program which involve a commutative operation, b) for such instructions, considering the effect of swapping operands of said commutative operation on a Hamming distance between consecutive ones of said instructions, and c) selecting an order of said operands which results in a lowest overall Hamming distance when said program is executed, wherein â€œcommutative operationâ€ includes at least one operation which is commutative only if said operation is modified, and wherein the method further includes taking into account an effect on Hamming distance of modifying said operation, and both modifying said operation and changing the order of said operands if this results in a smaller Hamming distance.