This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28379D: XAR0 default value is 0xFFFFFFFF

Part Number: TMS320F28379D

Hello,

I was working on some assembly code, and at the beginning of the code I had these instructions:

MOV      AR0, #someAddress

MOV      AL, *AR0

where someAddress was 0x8000 in this scenario.

I noticed that the value at 0x8000 wouldn't get stored into AL, and after some investigating I saw that register XAR0 defaulted to 0xFFFFFFFF. So, after running those instructions, I would actually be looking at address 0xFFFF8000, which is of course incorrect. Using this instruction fixed the issue, as expected:

MOVL     XAR0, #someAddress

My question is, why does XAR0 default to 0xFFFFFFFF while all of the other XARn registers default to 0? The original instruction was written with the assumption that XAR0 defaulted to 0, and the series of instructions still works for the other auxiliary registers. I've tried looking in the TRM, datasheet, CPU instruction set manual, and errata but I couldn't seem to find any information on this.

Here is an image of what I am referring to. The screenshot was taken before a single line of code was run.

Thank you for your help!

Colin

  • Hello Collin,

    When CPU comes out of reset it would have been the 0x0, but once it executes and leaves out of boot based on different boot schemes, register contents might be different. So if you are using assembly, please do make sure all the registers are initialized as needed.

    Hope this clarifies.