We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0631ea5 commit 5663bb3Copy full SHA for 5663bb3
1 file changed
src/test/codegen/issue-85872-multiple-reverse.rs
@@ -0,0 +1,20 @@
1
+// min-llvm-version: 15.0.0
2
+// compile-flags: -O
3
+
4
+#![crate_type = "lib"]
5
6
+#[no_mangle]
7
+pub fn u16_be_to_arch(mut data: [u8; 2]) -> [u8; 2] {
8
+ // CHECK-LABEL: @u16_be_to_arch
9
+ // CHECK: @llvm.bswap.i16
10
+ data.reverse();
11
+ data
12
+}
13
14
15
+pub fn u32_be_to_arch(mut data: [u8; 4]) -> [u8; 4] {
16
+ // CHECK-LABEL: @u32_be_to_arch
17
+ // CHECK: @llvm.bswap.i32
18
19
20
0 commit comments