public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/58359] New: __builtin_unreachable prevents vectorization
@ 2013-09-08  8:20 glisse at gcc dot gnu.org
  2013-09-09  8:22 ` [Bug tree-optimization/58359] " rguenth at gcc dot gnu.org
                   ` (13 more replies)
  0 siblings, 14 replies; 15+ messages in thread
From: glisse at gcc dot gnu.org @ 2013-09-08  8:20 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58359

            Bug ID: 58359
           Summary: __builtin_unreachable prevents vectorization
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Keywords: missed-optimization
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: glisse at gcc dot gnu.org

void f(int*q){
  int*p=(int*)__builtin_assume_aligned(q,32);
  for(int i=0;i<(1<<20);++i){
    if(p+i==0)__builtin_unreachable();
    p[i]=i;
  }
}

If I remove the line with __builtin_unreachable, this is vectorized at -O3. But
as is, we have control flow in the loop and the vectorizer won't even try.


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2023-04-18 14:48 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-08  8:20 [Bug tree-optimization/58359] New: __builtin_unreachable prevents vectorization glisse at gcc dot gnu.org
2013-09-09  8:22 ` [Bug tree-optimization/58359] " rguenth at gcc dot gnu.org
2013-09-17 13:31 ` glisse at gcc dot gnu.org
2013-09-20 14:20 ` a.sinyavin at samsung dot com
2013-09-27 14:46 ` a.sinyavin at samsung dot com
2013-09-27 14:46 ` a.sinyavin at samsung dot com
2013-09-27 14:48 ` a.sinyavin at samsung dot com
2013-10-23 14:56 ` glisse at gcc dot gnu.org
2013-10-23 15:55 ` a.sinyavin at samsung dot com
2013-10-23 15:56 ` a.sinyavin at samsung dot com
2013-10-24  8:52 ` jakub at gcc dot gnu.org
2013-10-24 12:03 ` glisse at gcc dot gnu.org
2013-12-06 12:22 ` a.sinyavin at samsung dot com
2021-08-24 23:22 ` pinskia at gcc dot gnu.org
2023-04-18 14:48 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).