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

Side by Side Diff: src/compiler/js-generic-lowering.cc

Issue 523633002: Fix typed lowering of JSUnaryNot to work with graph reducer. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/code-stubs.h" 5 #include "src/code-stubs.h"
6 #include "src/compiler/common-operator.h" 6 #include "src/compiler/common-operator.h"
7 #include "src/compiler/graph-inl.h" 7 #include "src/compiler/graph-inl.h"
8 #include "src/compiler/js-generic-lowering.h" 8 #include "src/compiler/js-generic-lowering.h"
9 #include "src/compiler/machine-operator.h" 9 #include "src/compiler/machine-operator.h"
10 #include "src/compiler/node-aux-data-inl.h" 10 #include "src/compiler/node-aux-data-inl.h"
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 REPLACE_RUNTIME_CALL(JSCreateModuleContext, Runtime::kPushModuleContext) 279 REPLACE_RUNTIME_CALL(JSCreateModuleContext, Runtime::kPushModuleContext)
280 REPLACE_RUNTIME_CALL(JSCreateGlobalContext, Runtime::kAbort) 280 REPLACE_RUNTIME_CALL(JSCreateGlobalContext, Runtime::kAbort)
281 #undef REPLACE_RUNTIME 281 #undef REPLACE_RUNTIME
282 282
283 283
284 #define REPLACE_UNIMPLEMENTED(op) \ 284 #define REPLACE_UNIMPLEMENTED(op) \
285 Node* JSGenericLowering::Lower##op(Node* node) { \ 285 Node* JSGenericLowering::Lower##op(Node* node) { \
286 UNIMPLEMENTED(); \ 286 UNIMPLEMENTED(); \
287 return node; \ 287 return node; \
288 } 288 }
289 REPLACE_UNIMPLEMENTED(JSToString)
290 REPLACE_UNIMPLEMENTED(JSToName) 289 REPLACE_UNIMPLEMENTED(JSToName)
291 REPLACE_UNIMPLEMENTED(JSYield) 290 REPLACE_UNIMPLEMENTED(JSYield)
292 REPLACE_UNIMPLEMENTED(JSDebugger) 291 REPLACE_UNIMPLEMENTED(JSDebugger)
293 #undef REPLACE_UNIMPLEMENTED 292 #undef REPLACE_UNIMPLEMENTED
294 293
295 294
296 static CallDescriptor::Flags FlagsForNode(Node* node) { 295 static CallDescriptor::Flags FlagsForNode(Node* node) {
297 CallDescriptor::Flags result = CallDescriptor::kNoFlags; 296 CallDescriptor::Flags result = CallDescriptor::kNoFlags;
298 if (OperatorProperties::CanLazilyDeoptimize(node->op())) { 297 if (OperatorProperties::CanLazilyDeoptimize(node->op())) {
299 result |= CallDescriptor::kLazyDeoptimization; 298 result |= CallDescriptor::kLazyDeoptimization;
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
404 } 403 }
405 404
406 405
407 Node* JSGenericLowering::LowerJSToBoolean(Node* node) { 406 Node* JSGenericLowering::LowerJSToBoolean(Node* node) {
408 ToBooleanStub stub(isolate(), ToBooleanStub::RESULT_AS_ODDBALL); 407 ToBooleanStub stub(isolate(), ToBooleanStub::RESULT_AS_ODDBALL);
409 ReplaceWithStubCall(node, &stub, CallDescriptor::kPatchableCallSite); 408 ReplaceWithStubCall(node, &stub, CallDescriptor::kPatchableCallSite);
410 return node; 409 return node;
411 } 410 }
412 411
413 412
413 Node* JSGenericLowering::LowerJSToString(Node* node) {
414 ReplaceWithBuiltinCall(node, Builtins::TO_STRING, 1);
415 return node;
416 }
417
418
414 Node* JSGenericLowering::LowerJSToObject(Node* node) { 419 Node* JSGenericLowering::LowerJSToObject(Node* node) {
415 ReplaceWithBuiltinCall(node, Builtins::TO_OBJECT, 1); 420 ReplaceWithBuiltinCall(node, Builtins::TO_OBJECT, 1);
416 return node; 421 return node;
417 } 422 }
418 423
419 424
420 Node* JSGenericLowering::LowerJSLoadProperty(Node* node) { 425 Node* JSGenericLowering::LowerJSLoadProperty(Node* node) {
421 KeyedLoadICStubShim stub(isolate()); 426 KeyedLoadICStubShim stub(isolate());
422 ReplaceWithStubCall(node, &stub, CallDescriptor::kPatchableCallSite); 427 ReplaceWithStubCall(node, &stub, CallDescriptor::kPatchableCallSite);
423 return node; 428 return node;
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
548 Node* JSGenericLowering::LowerJSCallRuntime(Node* node) { 553 Node* JSGenericLowering::LowerJSCallRuntime(Node* node) {
549 Runtime::FunctionId function = OpParameter<Runtime::FunctionId>(node); 554 Runtime::FunctionId function = OpParameter<Runtime::FunctionId>(node);
550 int arity = OperatorProperties::GetValueInputCount(node->op()); 555 int arity = OperatorProperties::GetValueInputCount(node->op());
551 ReplaceWithRuntimeCall(node, function, arity); 556 ReplaceWithRuntimeCall(node, function, arity);
552 return node; 557 return node;
553 } 558 }
554 559
555 } // namespace compiler 560 } // namespace compiler
556 } // namespace internal 561 } // namespace internal
557 } // namespace v8 562 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/compiler/js-typed-lowering.cc » ('j') | test/cctest/compiler/test-js-typed-lowering.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698