about summary refs log tree commit diff
path: root/src/test/run-pass/thinlto
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2016-11-19 04:58:48 -0800
committerGitHub <noreply@github.com>2016-11-19 04:58:48 -0800
commitfb025b483a5ef96bba944055c47af620d2afb602 (patch)
tree2336c788877ce66122323cd03bc36773f86a6f4e /src/test/run-pass/thinlto
parentaa97dafe018de235b544b13e5beceba1b5d0593b (diff)
parent456ceba13784f2f88f7f21239e308a0f195967a1 (diff)
downloadrust-fb025b483a5ef96bba944055c47af620d2afb602.tar.gz
rust-fb025b483a5ef96bba944055c47af620d2afb602.zip
Auto merge of #37814 - japaric:aapcs, r=alexcrichton
fix `extern "aapcs" fn`

to actually use the AAPCS calling convention

closes #37810

This is technically a [breaking-change] because it changes the ABI of
`extern "aapcs"` functions that (a) involve `f32`/`f64` arguments/return
values and (b) are compiled for arm-eabihf targets from
"aapcs-vfp" (wrong) to "aapcs" (correct).

Appendix:

What these ABIs mean?

- In the "aapcs-vfp" ABI or "hard float" calling convention: Floating
point values are passed/returned through FPU registers (s0, s1, d0, etc.)

- Whereas, in the "aapcs" ABI or "soft float" calling convention:
Floating point values are passed/returned through general purpose
registers (r0, r1, etc.)

Mixing these ABIs can cause problems if the caller assumes that the
routine is using one of these ABIs but it's actually using the other
one.

---

r? @alexcrichton We are going this `extern "aapcs" fn` thing to implement some intrinsics (floatundidf) for the eabihf targets in order to comply with LLVM's calling convention of intrinsics.

Oh, and the value of the enum came from [here](http://llvm.org/docs/doxygen/html/namespacellvm_1_1CallingConv.html).

cc @TimNN @parched
Diffstat (limited to 'src/test/run-pass/thinlto')
0 files changed, 0 insertions, 0 deletions