Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(318)

Unified Diff: src/x64/lithium-x64.cc

Issue 6113004: Version 3.0.7 (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/x64/lithium-x64.h ('k') | src/x64/macro-assembler-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/x64/lithium-x64.cc
diff --git a/test/mjsunit/bugs/bug-1015.js b/src/x64/lithium-x64.cc
similarity index 53%
copy from test/mjsunit/bugs/bug-1015.js
copy to src/x64/lithium-x64.cc
index 9e4406a9aabade1fa40dd13bd439a1d395dbe5cd..8afa9d47edf086bbea10a346ef99dd8f0db1aa1b 100644
--- a/test/mjsunit/bugs/bug-1015.js
+++ b/src/x64/lithium-x64.cc
@@ -1,4 +1,4 @@
-// Copyright 2010 the V8 project authors. All rights reserved.
+// Copyright 2011 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:
@@ -25,42 +25,47 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// See: http://code.google.com/p/v8/issues/detail?id=1015
+#include "x64/lithium-x64.h"
+#include "x64/lithium-codegen-x64.h"
-// Object and array literals should be created using DefineOwnProperty, and
-// therefore not hit setters in the prototype.
+namespace v8 {
+namespace internal {
-function mkFail(message) {
- return function () { assertUnreachable(message); }
+LChunk* LChunkBuilder::Build() {
+ ASSERT(is_unused());
+ chunk_ = new LChunk(graph());
+ HPhase phase("Building chunk", chunk_);
+ status_ = BUILDING;
+ const ZoneList<HBasicBlock*>* blocks = graph()->blocks();
+ for (int i = 0; i < blocks->length(); i++) {
+ HBasicBlock* next = NULL;
+ if (i < blocks->length() - 1) next = blocks->at(i + 1);
+ DoBasicBlock(blocks->at(i), next);
+ if (is_aborted()) return NULL;
+ }
+ status_ = DONE;
+ return chunk_;
}
-Object.defineProperty(Object.prototype, "foo",
- {get: mkFail("oget"), set: mkFail("oset")});
-Object.defineProperty(Array.prototype, "2",
- {get: mkFail("aget"), set: mkFail("aset")});
-function inFunction() {
- for (var i = 0; i < 10; i++) {
- // in loop.
- var ja = JSON.parse('[1,2,3,4]');
- var jo = JSON.parse('{"bar": 10, "foo": 20}')
- var jop = JSON.parse('{"bar": 10, "__proto__": { }, "foo": 20}')
- var a = [1,2,3,4];
- var o = { bar: 10, foo: 20 };
- var op = { __proto__: { set bar(v) { assertUnreachable("bset"); } },
- bar: 10 };
+void LChunkBuilder::Abort(const char* format, ...) {
+ if (FLAG_trace_bailout) {
+ SmartPointer<char> debug_name = graph()->debug_name()->ToCString();
+ PrintF("Aborting LChunk building in @\"%s\": ", *debug_name);
+ va_list arguments;
+ va_start(arguments, format);
+ OS::VPrint(format, arguments);
+ va_end(arguments);
+ PrintF("\n");
}
+ status_ = ABORTED;
}
-for (var i = 0; i < 10; i++) {
- // In global scope.
- var ja = JSON.parse('[1,2,3,4]');
- var jo = JSON.parse('{"bar": 10, "foo": 20}')
- var jop = JSON.parse('{"bar": 10, "__proto__": { }, "foo": 20}')
- var a = [1,2,3,4];
- var o = { bar: 10, foo: 20 };
- var op = { __proto__: { set bar(v) { assertUnreachable("bset"); } },
- bar: 10 };
- // In function scope.
- inFunction();
+
+void LChunkBuilder::DoBasicBlock(HBasicBlock* block, HBasicBlock* next_block) {
+ ASSERT(is_building());
+ Abort("Lithium not implemented on x64.");
}
+
+
+} } // namespace v8::internal
« no previous file with comments | « src/x64/lithium-x64.h ('k') | src/x64/macro-assembler-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698