1 /* { dg-do compile } */
2 /* { dg-options "-O -w" } */
4 /* This code snippet from glibc 2.3.5 was causing an ICE during
5 optimization because we were failing to update the SSA form for
6 stale name tags. These are tags that are associated with SSA pointers
7 that have been removed from the IL. This was causing the SSA
8 verifier to fail before we had a chance to run the cleanup pass that
9 finally removes all the remaining PHI nodes for the stale name tag. */
15 typedef struct _IO_FILE _IO_FILE;
23 extern const struct _IO_jump_t _IO_file_jumps_maybe_mmap ;
24 extern const struct _IO_jump_t _IO_wfile_jumps;
25 extern const struct _IO_jump_t _IO_wfile_jumps_maybe_mmap ;
27 _IO_new_fdopen (fd, mode)
34 struct _IO_FILE_plus fp;
35 struct _IO_wide_data wd;
48 if (((fd_flags & 0003) == 00 && !(read_write & 8))
49 || ((fd_flags & 0003) == 01 && !(read_write & 4)))
52 if ((posix_mode & 02000) && !(fd_flags & 02000))
54 _IO_no_init (&new_f->fp.file, 0, 0, &new_f->wd,
55 (use_mmap && (read_write & 8))
56 ? &_IO_wfile_jumps_maybe_mmap :
58 (use_mmap && (read_write & 8)) ? &_IO_file_jumps_maybe_mmap :
59 _IO_file_init (&new_f->fp);