Bug 27992 - Incremental compile time = complete build time
Summary: Incremental compile time = complete build time
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows 2000
: P3 blocker (vote)
Target Milestone: 2.1 M4   Edit
Assignee: Kent Johnson CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-12-09 20:18 EST by abraham tio CLA
Modified: 2003-03-17 11:31 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description abraham tio CLA 2002-12-09 20:18:42 EST
trivial change & save to one file triggers incremental build requiring as much 
time as a complete build.
installed eclipse M4 on new win2k, latest jvm. connected to cvs repository. 
checked out project as... complete build finished without issue.  added, saved 
blank line to one .java file triggered a build of some sort: did not confirm if 
it was a complete build, but it takes as long as one.  

discussed briefly on newsgroup: as follows: 

Abraham, thank you for giving us this initial diagnostic information. 
This tells us that all of the time is taken by the incremental java 
builder.  This definitely looks like a bug.  Incremental compilation 
after a no-op change in a single file should *always* be fast.  Your 
timings show that the incremental build is taking about as long as a 
full build.  Please enter a bug report in bugzilla against JDT->Core so 
this can be diagnosed further.  My initial suspicion is that your 
classpath has errors or cycles in it, but entering a bug report is the 
best way to track it down.  Please include the timing results in the bug 
report.  The java builder people will help you diagnose this further. 
Thanks for your patience.
-


abraham tio wrote:
> hi everybody. the results are in.
> 
> before i went ahead and carried out john's instructions, i uninstalled
> eclipse, reinstalled, just to be certain i didn't overlook some dialogue box
> or error message that might have been thrown up or that i might have ignored
> during eclipse's installation completion: none were seen, nothing unusual at
> all.
> the jdk i have running here is j2sdk-1_4_1_01 (the windows-i586.exe).
> 
> a brief primer on this output:
> the first invocation of the javabuilder occured when i checked out recent
> changes i had written the night previous and checked into our cvs.
> the second invocation of the javabuilder occured when i added a blank line
> to one .java file and saved it.
> the workbench is set to perform a build automatically on resource
> modification.
> 
> i did a search in the news group for similar posts: builder, invoking, etc.
> no pertinent results.
> the eclipse documentation is pretty detailed about the process of building
> and how eclipse likes to function. i was even tempted to start poking around
> in builder config, but i thought i should submit this information to the
> gang first.
> 
> whaddayathink?
> ========================================================================
> Startup: using configuration
> file:C:\Prog\eclipse\workspace\.metadata\.config\pl
> atform.cfg
> Boot URL: file:C:/Prog/eclipse/plugins/org.eclipse.core.boot_2.1.0/boot.jar
> Startup: splash path =
> C:\Prog\eclipse\plugins\org.eclipse.platform_2.1.0\splash
> .bmp
> Workspace location:
>    C:\Prog\eclipse\workspace
> Debug-Options:
>     file:C:/Prog/eclipse/.options
> Install URL:
>     file:C:/Prog/eclipse/
> Starting snapshot delay thread
> Invoking builder: JavaBuilder(tacteon)
> [Thread[Snapshot,5,main]] Operation waiting to be executed... :-/
> Builder finished: JavaBuilder(tacteon) time: 252804ms
> Invoking builder: ManifestConsistencyChecker(tacteon)
> Computing delta for project: tacteon
> Finished computing delta, time: 491ms
> Builder finished: ManifestConsistencyChecker(tacteon) time: 531ms
> Invoking builder: ExtensionPointSchemaBuilder(tacteon)
> Builder finished: ExtensionPointSchemaBuilder(tacteon) time: 40ms
> [Thread[Snapshot,5,main]] Operation started... :-)
> Snapshot took: 1031 milliseconds.
> Starting snapshot delay thread
> Invoking builder: JavaBuilder(tacteon)
> Builder finished: JavaBuilder(tacteon) time: 233025ms
> Invoking builder: ManifestConsistencyChecker(tacteon)
> Computing delta for project: tacteon
> Finished computing delta, time: 171ms
> Builder finished: ManifestConsistencyChecker(tacteon) time: 171ms
> Invoking builder: ExtensionPointSchemaBuilder(tacteon)
> Builder finished: ExtensionPointSchemaBuilder(tacteon) time: 0ms
> ===================================================================
> "John Arthorne" <John_Arthorne@oti.com_> wrote in message
> news:3DED49CF.20901@oti.com_...
> 
>>Please try the following:
>>
>>1) Create a file called ".options" in your eclipse home directory (it
>>should be a sibling of eclipse.exe).
>>2) Add the following contents:
>>
>>org.eclipse.core.resources/debug=true
>>org.eclipse.core.resources/build/failure=true
>>org.eclipse.core.resources/build/invoking=true
>>org.eclipse.core.resources/build/delta=true
>>
>>3) Restart eclipse, passing the "-debug" command line parameter.
>>
>>4) Respond here with a description of the console output when your
>>looong build occurs.
>>
>>This will give us some diagnostic information to find out which builder
>>is taking so long, and why.
>>-
>>
>>
>>
>>
>>abraham tio wrote:
>>
>>>hi all:
>>>
>>>running 2.1. no matter what i do:
>>>    copy a file from one folder to another
>>>    changing a file by one letter
>>>    creating a file
>>>eclipse spends five minutes or more invoking the compiler.
>>>at this rate, i can look forward to my next product release in 2057,
>>
> perhaps
> 
>>>later.
>>>
>>>previously i'd used the feb14 build. i'm working on a new machine now
>>
> and
> 
>>>brought down the most recent stable build.
>>>
>>>could some one please please direct me to where i can tell eclipse to
>>
> stop
> 
>>>doing a complete rebuild of my entire project every time i change just
>>
> one
> 
>>>file ?
>>>
>>>much appreciated.
>>>
>>>
>>
> 
>
Comment 1 Philipe Mulet CLA 2002-12-10 12:40:49 EST
In your .options file, can you please add the following lines:

org.eclipse.jdt.core/debug=true
org.eclipse.jdt.core/debug/builder=true

also remember that (as described in 
http://download.eclipse.org/downloads/drops/S-M3-200211151436/eclipse-news-
M3.html)

When you first open an existing workspace with Eclipse 2.1 M3, use Project > 
Rebuild All to explicitly rebuild all Java projects before proceeding. If you 
don't, incremental builds will fail saying that some prerequisite projects 
failed to build. (This is necessitated by a change to the internal 
representation of  a built state of a Java project.)
Comment 2 Kent Johnson CLA 2002-12-10 13:35:40 EST
Can you also please configure the Task list to show 'only errors' on 'the 
selected resource & its children'... then select your project.

What errors do you see?
Comment 3 Kent Johnson CLA 2002-12-11 11:01:46 EST
Abraham, sorry I deleted your e-mail, I thought you had pasted your comments 
into this PR.

The explanation for your problem is found in the errors on your project. 
Anytime we cannot build your project because of missing .class or .jar files, 
the build is aborted so we do not generate 100's of the same error. No .class 
files are generated since we cannot successfully compile all the source files.

Major build failures must be fixed before you can continue to develop your 
code. Any further changes will start a full build until the build succeeds.

In the future, whenever you see a red X on your project you should check the 
task list to see if the errors are serious.