Fix regression caused by context creation optimization r2681.
authorager@chromium.org <ager@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Tue, 18 Aug 2009 09:14:19 +0000 (09:14 +0000)
committerager@chromium.org <ager@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Tue, 18 Aug 2009 09:14:19 +0000 (09:14 +0000)
The issue is that a shift operation is used when creating the
snapshot.  This means that the shift binary operation stub is
generated at snapshot time without sse3 instructions.

The fix is to use division instead.

TBR=erik.corry@gmail.com

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2704 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

src/v8natives.js

index be92347..e11c80f 100644 (file)
@@ -47,7 +47,7 @@ const $isFinite = GlobalIsFinite;
 // Helper function used to install functions on objects.
 function InstallFunctions(object, attributes, functions) {
   if (functions.length >= 8) {
-    %OptimizeObjectForAddingMultipleProperties(object, functions.length >> 1);
+    %OptimizeObjectForAddingMultipleProperties(object, functions.length / 2);
   }
   for (var i = 0; i < functions.length; i += 2) {
     var key = functions[i];