mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-27 15:41:46 +00:00
Revert "[mlir][spirv] Add lowering for std.fpext, std.fptrunc, std.sitofp."
This reverts commit 7e7f849a6d
because
it recorded the wrong commit author.
This commit is contained in:
parent
22700f68e1
commit
dab2921f77
@ -20,10 +20,6 @@ class BinaryOpPattern<Type type, Op src, Op tgt> :
|
||||
Pat<(src SPV_ScalarOrVectorOf<type>:$l, SPV_ScalarOrVectorOf<type>:$r),
|
||||
(tgt $l, $r)>;
|
||||
|
||||
class UnaryOpPattern<Type type, Op src, Op tgt> :
|
||||
Pat<(src type:$input),
|
||||
(tgt $input)>;
|
||||
|
||||
def : BinaryOpPattern<SPV_Bool, AndOp, SPV_LogicalAndOp>;
|
||||
def : BinaryOpPattern<SPV_Bool, OrOp, SPV_LogicalOrOp>;
|
||||
def : BinaryOpPattern<SPV_Integer, AndOp, SPV_BitwiseAndOp>;
|
||||
@ -40,10 +36,6 @@ def : BinaryOpPattern<SPV_Float, MulFOp, SPV_FMulOp>;
|
||||
def : BinaryOpPattern<SPV_Float, RemFOp, SPV_FRemOp>;
|
||||
def : BinaryOpPattern<SPV_Float, SubFOp, SPV_FSubOp>;
|
||||
|
||||
def : UnaryOpPattern<SPV_Integer, SIToFPOp, SPV_ConvertSToFOp>;
|
||||
def : UnaryOpPattern<SPV_Float, FPExtOp, SPV_FConvertOp>;
|
||||
def : UnaryOpPattern<SPV_Float, FPTruncOp, SPV_FConvertOp>;
|
||||
|
||||
// Constant Op
|
||||
// TODO(ravishankarm): Handle lowering other constant types.
|
||||
def : Pat<(ConstantOp:$result $valueAttr),
|
||||
|
@ -245,28 +245,6 @@ func @logical_vector(%arg0 : vector<4xi1>, %arg1 : vector<4xi1>) {
|
||||
return
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// std.fpext
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// CHECK-LABEL: @fpext
|
||||
func @fpext(%arg0 : f32) {
|
||||
// CHECK: spv.FConvert
|
||||
%0 = std.fpext %arg0 : f32 to f64
|
||||
return
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// std.fptrunc
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// CHECK-LABEL: @fptrunc
|
||||
func @fptrunc(%arg0 : f64) {
|
||||
// CHECK: spv.FConvert
|
||||
%0 = std.fptrunc %arg0 : f64 to f32
|
||||
return
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// std.select
|
||||
//===----------------------------------------------------------------------===//
|
||||
@ -278,14 +256,3 @@ func @select(%arg0 : i32, %arg1 : i32) {
|
||||
%1 = select %0, %arg0, %arg1 : i32
|
||||
return
|
||||
}
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// std.sitofp
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
// CHECK-LABEL: @sitofp
|
||||
func @sitofp(%arg0 : i32) {
|
||||
// CHECK: spv.ConvertSToF
|
||||
%0 = std.sitofp %arg0 : i32 to f32
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user