http://codereview.chromium.org/9455088/diff/46/tools/check-static-initializers.sh
File tools/check-static-initializers.sh (right):

http://codereview.chromium.org/9455088/diff/46/tools/check-static-initializers.sh#newcode36
tools/check-static-initializers.sh:36: v8_out=$(readlink -f $(dirname
$BASH_SOURCE)/../out)
A few points:

 * A non-shared scons build only generates a library for the preparser.

 * You typically have various build variants lying around, which get
added together and therefore things will almost always fail.

  * You can't use this for a presubmit script, because there is no
guarantee that the objects you find are the ones created from the
current sources.

  * Just to be nitpicking: What is being counted here is *not* the
number of static initializers, it is the number of compilation units
having at least 1 static initializer.

  * You can greatly simplify the whole script by just looking at the
final executable, doing something like "objdump --headers
--section=.ctors d8" and look at the size of the section.

http://codereview.chromium.org/9455088/

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to