Permalink
Browse files

Upgrade V8 to 3.1.8

  • Loading branch information...
1 parent cf7b680 commit 14475c77a61795ab706ddca41be955ea8b8c9eeb @ry ry committed Mar 3, 2011
Showing with 7,645 additions and 2,254 deletions.
  1. +14 −1 deps/v8/ChangeLog
  2. +27 −94 deps/v8/SConstruct
  3. +1 −2 deps/v8/src/SConscript
  4. +4 −2 deps/v8/src/api.cc
  5. +1 −0 deps/v8/src/arm/assembler-arm.h
  6. +675 −31 deps/v8/src/arm/code-stubs-arm.cc
  7. +33 −14 deps/v8/src/arm/codegen-arm.cc
  8. +8 −0 deps/v8/src/arm/constants-arm.h
  9. +312 −270 deps/v8/src/arm/full-codegen-arm.cc
  10. +19 −8 deps/v8/src/arm/ic-arm.cc
  11. +1 −2 deps/v8/src/arm/lithium-arm.cc
  12. +25 −60 deps/v8/src/arm/lithium-codegen-arm.cc
  13. +0 −5 deps/v8/src/arm/lithium-codegen-arm.h
  14. +126 −3 deps/v8/src/arm/macro-assembler-arm.cc
  15. +45 −4 deps/v8/src/arm/macro-assembler-arm.h
  16. +22 −8 deps/v8/src/arm/simulator-arm.cc
  17. +10 −2 deps/v8/src/arm/stub-cache-arm.cc
  18. +7 −5 deps/v8/src/arm/virtual-frame-arm.cc
  19. +1 −1 deps/v8/src/arm/virtual-frame-arm.h
  20. +15 −5 deps/v8/src/builtins.cc
  21. +110 −105 deps/v8/src/builtins.h
  22. +4 −3 deps/v8/src/compiler.cc
  23. +7 −1 deps/v8/src/d8.cc
  24. +618 −0 deps/v8/src/d8.js
  25. +121 −0 deps/v8/src/debug-debugger.js
  26. +2 −1 deps/v8/src/debug.cc
  27. +7 −2 deps/v8/src/flag-definitions.h
  28. +4 −16 deps/v8/src/full-codegen.cc
  29. +9 −39 deps/v8/src/full-codegen.h
  30. +0 −10 deps/v8/src/handles-inl.h
  31. +12 −6 deps/v8/src/handles.cc
  32. +43 −63 deps/v8/src/handles.h
  33. +27 −18 deps/v8/src/heap-profiler.cc
  34. +3 −1 deps/v8/src/heap-profiler.h
  35. +5 −10 deps/v8/src/heap.cc
  36. +105 −164 deps/v8/src/hydrogen.cc
  37. +4 −11 deps/v8/src/hydrogen.h
  38. +2 −3 deps/v8/src/ia32/code-stubs-ia32.cc
  39. +20 −9 deps/v8/src/ia32/codegen-ia32.cc
  40. +88 −272 deps/v8/src/ia32/full-codegen-ia32.cc
  41. +17 −10 deps/v8/src/ia32/ic-ia32.cc
  42. +9 −9 deps/v8/src/ia32/lithium-codegen-ia32.cc
  43. +13 −6 deps/v8/src/ia32/lithium-ia32.cc
  44. +7 −3 deps/v8/src/ia32/stub-cache-ia32.cc
  45. +21 −5 deps/v8/src/ia32/virtual-frame-ia32.cc
  46. +2 −2 deps/v8/src/ia32/virtual-frame-ia32.h
  47. +9 −0 deps/v8/src/ic-inl.h
  48. +64 −38 deps/v8/src/ic.cc
  49. +33 −12 deps/v8/src/ic.h
  50. +90 −0 deps/v8/src/liveobjectlist-inl.h
  51. +2,475 −1 deps/v8/src/liveobjectlist.cc
  52. +245 −35 deps/v8/src/liveobjectlist.h
  53. +7 −0 deps/v8/src/mark-compact.cc
  54. +6 −2 deps/v8/src/messages.js
  55. +4 −2 deps/v8/src/objects-inl.h
  56. +30 −11 deps/v8/src/objects.cc
  57. +8 −4 deps/v8/src/objects.h
  58. +65 −23 deps/v8/src/parser.cc
  59. +0 −28 deps/v8/src/profile-generator-inl.h
  60. +433 −372 deps/v8/src/profile-generator.cc
  61. +122 −62 deps/v8/src/profile-generator.h
  62. +33 −38 deps/v8/src/runtime-profiler.cc
  63. +3 −2 deps/v8/src/runtime-profiler.h
  64. +344 −57 deps/v8/src/runtime.cc
  65. +21 −6 deps/v8/src/runtime.h
  66. +46 −32 deps/v8/src/stub-cache.cc
  67. +21 −12 deps/v8/src/stub-cache.h
  68. +1 −1 deps/v8/src/version.cc
  69. +0 −8 deps/v8/src/virtual-frame-heavy-inl.h
  70. +210 −4 deps/v8/src/x64/code-stubs-x64.cc
  71. +20 −20 deps/v8/src/x64/codegen-x64.cc
  72. +142 −45 deps/v8/src/x64/full-codegen-x64.cc
  73. +16 −9 deps/v8/src/x64/ic-x64.cc
  74. +94 −16 deps/v8/src/x64/lithium-codegen-x64.cc
  75. +11 −0 deps/v8/src/x64/lithium-codegen-x64.h
  76. +21 −7 deps/v8/src/x64/lithium-x64.cc
  77. +6 −2 deps/v8/src/x64/stub-cache-x64.cc
  78. +25 −5 deps/v8/src/x64/virtual-frame-x64.cc
  79. +2 −2 deps/v8/src/x64/virtual-frame-x64.h
  80. +5 −4 deps/v8/test/cctest/test-api.cc
  81. +1 −1 deps/v8/test/cctest/test-compiler.cc
  82. +2 −1 deps/v8/test/cctest/test-debug.cc
  83. +38 −25 deps/v8/test/cctest/test-heap.cc
  84. +8 −3 deps/v8/test/cctest/test-mark-compact.cc
  85. +0 −66 deps/v8/test/es5conform/es5conform.status
  86. +25 −0 deps/v8/test/mjsunit/array-join.js
  87. +0 −12 deps/v8/test/mjsunit/mjsunit.status
  88. +36 −0 deps/v8/test/mjsunit/override-eval-with-non-function.js
  89. +35 −0 deps/v8/test/mjsunit/regress/regress-1207.js
  90. +34 −0 deps/v8/test/mjsunit/regress/regress-1209.js
  91. +48 −0 deps/v8/test/mjsunit/regress/regress-1210.js
  92. +43 −0 deps/v8/test/mjsunit/regress/regress-1213.js
  93. +29 −0 deps/v8/test/mjsunit/regress/regress-1218.js
  94. +128 −0 deps/v8/test/mjsunit/strict-mode.js
View
@@ -1,10 +1,23 @@
+2011-03-02: Version 3.1.8
+
+ Fixed a number of crash bugs.
+
+ Improved Crankshaft for x64 and ARM.
+
+ Implemented more of EcmaScript 5 strict mode.
+
+ Fixed issue with unaligned reads and writes on ARM.
+
+ Improved heap profiler support.
+
+
2011-02-28: Version 3.1.7
Fixed a number of crash bugs.
Improved Crankshaft for x64 and ARM.
- Fixed implementation of indexOf/lastIndexOf for sparse
+ Fixed implementation of indexOf/lastIndexOf for sparse
arrays (http://crbug.com/73940).
Fixed bug in map space compaction (http://crbug.com/59688).
View
@@ -27,7 +27,6 @@
import platform
import re
-import subprocess
import sys
import os
from os.path import join, dirname, abspath
@@ -143,9 +142,6 @@ LIBRARY_FLAGS = {
# Use visibility=default to disable this.
'CXXFLAGS': ['-fvisibility=hidden']
},
- 'strictaliasing:off': {
- 'CCFLAGS': ['-fno-strict-aliasing']
- },
'mode:debug': {
'CCFLAGS': ['-g', '-O0'],
'CPPDEFINES': ['ENABLE_DISASSEMBLER', 'DEBUG'],
@@ -655,16 +651,8 @@ def Abort(message):
sys.exit(1)
-def GuessOS(env):
- return utils.GuessOS()
-
-
-def GuessArch(env):
- return utils.GuessArchitecture()
-
-
-def GuessToolchain(env):
- tools = env['TOOLS']
+def GuessToolchain(os):
+ tools = Environment()['TOOLS']
if 'gcc' in tools:
return 'gcc'
elif 'msvc' in tools:
@@ -673,9 +661,7 @@ def GuessToolchain(env):
return None
-def GuessVisibility(env):
- os = env['os']
- toolchain = env['toolchain'];
+def GuessVisibility(os, toolchain):
if (os == 'win32' or os == 'cygwin') and toolchain == 'gcc':
# MinGW / Cygwin can't do it.
return 'default'
@@ -685,35 +671,27 @@ def GuessVisibility(env):
return 'hidden'
-def GuessStrictAliasing(env):
- # There seems to be a problem with gcc 4.5.x
- # see http://code.google.com/p/v8/issues/detail?id=884
- # it can be worked around by disabling strict aliasing
- toolchain = env['toolchain'];
- if toolchain == 'gcc':
- env = Environment(tools=['gcc'])
- version = subprocess.Popen([env['CC'], '-dumpversion'],
- stdout=subprocess.PIPE).communicate()[0]
- if version.find('4.5.') == 0:
- return 'off'
- return 'default'
+OS_GUESS = utils.GuessOS()
+TOOLCHAIN_GUESS = GuessToolchain(OS_GUESS)
+ARCH_GUESS = utils.GuessArchitecture()
+VISIBILITY_GUESS = GuessVisibility(OS_GUESS, TOOLCHAIN_GUESS)
SIMPLE_OPTIONS = {
'toolchain': {
'values': ['gcc', 'msvc'],
- 'guess': GuessToolchain,
- 'help': 'the toolchain to use'
+ 'default': TOOLCHAIN_GUESS,
+ 'help': 'the toolchain to use (%s)' % TOOLCHAIN_GUESS
},
'os': {
'values': ['freebsd', 'linux', 'macos', 'win32', 'android', 'openbsd', 'solaris', 'cygwin'],
- 'guess': GuessOS,
- 'help': 'the os to build for'
+ 'default': OS_GUESS,
+ 'help': 'the os to build for (%s)' % OS_GUESS
},
'arch': {
'values':['arm', 'ia32', 'x64', 'mips'],
- 'guess': GuessArch,
- 'help': 'the architecture to build for'
+ 'default': ARCH_GUESS,
+ 'help': 'the architecture to build for (%s)' % ARCH_GUESS
},
'regexp': {
'values': ['native', 'interpreted'],
@@ -822,15 +800,8 @@ SIMPLE_OPTIONS = {
},
'visibility': {
'values': ['default', 'hidden'],
- 'guess': GuessVisibility,
- 'depends': ['os', 'toolchain'],
- 'help': 'shared library symbol visibility'
- },
- 'strictaliasing': {
- 'values': ['default', 'off'],
- 'guess': GuessStrictAliasing,
- 'depends': ['toolchain'],
- 'help': 'assume strict aliasing while optimizing'
+ 'default': VISIBILITY_GUESS,
+ 'help': 'shared library symbol visibility (%s)' % VISIBILITY_GUESS
},
'pgo': {
'values': ['off', 'instrument', 'optimize'],
@@ -840,55 +811,19 @@ SIMPLE_OPTIONS = {
}
-def AddOption(result, name, option):
- if 'guess' in option:
- # Option has a guess function
- guess = option.get('guess')
- guess_env = Environment(options=result)
- # Check if all options that the guess function depends on are set
- if 'depends' in option:
- for dependency in option.get('depends'):
- if not dependency in guess_env:
- return False
- default = guess(guess_env)
- else:
- # Option has a fixed default
- default = option.get('default')
-
- help = '%s (%s)' % (option.get('help'), ", ".join(option['values']))
- result.Add(name, help, default)
- return True
-
-
def GetOptions():
result = Options()
result.Add('mode', 'compilation mode (debug, release)', 'release')
result.Add('sample', 'build sample (shell, process, lineprocessor)', '')
result.Add('cache', 'directory to use for scons build cache', '')
result.Add('env', 'override environment settings (NAME0:value0,NAME1:value1,...)', '')
result.Add('importenv', 'import environment settings (NAME0,NAME1,...)', '')
- options = SIMPLE_OPTIONS
- while len(options):
- postpone = {}
- for (name, option) in options.iteritems():
- if not AddOption(result, name, option):
- postpone[name] = option
- options = postpone
+ for (name, option) in SIMPLE_OPTIONS.iteritems():
+ help = '%s (%s)' % (name, ", ".join(option['values']))
+ result.Add(name, help, option.get('default'))
return result
-def GetTools(opts):
- env = Environment(options=opts)
- os = env['os']
- toolchain = env['toolchain']
- if os == 'win32' and toolchain == 'gcc':
- return ['mingw']
- elif os == 'win32' and toolchain == 'msvc':
- return ['msvc', 'mslink', 'mslib', 'msvs']
- else:
- return ['default']
-
-
def GetVersionComponents():
MAJOR_VERSION_PATTERN = re.compile(r"#define\s+MAJOR_VERSION\s+(.*)")
MINOR_VERSION_PATTERN = re.compile(r"#define\s+MINOR_VERSION\s+(.*)")
@@ -969,7 +904,7 @@ def VerifyOptions(env):
print env['simulator']
Abort("Option unalignedaccesses only supported for the ARM architecture.")
for (name, option) in SIMPLE_OPTIONS.iteritems():
- if (not name in env):
+ if (not option.get('default')) and (name not in ARGUMENTS):
message = ("A value for option %s must be specified (%s)." %
(name, ", ".join(option['values'])))
Abort(message)
@@ -1097,7 +1032,7 @@ def ParseEnvOverrides(arg, imports):
return overrides
-def BuildSpecific(env, mode, env_overrides, tools):
+def BuildSpecific(env, mode, env_overrides):
options = {'mode': mode}
for option in SIMPLE_OPTIONS:
options[option] = env[option]
@@ -1150,7 +1085,7 @@ def BuildSpecific(env, mode, env_overrides, tools):
(object_files, shell_files, mksnapshot) = env.SConscript(
join('src', 'SConscript'),
build_dir=join('obj', target_id),
- exports='context tools',
+ exports='context',
duplicate=False
)
@@ -1170,21 +1105,21 @@ def BuildSpecific(env, mode, env_overrides, tools):
library = env.SharedLibrary(library_name, object_files, PDB=pdb_name)
context.library_targets.append(library)
- d8_env = Environment(tools=tools)
+ d8_env = Environment()
d8_env.Replace(**context.flags['d8'])
context.ApplyEnvOverrides(d8_env)
shell = d8_env.Program('d8' + suffix, object_files + shell_files)
context.d8_targets.append(shell)
for sample in context.samples:
- sample_env = Environment(tools=tools)
+ sample_env = Environment()
sample_env.Replace(**context.flags['sample'])
sample_env.Prepend(LIBS=[library_name])
context.ApplyEnvOverrides(sample_env)
sample_object = sample_env.SConscript(
join('samples', 'SConscript'),
build_dir=join('obj', 'sample', sample, target_id),
- exports='sample context tools',
+ exports='sample context',
duplicate=False
)
sample_name = sample + suffix
@@ -1197,7 +1132,7 @@ def BuildSpecific(env, mode, env_overrides, tools):
cctest_program = cctest_env.SConscript(
join('test', 'cctest', 'SConscript'),
build_dir=join('obj', 'test', target_id),
- exports='context object_files tools',
+ exports='context object_files',
duplicate=False
)
context.cctest_targets.append(cctest_program)
@@ -1207,9 +1142,7 @@ def BuildSpecific(env, mode, env_overrides, tools):
def Build():
opts = GetOptions()
- tools = GetTools(opts)
- env = Environment(options=opts, tools=tools)
-
+ env = Environment(options=opts)
Help(opts.GenerateHelpText(env))
VerifyOptions(env)
env_overrides = ParseEnvOverrides(env['env'], env['importenv'])
@@ -1223,7 +1156,7 @@ def Build():
d8s = []
modes = SplitList(env['mode'])
for mode in modes:
- context = BuildSpecific(env.Copy(), mode, env_overrides, tools)
+ context = BuildSpecific(env.Copy(), mode, env_overrides)
libraries += context.library_targets
mksnapshots += context.mksnapshot_targets
cctests += context.cctest_targets
View
@@ -31,7 +31,6 @@ root_dir = dirname(File('SConstruct').rfile().abspath)
sys.path.append(join(root_dir, 'tools'))
import js2c
Import('context')
-Import('tools')
SOURCES = {
@@ -306,7 +305,7 @@ def Abort(message):
def ConfigureObjectFiles():
- env = Environment(tools=tools)
+ env = Environment()
env.Replace(**context.flags['v8'])
context.ApplyEnvOverrides(env)
env['BUILDERS']['JS2C'] = Builder(action=js2c.JS2C)
View
@@ -2286,7 +2286,8 @@ bool v8::Object::Set(v8::Handle<Value> key, v8::Handle<Value> value,
self,
key_obj,
value_obj,
- static_cast<PropertyAttributes>(attribs));
+ static_cast<PropertyAttributes>(attribs),
+ i::kNonStrictMode);
has_pending_exception = obj.is_null();
EXCEPTION_BAILOUT_CHECK(false);
return true;
@@ -2711,7 +2712,8 @@ bool v8::Object::SetHiddenValue(v8::Handle<v8::String> key,
hidden_props,
key_obj,
value_obj,
- static_cast<PropertyAttributes>(None));
+ static_cast<PropertyAttributes>(None),
+ i::kNonStrictMode);
has_pending_exception = obj.is_null();
EXCEPTION_BAILOUT_CHECK(false);
return true;
@@ -284,6 +284,7 @@ const SwVfpRegister s29 = { 29 };
const SwVfpRegister s30 = { 30 };
const SwVfpRegister s31 = { 31 };
+const DwVfpRegister no_dreg = { -1 };
const DwVfpRegister d0 = { 0 };
const DwVfpRegister d1 = { 1 };
const DwVfpRegister d2 = { 2 };
Oops, something went wrong.

0 comments on commit 14475c7

Please sign in to comment.