-
Notifications
You must be signed in to change notification settings - Fork 194
[LLVM] Update LLVM version to 21.0.0git #472
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: v-snake
Are you sure you want to change the base?
Conversation
Running standalone build for llvm doesn't install MLIRPythonCAPI library into build/tool/mlir, please make this link path configurable: |
Also worth notice that, buddy-llc breaks after bump: $ buddy-llc forward-lowered.mlir.ll -mtriple=riscv32 -target-abi=ilp32f -mattr=+m,+f,+zve32f --filetype=obj -o forward-lowered.mlir.ll.o
#5 0x0000555556f05896 getFeatures(llvm::MCSubtargetInfo&, llvm::StringRef, llvm::StringRef, llvm::StringRef, llvm::ArrayRef<llvm::StringRef>, llvm::ArrayRef<llvm::SubtargetSubTypeKV>, llvm::ArrayRef<llvm::SubtargetFeatureKV>) (/nix/store/wcvck76nnpi9slmj4csksgp37df4sx09->
#6 0x0000555556f054bc llvm::MCSubtargetInfo::InitMCProcessorInfo(llvm::StringRef, llvm::StringRef, llvm::StringRef) (/nix/store/wcvck76nnpi9slmj4csksgp37df4sx09-buddy-mlir-unstable-2024-07-18/bin/buddy-llc+0x19b14bc)
#7 0x0000555556b38c77 llvm::TargetSubtargetInfo::TargetSubtargetInfo(llvm::Triple const&, llvm::StringRef, llvm::StringRef, llvm::StringRef, llvm::ArrayRef<llvm::StringRef>, llvm::ArrayRef<llvm::SubtargetFeatureKV>, llvm::ArrayRef<llvm::SubtargetSubTypeKV>, llvm::MCWrite>
#8 0x0000555555dd736c llvm::RISCVSubtarget::RISCVSubtarget(llvm::Triple const&, llvm::StringRef, llvm::StringRef, llvm::StringRef, llvm::StringRef, unsigned int, unsigned int, llvm::TargetMachine const&) (/nix/store/wcvck76nnpi9slmj4csksgp37df4sx09-buddy-mlir-unstable-20>
#9 0x0000555555dd9049 llvm::RISCVTargetMachine::getSubtargetImpl(llvm::Function const&) const (/nix/store/wcvck76nnpi9slmj4csksgp37df4sx09-buddy-mlir-unstable-2024-07-18/bin/buddy-llc+0x885049) I don't get such error using LLVM llc, so I guess there are missing linking libraries. |
Met Python op error after bump:
|
Should be fixed with following patch. The new --- a/frontend/Python/ops/linalg.py 1970-01-01 08:00:01.000000000 +0800
+++ b/frontend/Python/ops/linalg.py 2025-04-09 21:59:09.917019537 +0800
@@ -1854,9 +1854,9 @@
output = tensor.EmptyOp(output_shape, mlir_dtype)
if not isinstance(input2.type, ir.RankedTensorType):
- input2 = tensor.SplatOp(tensor_type, input2).result
+ input2 = tensor.SplatOp(tensor_type, input2, []).result
if not isinstance(input3.type, ir.RankedTensorType):
- input3 = tensor.SplatOp(tensor_type, input3).result
+ input3 = tensor.SplatOp(tensor_type, input3, []).result
generic_map = ir.AffineMap.get_permutation(
[i for i in range(len(output_shape))]
@@ -2038,7 +2038,7 @@
input_shape = ir.RankedTensorType(input_tensor.type).shape
tensor_type = ir.RankedTensorType.get(input_shape, input_dtype)
scalar = arith.ConstantOp(input_dtype, node.args[1])
- rhs = tensor.SplatOp(tensor_type, scalar)
+ rhs = tensor.SplatOp(tensor_type, scalar, [])
if str(input_dtype).find("i") != -1:
cmp_op = arith.CmpIOp(4, input_tensor, rhs)
else:
@@ -2069,7 +2069,7 @@
tensor_type = ir.RankedTensorType.get(input_shape, input_dtype)
scalar = arith.ConstantOp(input_dtype, node.args[1])
- rhs = tensor.SplatOp(tensor_type, scalar)
+ rhs = tensor.SplatOp(tensor_type, scalar, [])
if str(input_dtype).find("i") != -1:
cmp_op = arith.CmpIOp(5, input_tensor, rhs)
@@ -2390,7 +2390,7 @@
scalar = arith.ConstantOp(input_dtype, float(node.args[1]))
else:
scalar = arith.ConstantOp(input_dtype, node.args[1])
- rhs = tensor.SplatOp(tensor_type, scalar)
+ rhs = tensor.SplatOp(tensor_type, scalar, [])
if str(input_dtype).find("i") != -1:
cmp_op = arith.CmpIOp(0, input_tensor, rhs)
else: |
Now with following error:
|
Should be fixed with following patch --- a/frontend/Python/ops/linalg.py 1970-01-01 08:00:01.000000000 +0800
+++ b/frontend/Python/ops/linalg.py 1970-01-01 08:00:01.000000000 +0800
@@ -1166,7 +1166,7 @@
element = mlir_element_attr_get(dtype, 0.0)
attr = ir.DenseElementsAttr.get_splat(tensor_type, element)
matmul_result_buffer = arith.ConstantOp(tensor_type, attr).result
- op = linalg.matmul(input1, input2, outs=[matmul_result_buffer])
+ op = linalg.matmul(input1, input2, outputs=[matmul_result_buffer])
return op
@@ -1186,7 +1186,7 @@
element = mlir_element_attr_get(dtype, 0.0)
attr = ir.DenseElementsAttr.get_splat(tensor_type, element)
result_buffer = arith.ConstantOp(tensor_type, attr).result
- op = linalg.matmul_transpose_b(input1, input2, outs=[result_buffer])
+ op = linalg.matmul_transpose_b(input1, input2, outputs=[result_buffer])
return op
|
Now with error:
|
No description provided.