DescriptionFix performance regressions due to lazy initialization.
This CL:
- Adds a new trait parameter to LazyInstance to let it initialize the instance
without paying the cost of atomic operations (which are expensive on Mac).
This only works for users who don't care about thread-safety and this is now
the default initialization trait used by LazyInstance in v8.
- Reverts the changes that were made in r11010 in isolate.{cc,h}. That lets
Isolate's accessors be as cheap as they were before (but adds one static initializer).
- Adds OS::PostSetup() used to initialize the math functions which depend on CPU features.
That lets the math functions get rid of CallOnce().
BUG=118686
Committed: https://code.google.com/p/v8/source/detail?r=11198
Patch Set 1 #
Total comments: 12
Patch Set 2 : Address Daniel's comments. #Patch Set 3 : Add OS::PostSetUp(). #
Total comments: 4
Patch Set 4 : Address Daniel's comments. #Patch Set 5 : Add isolate.cc static initializer back. #Patch Set 6 : Update check-static-initializers.sh. #Patch Set 7 : Revert r11010 changes in api.cc. #Patch Set 8 : Make init traits non-template structs. #
Messages
Total messages: 9 (0 generated)
|