diff options
author | Ulrich Weigand <ulrich.weigand@de.ibm.com> | 2018-07-10 16:05:47 +0000 |
---|---|---|
committer | Ulrich Weigand <ulrich.weigand@de.ibm.com> | 2018-07-10 16:05:47 +0000 |
commit | b961fdc509c45a24aec122ff1a05e0e5076c0987 (patch) | |
tree | 717a4a178710fa8f1687cd58f0138c85b5ea9c2a /llvm/lib/CodeGen/DeadMachineInstructionElim.cpp | |
parent | 9ef850b8443d0745c2851ac3b7ce6570391392b2 (diff) | |
download | bcm5719-llvm-b961fdc509c45a24aec122ff1a05e0e5076c0987.tar.gz bcm5719-llvm-b961fdc509c45a24aec122ff1a05e0e5076c0987.zip |
[gcov] Fix ABI when calling llvm_gcov_... routines from instrumentation code
The llvm_gcov_... routines in compiler-rt are regular C functions that
need to be called using the proper C ABI for the target. The current
code simply calls them using plain LLVM IR types. Since the type are
mostly simple, this happens to just work on certain targets. But other
targets still need special handling; in particular, it may be necessary
to sign- or zero-extended sub-word values to comply with the ABI. This
caused gcov failures on SystemZ in particular.
Now the very same problem was already fixed for the llvm_profile_ calls
here: https://reviews.llvm.org/D21736
This patch uses the same method to fix the llvm_gcov_ calls, in
particular calls to llvm_gcda_start_file, llvm_gcda_emit_function, and
llvm_gcda_emit_arcs.
Reviewed By: marco-c
Differential Revision: https://reviews.llvm.org/D49134
llvm-svn: 336692
Diffstat (limited to 'llvm/lib/CodeGen/DeadMachineInstructionElim.cpp')
0 files changed, 0 insertions, 0 deletions