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

Side by Side Diff: src/compiler/js-operator.h

Issue 2035383003: [turbofan] Type feedback for numeric comparisons. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fixes Created 4 years, 6 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
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 #ifndef V8_COMPILER_JS_OPERATOR_H_ 5 #ifndef V8_COMPILER_JS_OPERATOR_H_
6 #define V8_COMPILER_JS_OPERATOR_H_ 6 #define V8_COMPILER_JS_OPERATOR_H_
7 7
8 #include "src/compiler/type-hints.h" 8 #include "src/compiler/type-hints.h"
9 #include "src/runtime/runtime.h" 9 #include "src/runtime/runtime.h"
10 10
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 bool operator!=(CreateLiteralParameters const&, CreateLiteralParameters const&); 369 bool operator!=(CreateLiteralParameters const&, CreateLiteralParameters const&);
370 370
371 size_t hash_value(CreateLiteralParameters const&); 371 size_t hash_value(CreateLiteralParameters const&);
372 372
373 std::ostream& operator<<(std::ostream&, CreateLiteralParameters const&); 373 std::ostream& operator<<(std::ostream&, CreateLiteralParameters const&);
374 374
375 const CreateLiteralParameters& CreateLiteralParametersOf(const Operator* op); 375 const CreateLiteralParameters& CreateLiteralParametersOf(const Operator* op);
376 376
377 const BinaryOperationHints& BinaryOperationHintsOf(const Operator* op); 377 const BinaryOperationHints& BinaryOperationHintsOf(const Operator* op);
378 378
379 const CompareOperationHints& CompareOperationHintsOf(const Operator* op);
380
379 // Interface for building JavaScript-level operators, e.g. directly from the 381 // Interface for building JavaScript-level operators, e.g. directly from the
380 // AST. Most operators have no parameters, thus can be globally shared for all 382 // AST. Most operators have no parameters, thus can be globally shared for all
381 // graphs. 383 // graphs.
382 class JSOperatorBuilder final : public ZoneObject { 384 class JSOperatorBuilder final : public ZoneObject {
383 public: 385 public:
384 explicit JSOperatorBuilder(Zone* zone); 386 explicit JSOperatorBuilder(Zone* zone);
385 387
386 const Operator* Equal(); 388 const Operator* Equal(CompareOperationHints hints);
387 const Operator* NotEqual(); 389 const Operator* NotEqual(CompareOperationHints hints);
388 const Operator* StrictEqual(); 390 const Operator* StrictEqual(CompareOperationHints hints);
389 const Operator* StrictNotEqual(); 391 const Operator* StrictNotEqual(CompareOperationHints hints);
390 const Operator* LessThan(); 392 const Operator* LessThan(CompareOperationHints hints);
391 const Operator* GreaterThan(); 393 const Operator* GreaterThan(CompareOperationHints hints);
392 const Operator* LessThanOrEqual(); 394 const Operator* LessThanOrEqual(CompareOperationHints hints);
393 const Operator* GreaterThanOrEqual(); 395 const Operator* GreaterThanOrEqual(CompareOperationHints hints);
394 const Operator* BitwiseOr(BinaryOperationHints hints); 396 const Operator* BitwiseOr(BinaryOperationHints hints);
395 const Operator* BitwiseXor(BinaryOperationHints hints); 397 const Operator* BitwiseXor(BinaryOperationHints hints);
396 const Operator* BitwiseAnd(BinaryOperationHints hints); 398 const Operator* BitwiseAnd(BinaryOperationHints hints);
397 const Operator* ShiftLeft(BinaryOperationHints hints); 399 const Operator* ShiftLeft(BinaryOperationHints hints);
398 const Operator* ShiftRight(BinaryOperationHints hints); 400 const Operator* ShiftRight(BinaryOperationHints hints);
399 const Operator* ShiftRightLogical(BinaryOperationHints hints); 401 const Operator* ShiftRightLogical(BinaryOperationHints hints);
400 const Operator* Add(BinaryOperationHints hints); 402 const Operator* Add(BinaryOperationHints hints);
401 const Operator* Subtract(BinaryOperationHints hints); 403 const Operator* Subtract(BinaryOperationHints hints);
402 const Operator* Multiply(BinaryOperationHints hints); 404 const Operator* Multiply(BinaryOperationHints hints);
403 const Operator* Divide(BinaryOperationHints hints); 405 const Operator* Divide(BinaryOperationHints hints);
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
440 const Operator* LoadProperty(VectorSlotPair const& feedback); 442 const Operator* LoadProperty(VectorSlotPair const& feedback);
441 const Operator* LoadNamed(Handle<Name> name, VectorSlotPair const& feedback); 443 const Operator* LoadNamed(Handle<Name> name, VectorSlotPair const& feedback);
442 444
443 const Operator* StoreProperty(LanguageMode language_mode, 445 const Operator* StoreProperty(LanguageMode language_mode,
444 VectorSlotPair const& feedback); 446 VectorSlotPair const& feedback);
445 const Operator* StoreNamed(LanguageMode language_mode, Handle<Name> name, 447 const Operator* StoreNamed(LanguageMode language_mode, Handle<Name> name,
446 VectorSlotPair const& feedback); 448 VectorSlotPair const& feedback);
447 449
448 const Operator* DeleteProperty(LanguageMode language_mode); 450 const Operator* DeleteProperty(LanguageMode language_mode);
449 451
450 const Operator* HasProperty(); 452 const Operator* HasProperty(CompareOperationHints hints);
451 453
452 const Operator* LoadGlobal(const Handle<Name>& name, 454 const Operator* LoadGlobal(const Handle<Name>& name,
453 const VectorSlotPair& feedback, 455 const VectorSlotPair& feedback,
454 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF); 456 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF);
455 const Operator* StoreGlobal(LanguageMode language_mode, 457 const Operator* StoreGlobal(LanguageMode language_mode,
456 const Handle<Name>& name, 458 const Handle<Name>& name,
457 const VectorSlotPair& feedback); 459 const VectorSlotPair& feedback);
458 460
459 const Operator* LoadContext(size_t depth, size_t index, bool immutable); 461 const Operator* LoadContext(size_t depth, size_t index, bool immutable);
460 const Operator* StoreContext(size_t depth, size_t index); 462 const Operator* StoreContext(size_t depth, size_t index);
461 463
462 const Operator* TypeOf(); 464 const Operator* TypeOf();
463 const Operator* InstanceOf(); 465 const Operator* InstanceOf(CompareOperationHints hints);
464 466
465 const Operator* ForInDone(); 467 const Operator* ForInDone();
466 const Operator* ForInNext(); 468 const Operator* ForInNext();
467 const Operator* ForInPrepare(); 469 const Operator* ForInPrepare();
468 const Operator* ForInStep(); 470 const Operator* ForInStep();
469 471
470 const Operator* LoadMessage(); 472 const Operator* LoadMessage();
471 const Operator* StoreMessage(); 473 const Operator* StoreMessage();
472 474
473 // Used to implement Ignition's SuspendGenerator bytecode. 475 // Used to implement Ignition's SuspendGenerator bytecode.
(...skipping 19 matching lines...) Expand all
493 Zone* const zone_; 495 Zone* const zone_;
494 496
495 DISALLOW_COPY_AND_ASSIGN(JSOperatorBuilder); 497 DISALLOW_COPY_AND_ASSIGN(JSOperatorBuilder);
496 }; 498 };
497 499
498 } // namespace compiler 500 } // namespace compiler
499 } // namespace internal 501 } // namespace internal
500 } // namespace v8 502 } // namespace v8
501 503
502 #endif // V8_COMPILER_JS_OPERATOR_H_ 504 #endif // V8_COMPILER_JS_OPERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698