-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[HVX] Failure on seemingly valid schedule #7806
Comments
Hey @rootjalex - I am sorry I missed this on Friday. Is this still an issue? Does your PR #7805 fix this? Let me take a look at this on Tuesday. |
@pranavb-ca No worries! Unfortunately no, that PR does not address this issue |
I think I have a fix for this. This problem sounded vaguely familiar and sure enough, I had fixed this downstream recently but hadn't upstreamed my fkx. My fault entirely. Sorry about that. I'll post the fix later today (or early tomorrow if that's ok with you as I have a series of meetings today) |
Great, thank you so much! No rush! |
FWIW, this
The problem is that there is no saturating downcast of u16 values to u8, that is
isn't supported on HVX. So, the solution is to pattern match it and then custom expand it in bitcode ( |
) (#7825) * Dump the IR more frequently in HexagonOptimize.cpp * Fix 8bit unsigned saturating downcasts for HVX We do not have a way of reliably lowering the following expression to LLVM bitcode for HVX. u8_sat(uint16x) where uint16x is a vector (preferably a HVX double vector) with element type uint16. Since there is no native HVX instruction to do this, this patch introduces two helper functions in hvx_128.ll to perform this operation. One function interleaves its input (trunc_satub.vuh) and the other does not (pack_satub.vuh) This patch also removes declaration of some intrinsics not use any longer in hvx_128.ll * Make IR dump messages in HexagonOptimize.cpp consistent with those in CodeGen_Hexagon.cpp * fix clang-format complaints --------- Co-authored-by: Steven Johnson <srj@google.com>
…lide#7806) (halide#7825) * Dump the IR more frequently in HexagonOptimize.cpp * Fix 8bit unsigned saturating downcasts for HVX We do not have a way of reliably lowering the following expression to LLVM bitcode for HVX. u8_sat(uint16x) where uint16x is a vector (preferably a HVX double vector) with element type uint16. Since there is no native HVX instruction to do this, this patch introduces two helper functions in hvx_128.ll to perform this operation. One function interleaves its input (trunc_satub.vuh) and the other does not (pack_satub.vuh) This patch also removes declaration of some intrinsics not use any longer in hvx_128.ll * Make IR dump messages in HexagonOptimize.cpp consistent with those in CodeGen_Hexagon.cpp * fix clang-format complaints --------- Co-authored-by: Steven Johnson <srj@google.com>
I'm getting a failure related to interleaving on a simple HVX schedule:
@pranavb-ca do you know what might fix this?
The text was updated successfully, but these errors were encountered: