Distributed Software

The chapter describes the distributed software excluding the compiler and linker as well as additional files.

Licenses

Software license management tool

The HighTec LLVM toolchain install package doesn’t include the license server, which is available upon request.

Binary tools

Naming

The names of the LLVM utils are of the form bin\llvm-<name>.exe.
Example:

Tab. 1. Toolchain Binutils
GNU LLVM
tricore-addr2line.exe
llvm-addr2line.exe
tricore-ar.exe
llvm-ar.exe
tricore-nm.exe
llvm-nm.exe
tricore-objcopy.exe
llvm-objcopy.exe
tricore-objdump.exe
llvm-objdump.exe
tricore-ranlib.exe
llvm-ranlib.exe
tricore-readelf.exe
llvm-readelf.exe
tricore-size.exe
llvm-size.exe
tricore-strings.exe
llvm-strings.exe
tricore-strip.exe
llvm-strip.exe
llvm-objcopy s-record

The LLVM utility doesn’t generate the s-record file format.
$(TOOLCHAIN)-objcopy -O srec input output
Example:

Code 1. To generate s-record file in the GNU toolchain:
# tricore-objcopy -O srec tc37x_bsp_example.elf test.srec
Code 2. If the same command is given for LLVM, s-record file will not be generated:
# llvm-objcopy -O srec tc37x_bsp_example_llvm.elf test.srec
llvm-objcopy.exe: error: invalid output format: 'srec'
llvm-objdump XML

The utility doesn’t support the XML output, option --xml-output=FILE.

llvm-objdump

Cannot disassemble hex files.

llvm-objdump -S (--source)

Source comments are not visible in LLVM utility.
$(TOOLCHAIN)-objdump -d -S name.elf
Example:

Code 3. GNU:
# tricore-objdump -d -S -m tricore tc37x_bsp_example.elf
Code 4. LLVM:
# llvm-objdump -d -S tc37x_bsp_example_llvm.elf
ObjDump S
Fig. 1. objdump -S outcome
llvm-objdump -D or -d

LLVM does not generate the symbolic name for options -D (--disassemble-all) and -d (--disassemble).
Example:

Code 5. GNU:
# tricore-objdump -D -m tricore tc37x_bsp_example.hex
Code 6. LLVM:
# llvm-objdump -D tc37x_bsp_example_llvm.elf
Objdump D
Fig. 2. objdump -D outcome

A possible workaround is to mix the disassembled output with the list of relocation entries: -r option of objdump. Since the linker removes all resolved relocation entries by default, the linker option --emit-relocs should be used for linking, so the llvm-objdump -d -r will have the required info to show the reloc entries.

Code 7. LLVM:
# llvm-objdump -d -r tc37x_bsp_example_llvm.elf
Objdump D r
Fig. 3. objdump -d -r outcome
llvm-objdump -i, --info

Not supported

llvm-objdump -m <machine>, --architecture=<machine>

Not supported

ld.lld (clang)

The linker doesn’t generate the Mapfile with XML output.

Customers transitioning from 4.9.x to 5.0.
Beginning with version 5.0.0 of the HighTec TriCore™ Development Platform, the default linker is LLVM’s ld.lld. Customers which still rely on the tricore-ld linker from version 4.9.x of the HighTec TriCore™ Development Platform can use --ld-path=tricore-ld to use the old GNU linker.
The compiler does not propagate the required ISA selection option to tricore-ld. -Wl,--mcpu={tc161|tc162|tc18} must be specified on the command line for clang or tricore-ld will fail.
tricore-ld is deprecated, not officially supported and will be removed in a future release of the toolchain. Furthermore, features like exceptions might not work properly when using the tricore-ld linker.
Libos.src

Libos.src is not present in the LLVM toolchain.

Libos
Fig. 4. Toolchain install folder

Built-in resources

Start-up code

The LLVM toolchain doesn’t include default start-up codes for supported devices. This code is part of the BSP example projects accessible via the HighTec IDE Content Manager or on request.

Utility header files

Utility files originally provided in the tricore/machine directory are no longer provided in the LLVM toolchain. This includes files such as cint.h and wdtcon.h. A workaround for setting the rounding mode without fenv.h is to use provided intrinsics. No functionality reduction is brought by this change.

Target header files

The toolchain doesn’t contain any target-specific header files. The latest files are provided by the chip vendor. A limited selection is a part of the BSP example projects accessible via the HighTec IDE Content Manager or on request.

TargetHeaderFiles
Fig. 5. Toolchain install folder - Target Header Files
Linker scripts

The toolchain doesn’t contain any linker scripts. A limited selection is a part of the BSP example projects accessible via the HighTec IDE Content Manager or on request.

Intrinsic functions

The functions are built into clang. Source code isn’t provided.

Customers transitioning from 4.9.x or 5.x to 5.2.0
Starting with version 5.2.0 of the HighTec TriCore™ toolchain, most target intrinsics are implemented as compiler builtins and now follow a strict naming scheme. This makes them incompatible with some of the intrinsics provided by earlier versions. The old intrinsics have been deprecated and will be removed in later versions.
If your application still relies on the old intrinsics, you may use the <machine/intrinsics.h> header while you transition to the new builtins.
Customers transitioning from 4.9.x or 5.x to 7.0.x
Use the <tricoreintrin.h> header while transitioning to the new builtins.