Hi,

mainline bootstrap on s390 currently fails with:

build/genmddeps ../../gcc/config/s390/s390.md > tmp-mddeps
../../gcc/config/s390/s390.md:2041: undefined attribute 'DBL<D0>' used for mode
../../gcc/config/s390/s390.md:2041: following context is `'

DBL is a macro attribute defined as:

(define_mode_attr DBL [(DI "TI") (SI "DI")])

The pattern in question is:

(define_insn "*clrmem_long"
  [(clobber (match_operand:<DBL> 0 "register_operand" "=d"))
   (set (mem:BLK (subreg:P (match_operand:<DBL> 2 "register_operand" "0") 0))
        (const_int 0))
   (use (match_dup 2))
   (use (match_operand:<DBL> 1 "register_operand" "d"))
   (clobber (reg:CC CC_REGNUM))]
  ""
  "mvcle\t%0,%1,0\;jo\t.-4"
  [(set_attr "length" "8")
   (set_attr "type" "vs")])

I think the problem lies in genmddeps. genmddeps seems to randomly complain 
about
uses of the DBL attribute. Always with an again randomly appended character at 
the
end of the macro name in the error message.

At first glance it appears like a string null termination problem so I've added:

Index: gcc/read-rtl.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/read-rtl.c,v
retrieving revision 1.38
diff -p -c -r1.38 read-rtl.c
*** gcc/read-rtl.c      17 May 2005 12:50:32 -0000      1.38
--- gcc/read-rtl.c      18 May 2005 08:00:47 -0000
*************** mode_attr_index (struct map_value **mode
*** 323,328 ****
--- 323,330 ----
    obstack_grow (&string_obstack, string + 1, strlen (string) - 2);
    p = (char *) obstack_finish (&string_obstack);

+   p[strlen (string) - 2] = 0;
+
    mv = XNEW (struct map_value);
    mv->number = *mode_maps == 0 ? 0 : (*mode_maps)->number + 1;
    mv->string = p;


... which takes s390 back to bootstrap land. This is probably not the proper fix
but it maybe helps debugging that issue.

Any ideas what goes wrong here?!

Bye,

-Andreas-

Reply via email to