public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug bootstrap/50513] New: cross configurations fail to build ipa-inline-analysis.o with -Werror
@ 2011-09-25 19:23 amylaar at gcc dot gnu.org
  2011-09-25 20:04 ` [Bug bootstrap/50513] " mikpe at it dot uu.se
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: amylaar at gcc dot gnu.org @ 2011-09-25 19:23 UTC (permalink / raw)
  To: gcc-bugs

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

             Bug #: 50513
           Summary: cross configurations fail to build
                    ipa-inline-analysis.o with -Werror
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Keywords: build
          Severity: major
          Priority: P3
         Component: bootstrap
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: amylaar@gcc.gnu.org
            Blocks: 44756
              Host: x86_64-unknown-linux-gnu
            Target: any cross


183 of 198 configurations in contrib/config-list.mk fail to build build with
this error:

../../../gcc/gcc/ipa-inline-analysis.c: In function ‘predicate_probability’:
../../../gcc/gcc/ipa-inline-analysis.c:485:8: error: comparison between signed
and unsigned integer expressions [-Werror=sign-compare]
../../../gcc/gcc/ipa-inline-analysis.c: In function ‘remap_edge_change_prob’:
../../../gcc/gcc/ipa-inline-analysis.c:2356:5: error: comparison between signed
and unsigned integer expressions [-Werror=sign-compare]
cc1: all warnings being treated as errors

(the other configurations fail for other reasons)

I have used a native compiler previously bootstrapped from the same sources.
I see that for the boostrap, ipa-inline-analysis.o was built once with
the bootstrap compiler, and twice with the previous stage g++.  For the
cross-compilation, on the other hand, gcc is used (even though g++ is
also available), with the additional options:
-Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -Wc++-compat


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

* [Bug bootstrap/50513] cross configurations fail to build ipa-inline-analysis.o with -Werror
  2011-09-25 19:23 [Bug bootstrap/50513] New: cross configurations fail to build ipa-inline-analysis.o with -Werror amylaar at gcc dot gnu.org
@ 2011-09-25 20:04 ` mikpe at it dot uu.se
  2011-09-27 13:55 ` mikpe at it dot uu.se
  2012-03-05 22:21 ` amylaar at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: mikpe at it dot uu.se @ 2011-09-25 20:04 UTC (permalink / raw)
  To: gcc-bugs

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

Mikael Pettersson <mikpe at it dot uu.se> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mikpe at it dot uu.se

--- Comment #1 from Mikael Pettersson <mikpe at it dot uu.se> 2011-09-25 19:22:14 UTC ---
Native builds of current trunk (mine is gcc-4.7-20110924 == r179148) also fail
in the same way, when configured with --disable-build-poststage1-with-cxx.  The
reason is that PR50012 (a C++ FE diagnostics bug) causes some warnings in new
code to go undetected, until someone does a build in proper C mode.

Anyway, for this PR the fix should be:

--- gcc-4.7-20110924/gcc/ipa-inline-analysis.c.~1~      2011-09-23
19:30:34.000000000 +0200
+++ gcc-4.7-20110924/gcc/ipa-inline-analysis.c  2011-09-25 20:39:45.000000000
+0200
@@ -482,8 +482,8 @@ predicate_probability (conditions conds,
                                     i2 - predicate_first_dynamic_condition);
                    if (c->code == CHANGED
                        && (c->operand_num
-                           < VEC_length (inline_param_summary_t,
-                                         inline_param_summary)))
+                           < (int) VEC_length (inline_param_summary_t,
+                                               inline_param_summary)))
                      {
                        int iprob = VEC_index (inline_param_summary_t,
                                               inline_param_summary,
@@ -2353,8 +2353,8 @@ remap_edge_change_prob (struct cgraph_ed
          struct ipa_jump_func *jfunc = ipa_get_ith_jump_func (args, i);
          if (jfunc->type == IPA_JF_PASS_THROUGH
              && (jfunc->value.pass_through.formal_id
-                 < VEC_length (inline_param_summary_t,
-                               inlined_es->param)))
+                 < (int) VEC_length (inline_param_summary_t,
+                                     inlined_es->param)))
            {
              int prob1 = VEC_index (inline_param_summary_t,
                                     es->param, i)->change_prob;


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

* [Bug bootstrap/50513] cross configurations fail to build ipa-inline-analysis.o with -Werror
  2011-09-25 19:23 [Bug bootstrap/50513] New: cross configurations fail to build ipa-inline-analysis.o with -Werror amylaar at gcc dot gnu.org
  2011-09-25 20:04 ` [Bug bootstrap/50513] " mikpe at it dot uu.se
@ 2011-09-27 13:55 ` mikpe at it dot uu.se
  2012-03-05 22:21 ` amylaar at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: mikpe at it dot uu.se @ 2011-09-27 13:55 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Mikael Pettersson <mikpe at it dot uu.se> 2011-09-27 13:34:56 UTC ---
Probably fixed by Richard Sandiford in r179268.


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

* [Bug bootstrap/50513] cross configurations fail to build ipa-inline-analysis.o with -Werror
  2011-09-25 19:23 [Bug bootstrap/50513] New: cross configurations fail to build ipa-inline-analysis.o with -Werror amylaar at gcc dot gnu.org
  2011-09-25 20:04 ` [Bug bootstrap/50513] " mikpe at it dot uu.se
  2011-09-27 13:55 ` mikpe at it dot uu.se
@ 2012-03-05 22:21 ` amylaar at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: amylaar at gcc dot gnu.org @ 2012-03-05 22:21 UTC (permalink / raw)
  To: gcc-bugs

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

Jorn Wolfgang Rennecke <amylaar at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED

--- Comment #3 from Jorn Wolfgang Rennecke <amylaar at gcc dot gnu.org> 2012-03-05 22:20:40 UTC ---
(In reply to comment #2)
> Probably fixed by Richard Sandiford in r179268.

I can confirm that the file builds fine in r184927


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

end of thread, other threads:[~2012-03-05 22:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-25 19:23 [Bug bootstrap/50513] New: cross configurations fail to build ipa-inline-analysis.o with -Werror amylaar at gcc dot gnu.org
2011-09-25 20:04 ` [Bug bootstrap/50513] " mikpe at it dot uu.se
2011-09-27 13:55 ` mikpe at it dot uu.se
2012-03-05 22:21 ` amylaar at gcc dot gnu.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).