This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug driver/47547] WHOPR, can't use /dev/null as an output file


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

Richard Guenther <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2011.01.31 13:29:28
                 CC|                            |hjl at gcc dot gnu.org
     Ever Confirmed|0                           |1

--- Comment #1 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-01-31 13:29:28 UTC ---
We end up with -dumpdir /dev/ -dumpbase null.wpa.  The failure occurs in

(gdb) up
#1  0x0000000000936029 in init_asm_output (name=0x1780640 "t.o")
    at /space/rguenther/src/svn/trunk/gcc/toplev.c:928
928             fatal_error ("can%'t open %s for writing: %m", asm_file_name);
(gdb) l
923           if (!strcmp (asm_file_name, "-"))
924             asm_out_file = stdout;
925           else
926             asm_out_file = fopen (asm_file_name, "w+b");
927           if (asm_out_file == 0)
928             fatal_error ("can%'t open %s for writing: %m", asm_file_name);
929         }
930
931       if (!flag_syntax_only)
932         {

and

(gdb) p global_options->x_dump_base_name 
$2 = 0x179ce30 "/dev/null.wpa"

I think HJ caused this (the -dumpdir / -dumpbase flags are bogus), non-LTO
does not use -dumpdir, lto-wrapper.c is what sets that flag (I don't
remember why -dumpdir is used at all - HJ?).

Same problem with

gcc -S t.c -o /dev/null -fdump-tree-optimized

btw, so not really LTO specific (but more annoying).


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]