Hi everyone,
I’ve noticed a variation in the code generated by the C2000 compiler after switching from 6.2.7 to 6.4.3. In one function I copy the content of a union like so:
volatile union CANMC_REG shadow; shadow = ECanaRegs.CANMC;
With 6.2.7 the compiler generates a MOVL to copy the union, exactly as though I had written the following:
shadow.all = EcanaRegs.CANMC.all
With 6.4.3 however, the compiler generates a PREAD || RPT #1.
Hence my question: is this the intended behaviour?
Please note I’m not asking how to get the compiler to generate a MOVL, this much is obvious. I’m merely asking if there is a rationale behind the change of behaviour between 6.2.7 and 6.4.3 and what to expect in the next versions of the C2000 compiler.
Best regards,
Pierre