This is the mail archive of the 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]

Re: GCC vs. `make' on Solaris

>>>>> "Mike" == Mike Stump <> writes:

    Mike> Gosh, while we can investigate this, we should not do it
    Mike> because of a random stupid bug on Solaris.  If build times
    Mike> are within a few % of the non stamp build, then it would be
    Mike> reasonable, if they are 4x longer, then I am in no way in
    Mike> favor of doing this.  Making this type of decision without
    Mike> supporting data would be bad.

Why will they be any longer at all?

If we have:

  x.o: s-foo
    gcc -c x.c

  s-foo: bar
    bar > tmp-foo
    move-if-change tmp-foo foo
    touch s-foo

Make will rebuild `x.o' whenever s-foo is out of date (i.e., whenever
`bar' changes), even if foo is not modified.

I can measure this, though.

I think the point of this trick is so that you can (in two steps) do:

  make s-foo
  make x.o

If you do it this way then x.o will not be rebuilt unless it really
needs to be.  That's a silly optimization; when you're doing
development rebuilding the compiler is now a very cheap operation.  On
any modern box, rebuilding cc1 takes only a few minutes at most.  The
real killer is rebuilding the libraries -- and this trickery has no
effect there.

Mark Mitchell         
CodeSourcery, LLC     

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