aboutsummaryrefslogtreecommitdiff
path: root/libgo
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2024-02-01 08:02:27 -0800
committerH.J. Lu <(no_default)>2024-02-05 11:08:06 -0800
commit51f8ac3341078303e81e72d9013698a31c5ddd29 (patch)
tree28829f5cd1502a8aec2fa6045e17b216b2230c28 /libgo
parent62babed519afba58b7efeb0e968d97a666b68fd3 (diff)
downloadgcc-51f8ac3341078303e81e72d9013698a31c5ddd29.zip
gcc-51f8ac3341078303e81e72d9013698a31c5ddd29.tar.gz
gcc-51f8ac3341078303e81e72d9013698a31c5ddd29.tar.bz2
x86-64: Find a scratch register for large model profiling
2 scratch registers, %r10 and %r11, are available at function entry for large model profiling. But %r10 may be used by stack realignment and we can't use %r10 in this case. Add x86_64_select_profile_regnum to find a caller-saved register which isn't live or a callee-saved register which has been saved on stack in the prologue at entry for large model profiling and sorry if we can't find one. gcc/ PR target/113689 * config/i386/i386.cc (x86_64_select_profile_regnum): New. (x86_function_profiler): Call x86_64_select_profile_regnum to get a scratch register for large model profiling. gcc/testsuite/ PR target/113689 * gcc.target/i386/pr113689-1.c: New file. * gcc.target/i386/pr113689-2.c: Likewise. * gcc.target/i386/pr113689-3.c: Likewise.
Diffstat (limited to 'libgo')
0 files changed, 0 insertions, 0 deletions