[Bug fortran/29459] Spurious warning about uninitialized optional arguments

fxcoudert at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Tue Aug 14 15:26:00 GMT 2007



------- Comment #8 from fxcoudert at gcc dot gnu dot org  2007-08-14 15:26 -------
(In reply to comment #7)
> I suspect that '<anonymous>' is labels.0 (though it *has* a name!)

Well, that was wrong. If you look at the gimple tree (004t.gimple), it contains
the following:

print_sub (l, labels, _labels)
{
  <unnamed-unsigned:64> D.1377;
  int4 D.1378;
  <unnamed-unsigned:64> D.1379;
  logical4 D.1380;
  <unnamed-unsigned:64> D.1381;
  char * D.1382;
  char[1][1:_labels] * labels.0;
  bit_size_type D.1373;
  <unnamed-unsigned:64> D.1374;
  bit_size_type D.1375;
  <unnamed-unsigned:64> D.1376;

  if (labels != 0B)
    {
      D.1377 = (<unnamed-unsigned:64>) _labels;
      D.1373 = D.1377 * 8;
      D.1378 = _labels + -1;
      D.1379 = (<unnamed-unsigned:64>) D.1378;
      D.1374 = D.1379 + 1;
      D.1377 = (<unnamed-unsigned:64>) _labels;
      D.1375 = D.1377 * 8;
      D.1378 = _labels + -1;
      D.1379 = (<unnamed-unsigned:64>) D.1378;
      D.1376 = D.1379 + 1;
      labels.0 = (char[1][1:_labels] *) labels;

  [...]

  if (labels != 0B)
    {
      D.1381 = D.1374;
      D.1382 = &(*labels.0)[0]{lb: 0 sz: NON_LVALUE_EXPR <D.1381>}[1]{lb: 1 sz:
1};
      _gfortran_transfer_character (&dt_parm.0, D.1382, _labels);
      _gfortran_st_write_done (&dt_parm.0);
    }

So, now, my guess is that our anonymous is D.1374. But the thing is, I looked
through trans-array.c and trans-decl.c, and I can't find the place where it's
generated!


-- 


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



More information about the Gcc-bugs mailing list