Skip to content

Commit 090e612

Browse files
authored
[CIR][NFC] Resolve various nits for builtin bit operations (#148378)
This patch contains fixes for various nits mentioned in #147200: - This patch removes the `bit.` prefix in the op mnemonic. The operation names now directly correspond to the builtin function names except for `bswap` which is represented by `cir.byte_swap` for more clarity. - Since all bit operations are `SameOperandsAndResultType`, this patch updates their assembly format and avoids spelling out the operand type twice.
1 parent 508f9a0 commit 090e612

File tree

2 files changed

+50
-56
lines changed

2 files changed

+50
-56
lines changed

clang/include/clang/CIR/Dialect/IR/CIROps.td

Lines changed: 23 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -2705,7 +2705,7 @@ class CIR_BitOpBase<string mnemonic, TypeConstraint operandTy>
27052705
let results = (outs operandTy:$result);
27062706

27072707
let assemblyFormat = [{
2708-
`(` $input `:` type($input) `)` `:` type($result) attr-dict
2708+
$input `:` type($result) attr-dict
27092709
}];
27102710
}
27112711

@@ -2714,20 +2714,20 @@ class CIR_BitZeroCountOpBase<string mnemonic, TypeConstraint operandTy>
27142714
let arguments = (ins operandTy:$input, UnitAttr:$poison_zero);
27152715

27162716
let assemblyFormat = [{
2717-
`(` $input `:` type($input) `)` (`poison_zero` $poison_zero^)?
2717+
$input (`poison_zero` $poison_zero^)?
27182718
`:` type($result) attr-dict
27192719
}];
27202720
}
27212721

2722-
def BitClrsbOp : CIR_BitOpBase<"bit.clrsb", CIR_SIntOfWidths<[32, 64]>> {
2722+
def BitClrsbOp : CIR_BitOpBase<"clrsb", CIR_SIntOfWidths<[32, 64]>> {
27232723
let summary = "Get the number of leading redundant sign bits in the input";
27242724
let description = [{
27252725
Compute the number of leading redundant sign bits in the input integer.
27262726

27272727
The input integer must be a signed integer. The most significant bit of the
2728-
input integer is the sign bit. The `cir.bit.clrsb` operation returns the
2729-
number of consecutive bits following the sign bit that are identical to the
2730-
sign bit.
2728+
input integer is the sign bit. The `cir.clrsb` operation returns the number
2729+
of consecutive bits following the sign bit that are identical to the sign
2730+
bit.
27312731

27322732
The bit width of the input integer must be either 32 or 64.
27332733

@@ -2738,24 +2738,23 @@ def BitClrsbOp : CIR_BitOpBase<"bit.clrsb", CIR_SIntOfWidths<[32, 64]>> {
27382738
%0 = cir.const #cir.int<3735928559> : !s32i
27392739
// %1 will be 1 because there is 1 bit following the most significant bit
27402740
// that is identical to it.
2741-
%1 = cir.bit.clrsb(%0 : !s32i) : !s32i
2741+
%1 = cir.clrsb %0 : !s32i
27422742

27432743
// %2 = 1, 0b0000_0000_0000_0000_0000_0000_0000_0001
27442744
%2 = cir.const #cir.int<1> : !s32i
27452745
// %3 will be 30 because there are 30 consecutive bits following the sign
27462746
// bit that are identical to the sign bit.
2747-
%3 = cir.bit.clrsb(%2 : !s32i) : !s32i
2747+
%3 = cir.clrsb %2 : !s32i
27482748
```
27492749
}];
27502750
}
27512751

2752-
def BitClzOp : CIR_BitZeroCountOpBase<"bit.clz",
2753-
CIR_UIntOfWidths<[16, 32, 64]>> {
2752+
def BitClzOp : CIR_BitZeroCountOpBase<"clz", CIR_UIntOfWidths<[16, 32, 64]>> {
27542753
let summary = "Get the number of leading 0-bits in the input";
27552754
let description = [{
27562755
Compute the number of leading 0-bits in the input.
27572756

2758-
The input integer must be an unsigned integer. The `cir.bit.clz` operation
2757+
The input integer must be an unsigned integer. The `cir.clz` operation
27592758
returns the number of consecutive 0-bits at the most significant bit
27602759
position in the input.
27612760

@@ -2768,18 +2767,17 @@ def BitClzOp : CIR_BitZeroCountOpBase<"bit.clz",
27682767
// %0 = 0b0000_0000_0000_0000_0000_0000_0000_1000
27692768
%0 = cir.const #cir.int<8> : !u32i
27702769
// %1 will be 28
2771-
%1 = cir.bit.clz(%0 : !u32i) poison_zero : !u32i
2770+
%1 = cir.clz %0 poison_zero : !u32i
27722771
```
27732772
}];
27742773
}
27752774

2776-
def BitCtzOp : CIR_BitZeroCountOpBase<"bit.ctz",
2777-
CIR_UIntOfWidths<[16, 32, 64]>> {
2775+
def BitCtzOp : CIR_BitZeroCountOpBase<"ctz", CIR_UIntOfWidths<[16, 32, 64]>> {
27782776
let summary = "Get the number of trailing 0-bits in the input";
27792777
let description = [{
27802778
Compute the number of trailing 0-bits in the input.
27812779

2782-
The input integer must be an unsigned integer. The `cir.bit.ctz` operation
2780+
The input integer must be an unsigned integer. The `cir.ctz` operation
27832781
counts the number of consecutive 0-bits starting from the least significant
27842782
bit.
27852783

@@ -2792,12 +2790,12 @@ def BitCtzOp : CIR_BitZeroCountOpBase<"bit.ctz",
27922790
// %0 = 0b1000
27932791
%0 = cir.const #cir.int<8> : !u32i
27942792
// %1 will be 3
2795-
%1 = cir.bit.ctz(%0 : !u32i) poison_zero : !u32i
2793+
%1 = cir.ctz %0 poison_zero : !u32i
27962794
```
27972795
}];
27982796
}
27992797

2800-
def BitParityOp : CIR_BitOpBase<"bit.parity", CIR_UIntOfWidths<[32, 64]>> {
2798+
def BitParityOp : CIR_BitOpBase<"parity", CIR_UIntOfWidths<[32, 64]>> {
28012799
let summary = "Get the parity of input";
28022800
let description = [{
28032801
Compute the parity of the input. The parity of an integer is the number of
@@ -2811,13 +2809,12 @@ def BitParityOp : CIR_BitOpBase<"bit.parity", CIR_UIntOfWidths<[32, 64]>> {
28112809
// %0 = 0x0110_1000
28122810
%0 = cir.const #cir.int<104> : !u32i
28132811
// %1 will be 1 since there are three 1-bits in %0
2814-
%1 = cir.bit.parity(%0 : !u32i) : !u32i
2812+
%1 = cir.parity %0 : !u32i
28152813
```
28162814
}];
28172815
}
28182816

2819-
def BitPopcountOp : CIR_BitOpBase<"bit.popcnt",
2820-
CIR_UIntOfWidths<[16, 32, 64]>> {
2817+
def BitPopcountOp : CIR_BitOpBase<"popcount", CIR_UIntOfWidths<[16, 32, 64]>> {
28212818
let summary = "Get the number of 1-bits in input";
28222819
let description = [{
28232820
Compute the number of 1-bits in the input.
@@ -2830,25 +2827,22 @@ def BitPopcountOp : CIR_BitOpBase<"bit.popcnt",
28302827
// %0 = 0x0110_1000
28312828
%0 = cir.const #cir.int<104> : !u32i
28322829
// %1 will be 3 since there are 3 1-bits in %0
2833-
%1 = cir.bit.popcnt(%0 : !u32i) : !u32i
2830+
%1 = cir.popcount %0 : !u32i
28342831
```
28352832
}];
28362833
}
28372834

2838-
def BitReverseOp : CIR_BitOpBase<"bit.reverse",
2835+
def BitReverseOp : CIR_BitOpBase<"bitreverse",
28392836
CIR_UIntOfWidths<[8, 16, 32, 64]>> {
28402837
let summary = "Reverse the bit pattern of the operand integer";
28412838
let description = [{
2842-
The `cir.bit.reverse` operation reverses the bits of the operand integer.
2843-
Its only argument must be of unsigned integer types of width 8, 16, 32, or
2844-
64.
2845-
2846-
This operation covers the C/C++ builtin function `__builtin_bitreverse`.
2839+
The `cir.bitreverse` operation reverses the bits of the operand integer. Its
2840+
only argument must be of unsigned integer types of width 8, 16, 32, or 64.
28472841

28482842
Example:
28492843

28502844
```mlir
2851-
%1 = cir.bit.reverse(%0 : !u32i): !u32i
2845+
%1 = cir.bitreverse %0: !u32i
28522846
```
28532847
}];
28542848
}
@@ -2869,7 +2863,7 @@ def ByteSwapOp : CIR_BitOpBase<"byte_swap", CIR_UIntOfWidths<[16, 32, 64]>> {
28692863
%0 = cir.const #cir.int<305419896> : !u32i
28702864

28712865
// %1 should be 0x78563412
2872-
%1 = cir.byte_swap(%0 : !u32i) : !u32i
2866+
%1 = cir.byte_swap %0 : !u32i
28732867
```
28742868
}];
28752869
}

clang/test/CIR/CodeGen/builtin_bit.cpp

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ int test_builtin_clrsb(int x) {
1010
}
1111

1212
// CIR-LABEL: _Z18test_builtin_clrsbi
13-
// CIR: [[TMP:%.+]] = cir.bit.clrsb(%{{.+}} : !s32i) : !s32i
13+
// CIR: [[TMP:%.+]] = cir.clrsb %{{.+}} : !s32i
1414

1515
// LLVM-LABEL: _Z18test_builtin_clrsbi
1616
// LLVM: %[[X:.+]] = load i32, ptr %{{.+}}, align 4
@@ -33,7 +33,7 @@ int test_builtin_clrsbl(long x) {
3333
}
3434

3535
// CIR-LABEL: _Z19test_builtin_clrsbll
36-
// CIR: [[TMP:%.+]] = cir.bit.clrsb(%{{.+}} : !s64i) : !s64i
36+
// CIR: [[TMP:%.+]] = cir.clrsb %{{.+}} : !s64i
3737
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !s64i), !s32i
3838

3939
// LLVM-LABEL: _Z19test_builtin_clrsbll
@@ -57,7 +57,7 @@ int test_builtin_clrsbll(long long x) {
5757
}
5858

5959
// CIR-LABEL: _Z20test_builtin_clrsbllx
60-
// CIR: [[TMP:%.+]] = cir.bit.clrsb(%{{.+}} : !s64i) : !s64i
60+
// CIR: [[TMP:%.+]] = cir.clrsb %{{.+}} : !s64i
6161
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !s64i), !s32i
6262

6363
// LLVM-LABEL: _Z20test_builtin_clrsbllx
@@ -81,7 +81,7 @@ int test_builtin_ctzs(unsigned short x) {
8181
}
8282

8383
// CIR-LABEL: _Z17test_builtin_ctzst
84-
// CIR: [[TMP:%.+]] = cir.bit.ctz(%{{.+}} : !u16i) poison_zero : !u16i
84+
// CIR: [[TMP:%.+]] = cir.ctz %{{.+}} poison_zero : !u16i
8585
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u16i), !s32i
8686

8787
// LLVM-LABEL: _Z17test_builtin_ctzst
@@ -95,7 +95,7 @@ int test_builtin_ctz(unsigned x) {
9595
}
9696

9797
// CIR-LABEL: _Z16test_builtin_ctzj
98-
// CIR: [[TMP:%.+]] = cir.bit.ctz(%{{.+}} : !u32i) poison_zero : !u32i
98+
// CIR: [[TMP:%.+]] = cir.ctz %{{.+}} poison_zero : !u32i
9999
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u32i), !s32i
100100

101101
// LLVM-LABEL: _Z16test_builtin_ctzj
@@ -109,7 +109,7 @@ int test_builtin_ctzl(unsigned long x) {
109109
}
110110

111111
// CIR-LABEL: _Z17test_builtin_ctzlm
112-
// CIR: [[TMP:%.+]] = cir.bit.ctz(%{{.+}} : !u64i) poison_zero : !u64i
112+
// CIR: [[TMP:%.+]] = cir.ctz %{{.+}} poison_zero : !u64i
113113
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
114114

115115
// LLVM-LABEL: _Z17test_builtin_ctzlm
@@ -123,7 +123,7 @@ int test_builtin_ctzll(unsigned long long x) {
123123
}
124124

125125
// CIR-LABEL: _Z18test_builtin_ctzlly
126-
// CIR: [[TMP:%.+]] = cir.bit.ctz(%{{.+}} : !u64i) poison_zero : !u64i
126+
// CIR: [[TMP:%.+]] = cir.ctz %{{.+}} poison_zero : !u64i
127127
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
128128

129129
// LLVM-LABEL: _Z18test_builtin_ctzlly
@@ -137,7 +137,7 @@ int test_builtin_ctzg(unsigned x) {
137137
}
138138

139139
// CIR-LABEL: _Z17test_builtin_ctzgj
140-
// CIR: [[TMP:%.+]] = cir.bit.ctz(%{{.+}} : !u32i) poison_zero : !u32i
140+
// CIR: [[TMP:%.+]] = cir.ctz %{{.+}} poison_zero : !u32i
141141
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u32i), !s32i
142142

143143
// LLVM-LABEL: _Z17test_builtin_ctzgj
@@ -151,7 +151,7 @@ int test_builtin_clzs(unsigned short x) {
151151
}
152152

153153
// CIR-LABEL: _Z17test_builtin_clzst
154-
// CIR: [[TMP:%.+]] = cir.bit.clz(%{{.+}} : !u16i) poison_zero : !u16i
154+
// CIR: [[TMP:%.+]] = cir.clz %{{.+}} poison_zero : !u16i
155155
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u16i), !s32i
156156

157157
// LLVM-LABEL: _Z17test_builtin_clzst
@@ -165,7 +165,7 @@ int test_builtin_clz(unsigned x) {
165165
}
166166

167167
// CIR-LABEL: _Z16test_builtin_clzj
168-
// CIR: [[TMP:%.+]] = cir.bit.clz(%{{.+}} : !u32i) poison_zero : !u32i
168+
// CIR: [[TMP:%.+]] = cir.clz %{{.+}} poison_zero : !u32i
169169
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u32i), !s32i
170170

171171
// LLVM-LABEL: _Z16test_builtin_clzj
@@ -179,7 +179,7 @@ int test_builtin_clzl(unsigned long x) {
179179
}
180180

181181
// CIR-LABEL: _Z17test_builtin_clzlm
182-
// CIR: [[TMP:%.+]] = cir.bit.clz(%{{.+}} : !u64i) poison_zero : !u64i
182+
// CIR: [[TMP:%.+]] = cir.clz %{{.+}} poison_zero : !u64i
183183
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
184184

185185
// LLVM-LABEL: _Z17test_builtin_clzlm
@@ -193,7 +193,7 @@ int test_builtin_clzll(unsigned long long x) {
193193
}
194194

195195
// CIR-LABEL: _Z18test_builtin_clzlly
196-
// CIR: [[TMP:%.+]] = cir.bit.clz(%{{.+}} : !u64i) poison_zero : !u64i
196+
// CIR: [[TMP:%.+]] = cir.clz %{{.+}} poison_zero : !u64i
197197
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
198198

199199
// LLVM-LABEL: _Z18test_builtin_clzlly
@@ -207,7 +207,7 @@ int test_builtin_clzg(unsigned x) {
207207
}
208208

209209
// CIR-LABEL: _Z17test_builtin_clzgj
210-
// CIR: [[TMP:%.+]] = cir.bit.clz(%{{.+}} : !u32i) poison_zero : !u32i
210+
// CIR: [[TMP:%.+]] = cir.clz %{{.+}} poison_zero : !u32i
211211
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u32i), !s32i
212212

213213
// LLVM-LABEL: _Z17test_builtin_clzgj
@@ -221,7 +221,7 @@ int test_builtin_parity(unsigned x) {
221221
}
222222

223223
// CIR-LABEL: _Z19test_builtin_parityj
224-
// CIR: [[TMP:%.+]] = cir.bit.parity(%{{.+}} : !u32i) : !u32i
224+
// CIR: [[TMP:%.+]] = cir.parity %{{.+}} : !u32i
225225
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u32i), !s32i
226226

227227
// LLVM-LABEL: _Z19test_builtin_parityj
@@ -239,7 +239,7 @@ int test_builtin_parityl(unsigned long x) {
239239
}
240240

241241
// CIR-LABEL: _Z20test_builtin_paritylm
242-
// CIR: [[TMP:%.+]] = cir.bit.parity(%{{.+}} : !u64i) : !u64i
242+
// CIR: [[TMP:%.+]] = cir.parity %{{.+}} : !u64i
243243
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
244244

245245
// LLVM-LABEL: _Z20test_builtin_paritylm
@@ -257,7 +257,7 @@ int test_builtin_parityll(unsigned long long x) {
257257
}
258258

259259
// CIR-LABEL: _Z21test_builtin_paritylly
260-
// CIR: [[TMP:%.+]] = cir.bit.parity(%{{.+}} : !u64i) : !u64i
260+
// CIR: [[TMP:%.+]] = cir.parity %{{.+}} : !u64i
261261
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
262262

263263
// LLVM-LABEL: _Z21test_builtin_paritylly
@@ -275,7 +275,7 @@ int test_builtin_popcount(unsigned x) {
275275
}
276276

277277
// CIR-LABEL: _Z21test_builtin_popcountj
278-
// CIR: [[TMP:%.+]] = cir.bit.popcnt(%{{.+}} : !u32i) : !u32i
278+
// CIR: [[TMP:%.+]] = cir.popcount %{{.+}} : !u32i
279279
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u32i), !s32i
280280

281281
// LLVM-LABEL: _Z21test_builtin_popcountj
@@ -289,7 +289,7 @@ int test_builtin_popcountl(unsigned long x) {
289289
}
290290

291291
// CIR-LABEL: _Z22test_builtin_popcountlm
292-
// CIR: [[TMP:%.+]] = cir.bit.popcnt(%{{.+}} : !u64i) : !u64i
292+
// CIR: [[TMP:%.+]] = cir.popcount %{{.+}} : !u64i
293293
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
294294

295295
// LLVM-LABEL: _Z22test_builtin_popcountlm
@@ -303,7 +303,7 @@ int test_builtin_popcountll(unsigned long long x) {
303303
}
304304

305305
// CIR-LABEL: _Z23test_builtin_popcountlly
306-
// CIR: [[TMP:%.+]] = cir.bit.popcnt(%{{.+}} : !u64i) : !u64i
306+
// CIR: [[TMP:%.+]] = cir.popcount %{{.+}} : !u64i
307307
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u64i), !s32i
308308

309309
// LLVM-LABEL: _Z23test_builtin_popcountlly
@@ -317,7 +317,7 @@ int test_builtin_popcountg(unsigned x) {
317317
}
318318

319319
// CIR-LABEL: _Z22test_builtin_popcountgj
320-
// CIR: [[TMP:%.+]] = cir.bit.popcnt(%{{.+}} : !u32i) : !u32i
320+
// CIR: [[TMP:%.+]] = cir.popcount %{{.+}} : !u32i
321321
// CIR: {{%.+}} = cir.cast(integral, [[TMP]] : !u32i), !s32i
322322

323323
// LLVM-LABEL: _Z22test_builtin_popcountgj
@@ -331,7 +331,7 @@ unsigned char test_builtin_bitreverse8(unsigned char x) {
331331
}
332332

333333
// CIR-LABEL: @_Z24test_builtin_bitreverse8h
334-
// CIR: %{{.+}} = cir.bit.reverse(%{{.+}} : !u8i) : !u8i
334+
// CIR: %{{.+}} = cir.bitreverse %{{.+}} : !u8i
335335

336336
// LLVM-LABEL: @_Z24test_builtin_bitreverse8h
337337
// LLVM: %{{.+}} = call i8 @llvm.bitreverse.i8(i8 %{{.+}})
@@ -344,7 +344,7 @@ unsigned short test_builtin_bitreverse16(unsigned short x) {
344344
}
345345

346346
// CIR-LABEL: @_Z25test_builtin_bitreverse16t
347-
// CIR: %{{.+}} = cir.bit.reverse(%{{.+}} : !u16i) : !u16i
347+
// CIR: %{{.+}} = cir.bitreverse %{{.+}} : !u16i
348348

349349
// LLVM-LABEL: @_Z25test_builtin_bitreverse16t
350350
// LLVM: %{{.+}} = call i16 @llvm.bitreverse.i16(i16 %{{.+}})
@@ -357,7 +357,7 @@ unsigned test_builtin_bitreverse32(unsigned x) {
357357
}
358358

359359
// CIR-LABEL: @_Z25test_builtin_bitreverse32j
360-
// CIR: %{{.+}} = cir.bit.reverse(%{{.+}} : !u32i) : !u32i
360+
// CIR: %{{.+}} = cir.bitreverse %{{.+}} : !u32i
361361

362362
// LLVM-LABEL: @_Z25test_builtin_bitreverse32j
363363
// LLVM: %{{.+}} = call i32 @llvm.bitreverse.i32(i32 %{{.+}})
@@ -370,7 +370,7 @@ unsigned long long test_builtin_bitreverse64(unsigned long long x) {
370370
}
371371

372372
// CIR-LABEL: @_Z25test_builtin_bitreverse64y
373-
// CIR: %{{.+}} = cir.bit.reverse(%{{.+}} : !u64i) : !u64i
373+
// CIR: %{{.+}} = cir.bitreverse %{{.+}} : !u64i
374374

375375
// LLVM-LABEL: @_Z25test_builtin_bitreverse64y
376376
// LLVM: %{{.+}} = call i64 @llvm.bitreverse.i64(i64 %{{.+}})
@@ -383,7 +383,7 @@ unsigned short test_builtin_bswap16(unsigned short x) {
383383
}
384384

385385
// CIR-LABEL: @_Z20test_builtin_bswap16t
386-
// CIR: %{{.+}} = cir.byte_swap(%{{.+}} : !u16i) : !u16i
386+
// CIR: %{{.+}} = cir.byte_swap %{{.+}} : !u16i
387387

388388
// LLVM-LABEL: @_Z20test_builtin_bswap16t
389389
// LLVM: %{{.+}} = call i16 @llvm.bswap.i16(i16 %{{.+}})
@@ -396,7 +396,7 @@ unsigned test_builtin_bswap32(unsigned x) {
396396
}
397397

398398
// CIR-LABEL: @_Z20test_builtin_bswap32j
399-
// CIR: %{{.+}} = cir.byte_swap(%{{.+}} : !u32i) : !u32i
399+
// CIR: %{{.+}} = cir.byte_swap %{{.+}} : !u32i
400400

401401
// LLVM-LABEL: @_Z20test_builtin_bswap32j
402402
// LLVM: %{{.+}} = call i32 @llvm.bswap.i32(i32 %{{.+}})
@@ -409,7 +409,7 @@ unsigned long long test_builtin_bswap64(unsigned long long x) {
409409
}
410410

411411
// CIR-LABEL: @_Z20test_builtin_bswap64y
412-
// CIR: %{{.+}} = cir.byte_swap(%{{.+}} : !u64i) : !u64i
412+
// CIR: %{{.+}} = cir.byte_swap %{{.+}} : !u64i
413413

414414
// LLVM-LABEL: @_Z20test_builtin_bswap64y
415415
// LLVM: %{{.+}} = call i64 @llvm.bswap.i64(i64 %{{.+}})

0 commit comments

Comments
 (0)