Other Parts Discussed in Thread: LAUNCHXL2-570LC43
Tool/software: Code Composer Studio
In the related thread a program was created for the big-endian TMS570LC4357, but with gcc set to create a little endian program as reported by readelf:
$ readelf -h ~/workspace_v10/TMS570LC4357_GCC_halcogen/Debug/TMS570LC4357_GCC_halcogen.out ELF Header: Magic: 7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00 Class: ELF32 Data: 2's complement, little endian Version: 1 (current) OS/ABI: UNIX - System V ABI Version: 0 Type: EXEC (Executable file) Machine: ARM Version: 0x1 Entry point address: 0xac94 Start of program headers: 52 (bytes into file) Start of section headers: 362228 (bytes into file) Flags: 0x5000400, Version5 EABI, hard-float ABI Size of this header: 52 (bytes) Size of program headers: 32 (bytes) Number of program headers: 3 Size of section headers: 40 (bytes) Number of section headers: 22 Section header string table index: 21
When I went to load this program with the wrong endianess using CCS 10 I expected to get an error that the target endianess didn't match that of the program. However, no such error was reported by CCS 10 which flashed the program, which then promptly generated an Undefined Instruction Exception when attempted to execute the first instruction.
When I tried the same program with CCS 9.0.1.00004 and TI Emulators 8.2.0.00004 I got the expected error on attempting to load the program:
Is it a bug that CCS 10.0.0.00010 with TI Emulators 9.1.0.00001 doesn't report an error on attempting to load a program for a Cortex-R5 with a target endianess which doesn't match the program?
