Ramon de C Valle 5d6e2d7050 Fix CFI: f32 and f64 are encoded incorrectly for c
Fix #115150 by encoding f32 and f64 correctly for cross-language CFI. I
missed changing the encoding for f32 and f64 when I introduced the
integer normalization option in #105452 as integer normalization does
not include floating point. `f32` and `f64` should be always encoded as
`f` and `d` since they are both FFI safe when their representation are
the same (i.e., IEEE 754) for both the Rust compiler and Clang.
2023-08-24 21:02:06 -07:00
..
2023-07-27 14:44:13 -07:00
2023-07-29 18:34:41 -07:00
2023-08-15 11:33:45 +02:00
2023-07-29 18:34:41 -07:00
2023-07-27 14:44:13 -07:00
2023-08-07 14:11:03 +02:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-08 15:38:40 +02:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-08-17 18:28:33 +00:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-27 14:44:13 -07:00
2023-07-08 15:38:40 +02:00
2023-07-27 14:44:13 -07:00

The files here use the LLVM FileCheck framework, documented at https://llvm.org/docs/CommandGuide/FileCheck.html.

One extension worth noting is the use of revisions as custom prefixes for FileCheck. If your codegen test has different behavior based on the chosen target or different compiler flags that you want to exercise, you can use a revisions annotation, like so:

// revisions: aaa bbb
// [bbb] compile-flags: --flags-for-bbb

After specifying those variations, you can write different expected, or explicitly unexpected output by using <prefix>-SAME: and <prefix>-NOT:, like so:

// CHECK: expected code
// aaa-SAME: emitted-only-for-aaa
// aaa-NOT:                        emitted-only-for-bbb
// bbb-NOT:  emitted-only-for-aaa
// bbb-SAME:                       emitted-only-for-bbb