Hi David! I'd be interested in hearing about the places that you had to fix. It seems like there is a number of people who are starting to look at the quality of the generated vector code. Maybe we should report our findings in bug reports, so that we could share the work and discuss possible findings. I also plan to fill a few bug reports with suboptimal code. Thanks, Nadav -----Original Message----- From: David A. Greene [mailto:dag at cray.com] Sent: Wednesday, February 08, 2012 18:11 To: Duncan Sands Cc: David A. Greene; Rotem, Nadav; Zaks, Ayal; llvmdev at cs.uiuc.edu Subject: Re: [LLVMdev] SelectionDAG scalarizes vector operations. Duncan Sands <baldrick at free.fr> writes:> I think it is important we produce non-scalarized code for the IR > produced by the GCC vectorizer, since we know it can be done > (otherwise GCC wouldn't have produced it). It is of course important > to produce decent code in the most common cases coming from other > vectorizers too. However it seems sensible to me to start with the > case where you know you can easily get perfect results (GCC vectorizer > output) and then try to progressively extend the goodness to the more problematic cases coming from other vectorizers.Of course. I was simply supporting Nadav's explanation that there's a lot of pessimization in the current lowering that doesn't even appear for code generated by gcc. We have a number of lowering modifications here to handle many of these cases. As always, I am slogging through trying to get them moved upstream. It's a long process, unfortunately. But don't be surprised to see changes that might look "unnecessary" but are very important for various compilers. -Dave --------------------------------------------------------------------- Intel Israel (74) Limited This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies.
Hi Nadav,> I'd be interested in hearing about the places that you had to fix. It seems like there is a number of people who are starting to look at the quality of the generated vector code. Maybe we should report our findings in bug reports, so that we could share the work and discuss possible findings. I also plan to fill a few bug reports with suboptimal code.yes, it would be great to have collection of important testcases that are handled poorly. Ciao, Duncan.
David A. Greene
2012-Feb-08 17:01 UTC
[LLVMdev] SelectionDAG scalarizes vector operations.
"Rotem, Nadav" <nadav.rotem at intel.com> writes:> Hi David! > > I'd be interested in hearing about the places that you had to fix. It > seems like there is a number of people who are starting to look at the > quality of the generated vector code. Maybe we should report our > findings in bug reports, so that we could share the work and discuss > possible findings. I also plan to fill a few bug reports with > suboptimal code.That's a good idea. I confess that I don't have a laundry list at-hand. These were fixes I made two years ago. I'll have to do a giant diff against the upstream LLVM. :) But yes, I fully intend to send these fixes up. -Dave
On Feb 8, 2012, at 9:01 AM, David A. Greene wrote:> "Rotem, Nadav" <nadav.rotem at intel.com> writes: > >> Hi David! >> >> I'd be interested in hearing about the places that you had to fix. It >> seems like there is a number of people who are starting to look at the >> quality of the generated vector code. Maybe we should report our >> findings in bug reports, so that we could share the work and discuss >> possible findings. I also plan to fill a few bug reports with >> suboptimal code. > > That's a good idea. I confess that I don't have a laundry list at-hand. > These were fixes I made two years ago. I'll have to do a giant diff > against the upstream LLVM. :) > > But yes, I fully intend to send these fixes up.Would it make sense to start something like a lib/Target/README-Vectors.txt file with a collection of small examples of pessimizations? We've successfully used text files like this to track "laundry lists" like this. High priority problems (e.g. the sorts that Duncan is pointing out) makes sense to track in bugzilla, of course. -Chris
Apparently Analagous Threads
- [LLVMdev] SelectionDAG scalarizes vector operations.
- [LLVMdev] SelectionDAG scalarizes vector operations.
- [LLVMdev] SelectionDAG scalarizes vector operations.
- [LLVMdev] SelectionDAG scalarizes vector operations.
- [LLVMdev] SelectionDAG scalarizes vector operations.