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.

How to align objects on stack?



Hi,


I am using CGT-7.4.8 for C66x and would like to align objects allocated on stack, so I can use intrinsics for aligned memory access. I tried to use the same synthax as for global objects:

void function() {
        int someArray[10];
        #pragma DATA_ALIGN (someArray, 8);
}


However, in this case I get the warning, that the DATA_ALIGN pragma can only be applied to file-level symbols.
Is there any way to make sure, local variables/arrays are aligned to double-word addresses?

Thank you in advance, Clemens