Details
Diff Detail
- Repository
- rL LLVM
Event Timeline
lib/Target/X86/X86ISelLowering.cpp | ||
---|---|---|
37054 ↗ | (On Diff #184089) | Maybe use DAG.GetDemandedBits ? |
lib/Target/X86/X86ISelLowering.cpp | ||
---|---|---|
37020 ↗ | (On Diff #184089) | The operation is similar to what's done here. |
37054 ↗ | (On Diff #184089) | It's not obvious to me that it would work. The and opcode itself uses it, so there is no need to redo it here. We also need to know if masking took place to know what we can accept as LHS for the sub opcode. |
lib/Target/X86/X86ISelLowering.cpp | ||
---|---|---|
37054 ↗ | (On Diff #184089) | I know this code (Bits - 1) check is used in other places earlier in this function, but is that valid for i16 SHLD/SHRD? SHLD/SHRD hardware mask shift amount to 5 bits on i16/i32 and 6 bits on i64. |
We might be better off just working on getting this code moved into DAGCombine (https://bugs.llvm.org/show_bug.cgi?id=40081) and use generic funnel shifts.
lib/Target/X86/X86ISelLowering.cpp | ||
---|---|---|
37054 ↗ | (On Diff #184089) | I do not know if this is valid for i16. If that isn't, this code is bogous already. Would you have a test case I can rely on to do this ? |
lib/Target/X86/X86ISelLowering.cpp | ||
---|---|---|
37054 ↗ | (On Diff #184089) | Yes I think its wrong - we're most likely being saved by the fact that its so tricky to create i16 double shifts from code (PR35155). As I said I'd much prefer to kill all this code and move it to FSHL/FSHR in DAGCombine (PR40081) - I'll take a look. |