> See the bug for symptoms and rationale.
> 
> In short, after [JDK-8288396](https://bugs.openjdk.org/browse/JDK-8288396) 
> moved the timestamp to `CFLAGS_VM_VERSION` macro, which changes with every 
> build, we get Hotspot recompilation every time, even when Hotspot is not 
> modified.
> 
> I believe current behavior is correct for `--with-source-date=updated` 
> (current default): you do Hotspot build, you get updated build timestamp, 
> which forces recompilation of affected compilation units, relinkage, 
> re-creation of jmods/jimage. The way out is to switch to 
> `--with-source-date=current`, which would only get the build timestamp at 
> configure time.
> 
> CIs and build farms are likely reconfiguring before every build anyway, so 
> their behavior is unlikely to be affected. But this switch definitely 
> improves the day-to-day OpenJDK development work: it saves >50 seconds on 
> every `make` for my machine, see below.
> 
> Back-to-back unmodified build before:
> 
> 
> $ CONF=linux-x86_64-server-release time make hotspot
> Building target 'hotspot' in configuration 'linux-x86_64-server-release'
> Finished building target 'hotspot' in configuration 
> 'linux-x86_64-server-release'
> 
> 39.03user 10.97system 0:56.89elapsed 87%CPU (0avgtext+0avgdata 
> 2048944maxresident)k
> 363616inputs+4108072outputs (484major+1100154minor)pagefaults 0swaps
> 
> $ CONF=linux-x86_64-server-release time make hotspot
> Building target 'hotspot' in configuration 'linux-x86_64-server-release'
> Finished building target 'hotspot' in configuration 
> 'linux-x86_64-server-release'
> 
> 38.18user 9.02system 0:49.18elapsed 95%CPU (0avgtext+0avgdata 
> 2048788maxresident)k
> 40inputs+4101112outputs (0major+1100077minor)pagefaults 0swaps
> 
> 
> Back-to-back unmodified build after:
> 
> 
> $ CONF=linux-x86_64-server-release time make hotspot
> Building target 'hotspot' in configuration 'linux-x86_64-server-release'
> Finished building target 'hotspot' in configuration 
> 'linux-x86_64-server-release'
> 
> 2.15user 0.22system 0:02.59elapsed 91%CPU (0avgtext+0avgdata 
> 49480maxresident)k
> 0inputs+176outputs (0major+55506minor)pagefaults 0swaps
> 
> $ CONF=linux-x86_64-server-release time make hotspot
> Building target 'hotspot' in configuration 'linux-x86_64-server-release'
> Finished building target 'hotspot' in configuration 
> 'linux-x86_64-server-release'
> 
> 2.18user 0.14system 0:02.46elapsed 94%CPU (0avgtext+0avgdata 
> 49332maxresident)k

Aleksey Shipilev has updated the pull request with a new target base due to a 
merge or a rebase. The incremental webrev excludes the unrelated changes 
brought in by the merge/rebase. The pull request contains three additional 
commits since the last revision:

 - Missed the spot
 - Merge branch 'master' into JDK-8290466-default-source-date-current
 - Fix

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/9638/files
  - new: https://git.openjdk.org/jdk/pull/9638/files/0f0163f5..10ab14aa

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=9638&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=9638&range=00-01

  Stats: 8370 lines in 323 files changed: 4727 ins; 2878 del; 765 mod
  Patch: https://git.openjdk.org/jdk/pull/9638.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/9638/head:pull/9638

PR: https://git.openjdk.org/jdk/pull/9638

Reply via email to