You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Support xla_hlo.convert operation on Structured Ops Path to SPIR-V #1687
Lowering xla_hlo.convert operations to SPIR-V on Structured Ops path requires use of std.trunci, std.sitofp, std.truncf, etc. The lowering from XLA-HLO to Linalg is fairly easy to add (the existing XLA-LHLO to Linalg lowering can be reused), but legalizing the std instructions to SPIR-V requires effective handling of integer widths.
changed the title [-]Support Convert operation on Structured Ops Path to SPIR-V[/-][+]Support `xla_hlo.convert` operation on Structured Ops Path to SPIR-V[/+]on Apr 27, 2020
changed the title [-]Support `xla_hlo.convert` operation on Structured Ops Path to SPIR-V[/-][+]Support xla_hlo.convert operation on Structured Ops Path to SPIR-V[/+]on Apr 27, 2020
I studied a bit on this issue since I'm working on integer width adjustment. I have a CL chain to pass the test except the last test case -- float_to_int. I haven't figured out the reason, will take a look later.
We don't have a pattern to convert floating point to integer in map_xla_to_scalar_op.h
I don't know why, it seems that there is only SIToFPOp in Standard Dialect, but no FPToSIOp. It would be super easy to support once there is something like FPToSIOp in Standard Dialect.
Activity
[-]Support Convert operation on Structured Ops Path to SPIR-V[/-][+]Support `xla_hlo.convert` operation on Structured Ops Path to SPIR-V[/+][-]Support `xla_hlo.convert` operation on Structured Ops Path to SPIR-V[/-][+]Support xla_hlo.convert operation on Structured Ops Path to SPIR-V[/+]hanhanW commentedon Apr 28, 2020
I studied a bit on this issue since I'm working on integer width adjustment. I have a CL chain to pass the test except the last test case -- float_to_int. I haven't figured out the reason, will take a look later.
hanhanW commentedon Apr 28, 2020
Just found that the reason is quite simple.
We don't have a pattern to convert floating point to integer in map_xla_to_scalar_op.h
I don't know why, it seems that there is only SIToFPOp in Standard Dialect, but no FPToSIOp. It would be super easy to support once there is something like FPToSIOp in Standard Dialect.
Enable most of xla_hlo.convert related tests on vulkan.
Enable most of xla_hlo.convert related tests on vulkan.
Enable most of xla_hlo.convert related tests on vulkan.
Enable most of xla_hlo.convert related tests on vulkan.
Enalbe clamp.mlir and convert.mlir test on vulkan.
Enable clamp.mlir and convert.mlir test on vulkan.
Enable clamp.mlir and convert.mlir test on vulkan.
Enable clamp.mlir and convert.mlir test on vulkan.