make/solaris/adlc_updater

Fri, 03 Sep 2010 17:51:07 -0700

author
iveresov
date
Fri, 03 Sep 2010 17:51:07 -0700
changeset 2138
d5d065957597
parent 910
284d0af00d53
child 2186
a50abfc67f31
permissions
-rw-r--r--

6953144: Tiered compilation
Summary: Infrastructure for tiered compilation support (interpreter + c1 + c2) for 32 and 64 bit. Simple tiered policy implementation.
Reviewed-by: kvn, never, phh, twisti

duke@435 1 #! /bin/sh
duke@435 2 #
duke@435 3 # This file is used by adlc.make to selectively update generated
duke@435 4 # adlc files. Because source and target diretories are relative
duke@435 5 # paths, this file is copied to the target build directory before
duke@435 6 # use.
duke@435 7 #
duke@435 8 # adlc-updater <file> <source-dir> <target-dir>
duke@435 9 #
jrose@910 10 fix_lines() {
jrose@910 11 # repair bare #line directives in $1 to refer to $2
jrose@910 12 awk < $1 > $1+ '
jrose@910 13 /^#line 999999$/ {print "#line " (NR+1) " \"" F2 "\""; next}
jrose@910 14 {print}
jrose@910 15 ' F2=$2
jrose@910 16 mv $1+ $1
jrose@910 17 }
jrose@910 18 [ -f $3/$1 ] && (fix_lines $2/$1 $3/$1; cmp -s $2/$1 $3/$1) || \
jrose@910 19 ( [ -f $3/$1 ] && echo Updating $3/$1 ; touch $2/made-change ; mv $2/$1 $3/$1 )

mercurial