You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This code fills up and overflows the x87 floating point stack, which doesn't crash the application but results in the stack containing nonsense values rather than the values 8.0, 9.0 expected. (This can be observed with gdb -ex start -ex 'layout asm' -ex 'tui reg float' float_to_ld.) Also the return values in the buffer are not the actual return values of the function as the wrong registers are being used.
As a more minor annoyance, even if the functions aren't used, rustc emits the warning note: 128-bit integers don't currently have a known stable ABI.
Expected Results
Either no bindings should be generated, or inline wrapper functions using inline assembly should be generated which correctly implement the calling convention. Given that Rust has no support for f80, simply omitting the bindings seems like the most pragmatic solution.
The text was updated successfully, but these errors were encountered:
GKFX
changed the title
Bindgen should not produce bindings to functions with 80-bit long doubles (f80)
Bindgen produces incorrect bindings to functions with 80-bit long doubles (f80)
Dec 31, 2022
Input C
Bindgen Invocation
bindgen float_to_ld.h
Actual Results
This code fills up and overflows the x87 floating point stack, which doesn't crash the application but results in the stack containing nonsense values rather than the values 8.0, 9.0 expected. (This can be observed with
gdb -ex start -ex 'layout asm' -ex 'tui reg float' float_to_ld
.) Also the return values in the buffer are not the actual return values of the function as the wrong registers are being used.As a more minor annoyance, even if the functions aren't used,
rustc
emits the warningnote: 128-bit integers don't currently have a known stable ABI
.Expected Results
Either no bindings should be generated, or inline wrapper functions using inline assembly should be generated which correctly implement the calling convention. Given that Rust has no support for
f80
, simply omitting the bindings seems like the most pragmatic solution.The text was updated successfully, but these errors were encountered: