1 // RUN: %clang_cc1 -ffreestanding %s -triple=x86_64-apple-darwin -emit-llvm -o - | FileCheck %s
2 
3 #include <x86intrin.h>
4 
test__bswapd(int X)5 int test__bswapd(int X) {
6 // CHECK-LABEL: @test__bswapd
7 // CHECK: call i32 @llvm.bswap.i32
8   return __bswapd(X);
9 }
10 
test_bswap(int X)11 int test_bswap(int X) {
12 // CHECK-LABEL: @test_bswap
13 // CHECK: call i32 @llvm.bswap.i32
14   return _bswap(X);
15 }
16 
test__bswapq(long long X)17 long test__bswapq(long long X) {
18 // CHECK-LABEL: @test__bswapq
19 // CHECK: call i64 @llvm.bswap.i64
20   return __bswapq(X);
21 }
22 
test_bswap64(long long X)23 long test_bswap64(long long X) {
24 // CHECK-LABEL: @test_bswap64
25 // CHECK: call i64 @llvm.bswap.i64
26   return _bswap64(X);
27 }
28 
29 
30