Skip to content

Commit

Permalink
Version 3.14.2
Browse files Browse the repository at this point in the history
ARM: allowed VFP3 instructions when hardfloat is enabled. (Chromium issue 152506)

Fixed instance_descriptors() and PushStackTraceAndDie regressions. (Chromium issue 151749)

Made GDBJIT interface compile again. (issue 1804)

Fixed Accessors::FunctionGetPrototype's proto chain traversal. (Chromium issue 143967)

Made sure that names of temporaries do not clash with real variables. (issue 2322)

Rejected local module declarations. (Chromium issue 150628)

Rejected uses of lexical for-loop variable on the RHS. (issue 2322)

Fixed slot recording of code target patches. (Chromium issue 152615,chromium:144230)

Changed the Android makefile to use GCC 4.6 instead of GCC 4.4.3.

Performance and stability improvements on all platforms.

git-svn-id: https://v8.googlecode.com/svn/trunk@12693 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
  • Loading branch information
verwaest@chromium.org committed Oct 10, 2012
1 parent 3ecb95d commit b4befaf
Show file tree
Hide file tree
Showing 224 changed files with 20,439 additions and 16,842 deletions.
11 changes: 11 additions & 0 deletions .gitignore
Expand Up @@ -27,11 +27,22 @@ shell_g
/build/Release
/obj/
/out/
/test/cctest/cctest.status2
/test/es5conform/data
/test/message/message.status2
/test/mjsunit/mjsunit.status2
/test/mozilla/CHECKED_OUT_VERSION
/test/mozilla/data
/test/mozilla/downloaded_*
/test/mozilla/mozilla.status2
/test/preparser/preparser.status2
/test/sputnik/sputniktests
/test/test262/data
/test/test262/test262-*
/test/test262/test262.status2
/third_party
/tools/jsfunfuzz
/tools/jsfunfuzz.zip
/tools/oom_dump/oom_dump
/tools/oom_dump/oom_dump.o
/tools/visual_studio/Debug
Expand Down
28 changes: 28 additions & 0 deletions ChangeLog
@@ -1,3 +1,31 @@
2012-10-10: Version 3.14.2

ARM: allowed VFP3 instructions when hardfloat is enabled.
(Chromium issue 152506)

Fixed instance_descriptors() and PushStackTraceAndDie regressions.
(Chromium issue 151749)

Made GDBJIT interface compile again. (issue 1804)

Fixed Accessors::FunctionGetPrototype's proto chain traversal.
(Chromium issue 143967)

Made sure that names of temporaries do not clash with real variables.
(issue 2322)

Rejected local module declarations. (Chromium issue 150628)

Rejected uses of lexical for-loop variable on the RHS. (issue 2322)

Fixed slot recording of code target patches.
(Chromium issue 152615,chromium:144230)

Changed the Android makefile to use GCC 4.6 instead of GCC 4.4.3.

Performance and stability improvements on all platforms.


2012-10-01: Version 3.14.1

Don't set -m32 flag when compiling with Android ARM compiler.
Expand Down
2 changes: 1 addition & 1 deletion DEPS
Expand Up @@ -5,7 +5,7 @@
deps = {
# Remember to keep the revision in sync with the Makefile.
"v8/build/gyp":
"http://gyp.googlecode.com/svn/trunk@1282",
"http://gyp.googlecode.com/svn/trunk@1501",
}

deps_os = {
Expand Down
3 changes: 2 additions & 1 deletion Makefile
Expand Up @@ -280,6 +280,7 @@ $(ENVFILE).new:
echo "CXX=$(CXX)" >> $(ENVFILE).new

# Dependencies.
# Remember to keep these in sync with the DEPS file.
dependencies:
svn checkout --force http://gyp.googlecode.com/svn/trunk build/gyp \
--revision 1282
--revision 1501
4 changes: 2 additions & 2 deletions Makefile.android
Expand Up @@ -48,11 +48,11 @@ endif
ifeq ($(ARCH), android_arm)
DEFINES = target_arch=arm v8_target_arch=arm android_target_arch=arm
DEFINES += arm_neon=0 armv7=1
TOOLCHAIN_ARCH = arm-linux-androideabi-4.4.3
TOOLCHAIN_ARCH = arm-linux-androideabi-4.6
else
ifeq ($(ARCH), android_ia32)
DEFINES = target_arch=ia32 v8_target_arch=ia32 android_target_arch=x86
TOOLCHAIN_ARCH = x86-4.4.3
TOOLCHAIN_ARCH = x86-4.6
else
$(error Target architecture "${ARCH}" is not supported)
endif
Expand Down
11 changes: 11 additions & 0 deletions OWNERS
@@ -0,0 +1,11 @@
danno@chromium.org
jkummerow@chromium.org
mmassi@chromium.org
mstarzinger@chromium.org
mvstanton@chromium.org
rossberg@chromium.org
svenpanne@chromium.org
ulan@chromium.org
vegorov@chromium.org
verwaest@chromium.org
yangguo@chromium.org
71 changes: 71 additions & 0 deletions PRESUBMIT.py
@@ -0,0 +1,71 @@
# Copyright 2012 the V8 project authors. All rights reserved.
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following
# disclaimer in the documentation and/or other materials provided
# with the distribution.
# * Neither the name of Google Inc. nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

"""Top-level presubmit script for V8.
See http://dev.chromium.org/developers/how-tos/depottools/presubmit-scripts
for more details about the presubmit API built into gcl.
"""

def _V8PresubmitChecks(input_api, output_api):
"""Runs the V8 presubmit checks."""
import sys
sys.path.append(input_api.os_path.join(
input_api.PresubmitLocalPath(), 'tools'))
from presubmit import CppLintProcessor
from presubmit import SourceProcessor

results = []
if not CppLintProcessor().Run(input_api.PresubmitLocalPath()):
results.append(output_api.PresubmitError("C++ lint check failed"))
if not SourceProcessor().Run(input_api.PresubmitLocalPath()):
results.append(output_api.PresubmitError(
"Copyright header and trailing whitespaces check failed"))
return results


def _CommonChecks(input_api, output_api):
"""Checks common to both upload and commit."""
results = []
results.extend(input_api.canned_checks.CheckOwners(
input_api, output_api, source_file_filter=None))
return results


def CheckChangeOnUpload(input_api, output_api):
results = []
results.extend(_CommonChecks(input_api, output_api))
return results


def CheckChangeOnCommit(input_api, output_api):
results = []
results.extend(_CommonChecks(input_api, output_api))
results.extend(input_api.canned_checks.CheckChangeHasDescription(
input_api, output_api))
results.extend(_V8PresubmitChecks(input_api, output_api))
return results
12 changes: 9 additions & 3 deletions build/common.gypi
Expand Up @@ -152,7 +152,7 @@
[ 'v8_use_arm_eabi_hardfloat=="true"', {
'defines': [
'USE_EABI_HARDFLOAT=1',
'CAN_USE_VFP2_INSTRUCTIONS',
'CAN_USE_VFP3_INSTRUCTIONS',
],
'target_conditions': [
['_toolset=="target"', {
Expand Down Expand Up @@ -302,9 +302,14 @@
['_toolset=="target"', {
'variables': {
'm32flag': '<!((echo | $(echo ${CXX_target:-${CXX:-$(which g++)}}) -m32 -E - > /dev/null 2>&1) && echo "-m32" || true)',
'clang%': 0,
},
'cflags': [ '<(m32flag)' ],
'ldflags': [ '<(m32flag)' ],
'conditions': [
['OS!="android" or clang==1', {
'cflags': [ '<(m32flag)' ],
'ldflags': [ '<(m32flag)' ],
}],
],
'xcode_settings': {
'ARCHS': [ 'i386' ],
},
Expand Down Expand Up @@ -346,6 +351,7 @@
['OS=="linux" or OS=="freebsd" or OS=="openbsd" or OS=="netbsd"', {
'cflags': [ '-Wall', '<(werror)', '-W', '-Wno-unused-parameter',
'-Wnon-virtual-dtor', '-Woverloaded-virtual' ],
'defines': ['ENABLE_GDB_JIT_INTERFACE',],
}],
['OS=="android"', {
'variables': {
Expand Down
2 changes: 1 addition & 1 deletion include/v8.h
Expand Up @@ -4066,7 +4066,7 @@ class Internals {
static const int kNullValueRootIndex = 7;
static const int kTrueValueRootIndex = 8;
static const int kFalseValueRootIndex = 9;
static const int kEmptySymbolRootIndex = 116;
static const int kEmptySymbolRootIndex = 117;

static const int kJSObjectType = 0xaa;
static const int kFirstNonstringType = 0x80;
Expand Down
74 changes: 29 additions & 45 deletions src/accessors.cc
Expand Up @@ -42,15 +42,11 @@ namespace internal {


template <class C>
static C* FindInPrototypeChain(Object* obj, bool* found_it) {
ASSERT(!*found_it);
Heap* heap = HEAP;
while (!Is<C>(obj)) {
if (obj == heap->null_value()) return NULL;
obj = obj->GetPrototype();
static C* FindInstanceOf(Object* obj) {
for (Object* cur = obj; !cur->IsNull(); cur = cur->GetPrototype()) {
if (Is<C>(cur)) return C::cast(cur);
}
*found_it = true;
return C::cast(obj);
return NULL;
}


Expand Down Expand Up @@ -81,10 +77,8 @@ MaybeObject* Accessors::ReadOnlySetAccessor(JSObject*, Object* value, void*) {

MaybeObject* Accessors::ArrayGetLength(Object* object, void*) {
// Traverse the prototype chain until we reach an array.
bool found_it = false;
JSArray* holder = FindInPrototypeChain<JSArray>(object, &found_it);
if (!found_it) return Smi::FromInt(0);
return holder->length();
JSArray* holder = FindInstanceOf<JSArray>(object);
return holder == NULL ? Smi::FromInt(0) : holder->length();
}


Expand Down Expand Up @@ -448,15 +442,12 @@ const AccessorDescriptor Accessors::ScriptEvalFromFunctionName = {

MaybeObject* Accessors::FunctionGetPrototype(Object* object, void*) {
Heap* heap = Isolate::Current()->heap();
bool found_it = false;
JSFunction* function = FindInPrototypeChain<JSFunction>(object, &found_it);
if (!found_it) return heap->undefined_value();
JSFunction* function = FindInstanceOf<JSFunction>(object);
if (function == NULL) return heap->undefined_value();
while (!function->should_have_prototype()) {
found_it = false;
function = FindInPrototypeChain<JSFunction>(object->GetPrototype(),
&found_it);
function = FindInstanceOf<JSFunction>(function->GetPrototype());
// There has to be one because we hit the getter.
ASSERT(found_it);
ASSERT(function != NULL);
}

if (!function->has_prototype()) {
Expand All @@ -477,9 +468,8 @@ MaybeObject* Accessors::FunctionSetPrototype(JSObject* object,
Object* value,
void*) {
Heap* heap = object->GetHeap();
bool found_it = false;
JSFunction* function = FindInPrototypeChain<JSFunction>(object, &found_it);
if (!found_it) return heap->undefined_value();
JSFunction* function = FindInstanceOf<JSFunction>(object);
if (function == NULL) return heap->undefined_value();
if (!function->should_have_prototype()) {
// Since we hit this accessor, object will have no prototype property.
return object->SetLocalPropertyIgnoreAttributes(heap->prototype_symbol(),
Expand Down Expand Up @@ -509,22 +499,20 @@ const AccessorDescriptor Accessors::FunctionPrototype = {


MaybeObject* Accessors::FunctionGetLength(Object* object, void*) {
bool found_it = false;
JSFunction* function = FindInPrototypeChain<JSFunction>(object, &found_it);
if (!found_it) return Smi::FromInt(0);
JSFunction* function = FindInstanceOf<JSFunction>(object);
if (function == NULL) return Smi::FromInt(0);
// Check if already compiled.
if (!function->shared()->is_compiled()) {
// If the function isn't compiled yet, the length is not computed
// correctly yet. Compile it now and return the right length.
HandleScope scope;
Handle<JSFunction> handle(function);
if (!JSFunction::CompileLazy(handle, KEEP_EXCEPTION)) {
return Failure::Exception();
}
return Smi::FromInt(handle->shared()->length());
} else {
if (function->shared()->is_compiled()) {
return Smi::FromInt(function->shared()->length());
}
// If the function isn't compiled yet, the length is not computed correctly
// yet. Compile it now and return the right length.
HandleScope scope;
Handle<JSFunction> handle(function);
if (JSFunction::CompileLazy(handle, KEEP_EXCEPTION)) {
return Smi::FromInt(handle->shared()->length());
}
return Failure::Exception();
}


Expand All @@ -541,10 +529,8 @@ const AccessorDescriptor Accessors::FunctionLength = {


MaybeObject* Accessors::FunctionGetName(Object* object, void*) {
bool found_it = false;
JSFunction* holder = FindInPrototypeChain<JSFunction>(object, &found_it);
if (!found_it) return HEAP->undefined_value();
return holder->shared()->name();
JSFunction* holder = FindInstanceOf<JSFunction>(object);
return holder == NULL ? HEAP->undefined_value() : holder->shared()->name();
}


Expand Down Expand Up @@ -589,9 +575,8 @@ static MaybeObject* ConstructArgumentsObjectForInlinedFunction(
MaybeObject* Accessors::FunctionGetArguments(Object* object, void*) {
Isolate* isolate = Isolate::Current();
HandleScope scope(isolate);
bool found_it = false;
JSFunction* holder = FindInPrototypeChain<JSFunction>(object, &found_it);
if (!found_it) return isolate->heap()->undefined_value();
JSFunction* holder = FindInstanceOf<JSFunction>(object);
if (holder == NULL) return isolate->heap()->undefined_value();
Handle<JSFunction> function(holder, isolate);

if (function->shared()->native()) return isolate->heap()->null_value();
Expand Down Expand Up @@ -727,9 +712,8 @@ MaybeObject* Accessors::FunctionGetCaller(Object* object, void*) {
Isolate* isolate = Isolate::Current();
HandleScope scope(isolate);
AssertNoAllocation no_alloc;
bool found_it = false;
JSFunction* holder = FindInPrototypeChain<JSFunction>(object, &found_it);
if (!found_it) return isolate->heap()->undefined_value();
JSFunction* holder = FindInstanceOf<JSFunction>(object);
if (holder == NULL) return isolate->heap()->undefined_value();
if (holder->shared()->native()) return isolate->heap()->null_value();
Handle<JSFunction> function(holder, isolate);

Expand Down

0 comments on commit b4befaf

Please sign in to comment.