@@ -1110,7 +1110,7 @@ def SaturationModeAttr : EnumAttr<NVVM_Dialect, SaturationMode, "sat_mode"> {
1110
1110
let assemblyFormat = "`<` $value `>`";
1111
1111
}
1112
1112
1113
- def NVVM_CvtFloatToTF32Op : NVVM_Op<"cvt .float.to.tf32"> {
1113
+ def NVVM_ConvertFloatToTF32Op : NVVM_Op<"convert .float.to.tf32"> {
1114
1114
let summary = "Convert the given float input to TF32";
1115
1115
let description = [{
1116
1116
This Op converts the given f32 input to tf32.
@@ -1139,24 +1139,24 @@ def NVVM_CvtFloatToTF32Op : NVVM_Op<"cvt.float.to.tf32"> {
1139
1139
}];
1140
1140
1141
1141
string llvmBuilder = [{
1142
- auto intId = NVVM::CvtFloatToTF32Op ::getIntrinsicID($rnd, $sat, $relu);
1142
+ auto intId = NVVM::ConvertFloatToTF32Op ::getIntrinsicID($rnd, $sat, $relu);
1143
1143
$res = createIntrinsicCall(builder, intId, {$src});
1144
1144
}];
1145
1145
}
1146
1146
1147
- def CVTFP6E2M3 : I32EnumAttrCase<"E2M3", 0, "e2m3">;
1148
- def CVTFP6E3M2 : I32EnumAttrCase<"E3M2", 1, "e3m2">;
1147
+ def ConvertFP6E2M3 : I32EnumAttrCase<"E2M3", 0, "e2m3">;
1148
+ def ConvertFP6E3M2 : I32EnumAttrCase<"E3M2", 1, "e3m2">;
1149
1149
1150
- def CVTFP6Type : I32EnumAttr<"CVTFP6Type ", "NVVM CVTFP6Type kind",
1151
- [CVTFP6E2M3, CVTFP6E3M2 ]> {
1150
+ def ConvertFP6Type : I32EnumAttr<"ConvertFP6Type ", "NVVM ConvertFP6Type kind",
1151
+ [ConvertFP6E2M3, ConvertFP6E3M2 ]> {
1152
1152
let genSpecializedAttr = 0;
1153
1153
let cppNamespace = "::mlir::NVVM";
1154
1154
}
1155
- def CVTFP6TypeAttr : EnumAttr<NVVM_Dialect, CVTFP6Type , "cvt_fp6_type "> {
1155
+ def ConvertFP6TypeAttr : EnumAttr<NVVM_Dialect, ConvertFP6Type , "convert_fp6_type "> {
1156
1156
let assemblyFormat = "`<` $value `>`";
1157
1157
}
1158
1158
1159
- def NVVM_CvtF32x2ToF6x2Op : NVVM_Op<"cvt .f32x2.to.f6x2"> {
1159
+ def NVVM_ConvertF32x2ToF6x2Op : NVVM_Op<"convert .f32x2.to.f6x2"> {
1160
1160
let summary = "Convert a pair of float inputs to f6x2";
1161
1161
let description = [{
1162
1162
This Op converts each of the given float inputs to the specified fp6 type.
@@ -1176,19 +1176,19 @@ def NVVM_CvtF32x2ToF6x2Op : NVVM_Op<"cvt.f32x2.to.f6x2"> {
1176
1176
1177
1177
let results = (outs AnyTypeOf<[I16, VectorOfLengthAndType<[2], [I8]>]>:$dst);
1178
1178
let arguments = (ins
1179
- CVTFP6TypeAttr :$type,
1179
+ ConvertFP6TypeAttr :$type,
1180
1180
F32:$a,
1181
1181
F32:$b,
1182
1182
DefaultValuedAttr<BoolAttr, "false">:$relu);
1183
1183
let assemblyFormat = "$type $a `,` $b attr-dict `:` type($dst)";
1184
1184
1185
1185
let extraClassDeclaration = [{
1186
- static llvm::Intrinsic::ID getIntrinsicID(NVVM::CVTFP6Type ,
1186
+ static llvm::Intrinsic::ID getIntrinsicID(NVVM::ConvertFP6Type ,
1187
1187
bool hasRelu);
1188
1188
}];
1189
1189
1190
1190
string llvmBuilder = [{
1191
- auto intId = NVVM::CvtF32x2ToF6x2Op ::getIntrinsicID($type, $relu);
1191
+ auto intId = NVVM::ConvertF32x2ToF6x2Op ::getIntrinsicID($type, $relu);
1192
1192
llvm::Value *packedI16 = createIntrinsicCall(builder, intId, {$a, $b});
1193
1193
if(op.getDst().getType().isInteger(16))
1194
1194
$dst = packedI16;
@@ -1198,20 +1198,20 @@ def NVVM_CvtF32x2ToF6x2Op : NVVM_Op<"cvt.f32x2.to.f6x2"> {
1198
1198
}];
1199
1199
}
1200
1200
1201
- def CVTFP8E4M3 : I32EnumAttrCase<"E4M3", 0, "e4m3">;
1202
- def CVTFP8E5M2 : I32EnumAttrCase<"E5M2", 1, "e5m2">;
1203
- def CVTFP8UE8M0 : I32EnumAttrCase<"UE8M0", 2, "ue8m0">;
1201
+ def ConvertFP8E4M3 : I32EnumAttrCase<"E4M3", 0, "e4m3">;
1202
+ def ConvertFP8E5M2 : I32EnumAttrCase<"E5M2", 1, "e5m2">;
1203
+ def ConvertFP8UE8M0 : I32EnumAttrCase<"UE8M0", 2, "ue8m0">;
1204
1204
1205
- def CVTFP8Type : I32EnumAttr<"CVTFP8Type ", "NVVM CVTFP8Type kind",
1206
- [CVTFP8E4M3, CVTFP8E5M2, CVTFP8UE8M0 ]> {
1205
+ def ConvertFP8Type : I32EnumAttr<"ConvertFP8Type ", "NVVM ConvertFP8Type kind",
1206
+ [ConvertFP8E4M3, ConvertFP8E5M2, ConvertFP8UE8M0 ]> {
1207
1207
let genSpecializedAttr = 0;
1208
1208
let cppNamespace = "::mlir::NVVM";
1209
1209
}
1210
- def CVTFP8TypeAttr : EnumAttr<NVVM_Dialect, CVTFP8Type , "cvt_fp8_type "> {
1210
+ def ConvertFP8TypeAttr : EnumAttr<NVVM_Dialect, ConvertFP8Type , "convert_fp8_type "> {
1211
1211
let assemblyFormat = "`<` $value `>`";
1212
1212
}
1213
1213
1214
- def NVVM_CvtF32x2ToF8x2Op : NVVM_Op<"cvt .f32x2.to.f8x2"> {
1214
+ def NVVM_ConvertF32x2ToF8x2Op : NVVM_Op<"convert .f32x2.to.f8x2"> {
1215
1215
let summary = "Convert a pair of float inputs to f8x2";
1216
1216
let description = [{
1217
1217
This Op converts each of the given float inputs to the specified fp8 type.
@@ -1232,7 +1232,7 @@ def NVVM_CvtF32x2ToF8x2Op : NVVM_Op<"cvt.f32x2.to.f8x2"> {
1232
1232
let hasVerifier = 1;
1233
1233
let results = (outs AnyTypeOf<[I16, VectorOfLengthAndType<[2], [I8]>]>:$dst);
1234
1234
let arguments = (ins
1235
- CVTFP8TypeAttr :$type,
1235
+ ConvertFP8TypeAttr :$type,
1236
1236
F32:$a,
1237
1237
F32:$b,
1238
1238
DefaultValuedAttr<FPRoundingModeAttr, "FPRoundingMode::NONE">:$rnd,
@@ -1241,14 +1241,14 @@ def NVVM_CvtF32x2ToF8x2Op : NVVM_Op<"cvt.f32x2.to.f8x2"> {
1241
1241
let assemblyFormat = "$type $a `,` $b attr-dict `:` type($dst)";
1242
1242
1243
1243
let extraClassDeclaration = [{
1244
- static llvm::Intrinsic::ID getIntrinsicID(NVVM::CVTFP8Type to,
1244
+ static llvm::Intrinsic::ID getIntrinsicID(NVVM::ConvertFP8Type to,
1245
1245
NVVM::FPRoundingMode rnd,
1246
1246
NVVM::SaturationMode sat,
1247
1247
bool hasRelu);
1248
1248
}];
1249
1249
1250
1250
string llvmBuilder = [{
1251
- auto intId = NVVM::CvtF32x2ToF8x2Op ::getIntrinsicID($type, $rnd, $sat, $relu);
1251
+ auto intId = NVVM::ConvertF32x2ToF8x2Op ::getIntrinsicID($type, $rnd, $sat, $relu);
1252
1252
llvm::Value *packedI16 = createIntrinsicCall(builder, intId, {$a, $b});
1253
1253
if(op.getDst().getType().isInteger(16))
1254
1254
$dst = packedI16;
@@ -1258,7 +1258,7 @@ def NVVM_CvtF32x2ToF8x2Op : NVVM_Op<"cvt.f32x2.to.f8x2"> {
1258
1258
}];
1259
1259
}
1260
1260
1261
- def NVVM_CvtF16x2ToF8x2Op : NVVM_Op<"cvt .f16x2.to.f8x2"> {
1261
+ def NVVM_ConvertF16x2ToF8x2Op : NVVM_Op<"convert .f16x2.to.f8x2"> {
1262
1262
let summary = "Convert an f16x2 input to f8x2";
1263
1263
let description = [{
1264
1264
This Op converts the given f16 inputs in an f16x2 vector to the specified
@@ -1280,18 +1280,18 @@ def NVVM_CvtF16x2ToF8x2Op : NVVM_Op<"cvt.f16x2.to.f8x2"> {
1280
1280
let hasVerifier = 1;
1281
1281
let results = (outs AnyTypeOf<[I16, VectorOfLengthAndType<[2], [I8]>]>:$dst);
1282
1282
let arguments = (ins
1283
- CVTFP8TypeAttr :$type,
1283
+ ConvertFP8TypeAttr :$type,
1284
1284
VectorOfLengthAndType<[2], [F16]>:$a,
1285
1285
DefaultValuedAttr<BoolAttr, "false">:$relu);
1286
1286
let assemblyFormat = "$type $a attr-dict `:` type($a) `->` type($dst)";
1287
1287
1288
1288
let extraClassDeclaration = [{
1289
- static llvm::Intrinsic::ID getIntrinsicID(NVVM::CVTFP8Type to,
1289
+ static llvm::Intrinsic::ID getIntrinsicID(NVVM::ConvertFP8Type to,
1290
1290
bool hasRelu);
1291
1291
}];
1292
1292
1293
1293
string llvmBuilder = [{
1294
- auto intId = NVVM::CvtF16x2ToF8x2Op ::getIntrinsicID($type, $relu);
1294
+ auto intId = NVVM::ConvertF16x2ToF8x2Op ::getIntrinsicID($type, $relu);
1295
1295
llvm::Value *packedI16 = createIntrinsicCall(builder, intId, {$a});
1296
1296
if(op.getDst().getType().isInteger(16))
1297
1297
$dst = packedI16;
@@ -1301,7 +1301,7 @@ def NVVM_CvtF16x2ToF8x2Op : NVVM_Op<"cvt.f16x2.to.f8x2"> {
1301
1301
}];
1302
1302
}
1303
1303
1304
- def NVVM_CvtBF16x2ToF8x2Op : NVVM_Op<"cvt .bf16x2.to.f8x2"> {
1304
+ def NVVM_ConvertBF16x2ToF8x2Op : NVVM_Op<"convert .bf16x2.to.f8x2"> {
1305
1305
let summary = "Convert a pair of bf16 inputs to f8x2";
1306
1306
let description = [{
1307
1307
This Op converts the given bf16 inputs in a bf16x2 vector to the specified
@@ -1323,7 +1323,7 @@ def NVVM_CvtBF16x2ToF8x2Op : NVVM_Op<"cvt.bf16x2.to.f8x2"> {
1323
1323
let hasVerifier = 1;
1324
1324
let results = (outs AnyTypeOf<[I16, VectorOfLengthAndType<[2], [I8]>]>:$dst);
1325
1325
let arguments = (ins
1326
- CVTFP8TypeAttr :$type,
1326
+ ConvertFP8TypeAttr :$type,
1327
1327
VectorOfLengthAndType<[2], [BF16]>:$a,
1328
1328
DefaultValuedAttr<FPRoundingModeAttr, "FPRoundingMode::NONE">:$rnd,
1329
1329
DefaultValuedAttr<SaturationModeAttr, "SaturationMode::NONE">:$sat);
@@ -1335,7 +1335,7 @@ def NVVM_CvtBF16x2ToF8x2Op : NVVM_Op<"cvt.bf16x2.to.f8x2"> {
1335
1335
}];
1336
1336
1337
1337
string llvmBuilder = [{
1338
- auto intId = NVVM::CvtBF16x2ToF8x2Op ::getIntrinsicID($rnd, $sat);
1338
+ auto intId = NVVM::ConvertBF16x2ToF8x2Op ::getIntrinsicID($rnd, $sat);
1339
1339
llvm::Value *packedI16 = createIntrinsicCall(builder, intId, {$a});
1340
1340
if(op.getDst().getType().isInteger(16))
1341
1341
$dst = packedI16;
0 commit comments