-
Bug
-
Resolution: Won't Fix
-
Not Prioritized
-
Code Generation Tools
-
CODEGEN-11452
-
C6000_8.3.12
-
default
-
Behavior undefined in C++ standards.
The attached file.cpp has a loop that uses type punning, via a union, to copy the high or low part of int32_t elements from an input array into int16_t elements of an output array. However, the loop does not advance through the input array.
Build the attached file ...
$ cl6x -mv6600 -o -s file.cpp
These are the compiler generated comments for the inner loop ...
;** -----------------------g3: ;** 16 ----------------------- *U$27++ = U$25; ;** 13 ----------------------- if ( L$1 = L$1-1 ) goto g3;
U$27 advances through the output array. But there is no corresponding pointer to advance through the input array.