public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/23247] New: ICE on valid code when compiled with -O3 and -ftree-vectorize
@ 2005-08-05 10:44 zlynx at acm dot org
  2005-08-05 10:45 ` [Bug c/23247] " zlynx at acm dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: zlynx at acm dot org @ 2005-08-05 10:44 UTC (permalink / raw)
  To: gcc-bugs

# gcc -v
Using built-in specs.
Target: x86_64-pc-linux-gnu
Configured with:
/var/tmp/portage/gcc-4.1.0_beta20050730/work/gcc-4.1-20050730/configure
--enable-version-specific-runtime-libs --prefix=/usr
--bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.1.0-beta20050730
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.0-beta20050730/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.1.0-beta20050730
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.1.0-beta20050730/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.1.0-beta20050730/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.0-beta20050730/include/g++-v4
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec
--enable-nls --without-included-gettext --with-system-zlib --disable-checking
--disable-werror --disable-libunwind-exceptions --enable-multilib
--disable-libgcj --enable-languages=c,c++,f95 --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
Thread model: posix
gcc version 4.1.0 20050730 (experimental)

# gcc -O3 -ftree-vectorize j2.c -c
j2.c: In function 'user_has_privileges':
j2.c:75: internal compiler error: Segmentation fault


j2.c will be attached.  I trimmed it as much as I could.

-- 
           Summary: ICE on valid code when compiled with -O3 and -ftree-
                    vectorize
           Product: gcc
           Version: 4.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: zlynx at acm dot org
                CC: gcc-bugs at gcc dot gnu dot org
  GCC host triplet: x86_64-pc-linux-gnu


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


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

* [Bug c/23247] ICE on valid code when compiled with -O3 and -ftree-vectorize
  2005-08-05 10:44 [Bug c/23247] New: ICE on valid code when compiled with -O3 and -ftree-vectorize zlynx at acm dot org
@ 2005-08-05 10:45 ` zlynx at acm dot org
  2005-08-05 15:29 ` [Bug tree-optimization/23247] " pinskia at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: zlynx at acm dot org @ 2005-08-05 10:45 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From zlynx at acm dot org  2005-08-05 10:45 -------
Created an attachment (id=9435)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=9435&action=view)
code to reproduce ICE


-- 


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


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

* [Bug tree-optimization/23247] ICE on valid code when compiled with -O3 and -ftree-vectorize
  2005-08-05 10:44 [Bug c/23247] New: ICE on valid code when compiled with -O3 and -ftree-vectorize zlynx at acm dot org
  2005-08-05 10:45 ` [Bug c/23247] " zlynx at acm dot org
@ 2005-08-05 15:29 ` pinskia at gcc dot gnu dot org
  2005-08-05 16:42 ` [Bug tree-optimization/23247] [4.1 Regression] " pinskia at gcc dot gnu dot org
  2005-08-06  7:03 ` pinskia at gcc dot gnu dot org
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-08-05 15:29 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|c                           |tree-optimization


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


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

* [Bug tree-optimization/23247] [4.1 Regression] ICE on valid code when compiled with -O3 and -ftree-vectorize
  2005-08-05 10:44 [Bug c/23247] New: ICE on valid code when compiled with -O3 and -ftree-vectorize zlynx at acm dot org
  2005-08-05 10:45 ` [Bug c/23247] " zlynx at acm dot org
  2005-08-05 15:29 ` [Bug tree-optimization/23247] " pinskia at gcc dot gnu dot org
@ 2005-08-05 16:42 ` pinskia at gcc dot gnu dot org
  2005-08-06  7:03 ` pinskia at gcc dot gnu dot org
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-08-05 16:42 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-08-05 16:42 -------
Confirmed, reduced testcase:
typedef struct {
 unsigned int mask[4];
} SE_PRIV;
static const SE_PRIV se_priv_all = { { 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF } };
typedef struct sid_info
{
 SE_PRIV privileges;
} NT_USER_TOKEN;
void *memcpy(void*,void*,__SIZE_TYPE__);
static void se_priv_empty( const SE_PRIV *mask )
{
 SE_PRIV p1;
 int i;   
 se_priv_copy( &p1, mask ); 
 for ( i=0; i<4; i++ ) {
  p1.mask[i] &= se_priv_all.mask[i];
 }
}

void is_privilege_assigned( SE_PRIV *privileges, const SE_PRIV *check )
{
 SE_PRIV p1;
 se_priv_empty( check );
 
 SE_PRIV allprivs; 
 int i;
  for ( i=0; i<4; i++ ) {
  allprivs.mask[i] &= ~check->mask[i];
 }
 memcpy( &p1, &allprivs, sizeof(SE_PRIV) );
}


But I don't think this is a vectorizer bug really but a complete unrolling bug.
The weird thing it works on x86 but not on x86_64.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
           Keywords|                            |ice-on-valid-code
   Last reconfirmed|0000-00-00 00:00:00         |2005-08-05 16:42:13
               date|                            |
            Summary|ICE on valid code when      |[4.1 Regression] ICE on
                   |compiled with -O3 and -     |valid code when compiled
                   |ftree-vectorize             |with -O3 and -ftree-
                   |                            |vectorize
   Target Milestone|---                         |4.1.0


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


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

* [Bug tree-optimization/23247] [4.1 Regression] ICE on valid code when compiled with -O3 and -ftree-vectorize
  2005-08-05 10:44 [Bug c/23247] New: ICE on valid code when compiled with -O3 and -ftree-vectorize zlynx at acm dot org
                   ` (2 preceding siblings ...)
  2005-08-05 16:42 ` [Bug tree-optimization/23247] [4.1 Regression] " pinskia at gcc dot gnu dot org
@ 2005-08-06  7:03 ` pinskia at gcc dot gnu dot org
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-08-06  7:03 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-08-06 07:02 -------
This is a dup of bug 23082.

*** This bug has been marked as a duplicate of 23082 ***

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |DUPLICATE


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


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

end of thread, other threads:[~2005-08-06  7:03 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-08-05 10:44 [Bug c/23247] New: ICE on valid code when compiled with -O3 and -ftree-vectorize zlynx at acm dot org
2005-08-05 10:45 ` [Bug c/23247] " zlynx at acm dot org
2005-08-05 15:29 ` [Bug tree-optimization/23247] " pinskia at gcc dot gnu dot org
2005-08-05 16:42 ` [Bug tree-optimization/23247] [4.1 Regression] " pinskia at gcc dot gnu dot org
2005-08-06  7:03 ` pinskia at gcc dot gnu dot 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).