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

Side by Side Diff: src/assembler.h

Issue 874323003: Externalize deoptimization reasons. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: minor change Created 5 years, 10 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
« no previous file with comments | « src/arm64/lithium-codegen-arm64.cc ('k') | src/assembler.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 347 matching lines...) Expand 10 before | Expand all | Expand 10 after
358 static const int kMaxCallSize = 6; 358 static const int kMaxCallSize = 6;
359 359
360 // The maximum pc delta that will use the short encoding. 360 // The maximum pc delta that will use the short encoding.
361 static const int kMaxSmallPCDelta; 361 static const int kMaxSmallPCDelta;
362 362
363 enum Mode { 363 enum Mode {
364 // Please note the order is important (see IsCodeTarget, IsGCRelocMode). 364 // Please note the order is important (see IsCodeTarget, IsGCRelocMode).
365 CODE_TARGET, // Code target which is not any of the above. 365 CODE_TARGET, // Code target which is not any of the above.
366 CODE_TARGET_WITH_ID, 366 CODE_TARGET_WITH_ID,
367 CONSTRUCT_CALL, // code target that is a call to a JavaScript constructor. 367 CONSTRUCT_CALL, // code target that is a call to a JavaScript constructor.
368 DEBUG_BREAK, // Code target for the debugger statement. 368 DEBUG_BREAK, // Code target for the debugger statement.
369 EMBEDDED_OBJECT, 369 EMBEDDED_OBJECT,
370 CELL, 370 CELL,
371 371
372 // Everything after runtime_entry (inclusive) is not GC'ed. 372 // Everything after runtime_entry (inclusive) is not GC'ed.
373 RUNTIME_ENTRY, 373 RUNTIME_ENTRY,
374 JS_RETURN, // Marks start of the ExitJSFrame code. 374 JS_RETURN, // Marks start of the ExitJSFrame code.
375 COMMENT, 375 COMMENT,
376 POSITION, // See comment for kNoPosition above. 376 POSITION, // See comment for kNoPosition above.
377 STATEMENT_POSITION, // See comment for kNoPosition above. 377 STATEMENT_POSITION, // See comment for kNoPosition above.
378 DEBUG_BREAK_SLOT, // Additional code inserted for debug break slot. 378 DEBUG_BREAK_SLOT, // Additional code inserted for debug break slot.
379 EXTERNAL_REFERENCE, // The address of an external C++ function. 379 EXTERNAL_REFERENCE, // The address of an external C++ function.
380 INTERNAL_REFERENCE, // An address inside the same function. 380 INTERNAL_REFERENCE, // An address inside the same function.
381 381
382 // Marks constant and veneer pools. Only used on ARM and ARM64. 382 // Marks constant and veneer pools. Only used on ARM and ARM64.
383 // They use a custom noncompact encoding. 383 // They use a custom noncompact encoding.
384 CONST_POOL, 384 CONST_POOL,
385 VENEER_POOL, 385 VENEER_POOL,
386 386
387 DEOPT_REASON, // Deoptimization reason index.
388
387 // add more as needed 389 // add more as needed
388 // Pseudo-types 390 // Pseudo-types
389 NUMBER_OF_MODES, // There are at most 15 modes with noncompact encoding. 391 NUMBER_OF_MODES, // There are at most 15 modes with noncompact encoding.
390 NONE32, // never recorded 32-bit value 392 NONE32, // never recorded 32-bit value
391 NONE64, // never recorded 64-bit value 393 NONE64, // never recorded 64-bit value
392 CODE_AGE_SEQUENCE, // Not stored in RelocInfo array, used explictly by 394 CODE_AGE_SEQUENCE, // Not stored in RelocInfo array, used explictly by
393 // code aging. 395 // code aging.
394 FIRST_REAL_RELOC_MODE = CODE_TARGET, 396 FIRST_REAL_RELOC_MODE = CODE_TARGET,
395 LAST_REAL_RELOC_MODE = VENEER_POOL, 397 LAST_REAL_RELOC_MODE = VENEER_POOL,
396 FIRST_PSEUDO_RELOC_MODE = CODE_AGE_SEQUENCE, 398 FIRST_PSEUDO_RELOC_MODE = CODE_AGE_SEQUENCE,
397 LAST_PSEUDO_RELOC_MODE = CODE_AGE_SEQUENCE, 399 LAST_PSEUDO_RELOC_MODE = CODE_AGE_SEQUENCE,
398 LAST_CODE_ENUM = DEBUG_BREAK, 400 LAST_CODE_ENUM = DEBUG_BREAK,
399 LAST_GCED_ENUM = CELL, 401 LAST_GCED_ENUM = CELL,
400 // Modes <= LAST_COMPACT_ENUM are guaranteed to have compact encoding. 402 // Modes <= LAST_COMPACT_ENUM are guaranteed to have compact encoding.
401 LAST_COMPACT_ENUM = CODE_TARGET_WITH_ID, 403 LAST_COMPACT_ENUM = CODE_TARGET_WITH_ID,
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
726 void ReadTaggedPC(); 728 void ReadTaggedPC();
727 void AdvanceReadPC(); 729 void AdvanceReadPC();
728 void AdvanceReadId(); 730 void AdvanceReadId();
729 void AdvanceReadPoolData(); 731 void AdvanceReadPoolData();
730 void AdvanceReadPosition(); 732 void AdvanceReadPosition();
731 void AdvanceReadData(); 733 void AdvanceReadData();
732 void AdvanceReadVariableLengthPCJump(); 734 void AdvanceReadVariableLengthPCJump();
733 int GetLocatableTypeTag(); 735 int GetLocatableTypeTag();
734 void ReadTaggedId(); 736 void ReadTaggedId();
735 void ReadTaggedPosition(); 737 void ReadTaggedPosition();
738 void ReadTaggedData();
736 739
737 // If the given mode is wanted, set it in rinfo_ and return true. 740 // If the given mode is wanted, set it in rinfo_ and return true.
738 // Else return false. Used for efficiently skipping unwanted modes. 741 // Else return false. Used for efficiently skipping unwanted modes.
739 bool SetMode(RelocInfo::Mode mode) { 742 bool SetMode(RelocInfo::Mode mode) {
740 return (mode_mask_ & (1 << mode)) ? (rinfo_.rmode_ = mode, true) : false; 743 return (mode_mask_ & (1 << mode)) ? (rinfo_.rmode_ = mode, true) : false;
741 } 744 }
742 745
743 byte* pos_; 746 byte* pos_;
744 byte* end_; 747 byte* end_;
745 byte* code_age_sequence_; 748 byte* code_age_sequence_;
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
1129 NullCallWrapper() { } 1132 NullCallWrapper() { }
1130 virtual ~NullCallWrapper() { } 1133 virtual ~NullCallWrapper() { }
1131 virtual void BeforeCall(int call_size) const { } 1134 virtual void BeforeCall(int call_size) const { }
1132 virtual void AfterCall() const { } 1135 virtual void AfterCall() const { }
1133 }; 1136 };
1134 1137
1135 1138
1136 } } // namespace v8::internal 1139 } } // namespace v8::internal
1137 1140
1138 #endif // V8_ASSEMBLER_H_ 1141 #endif // V8_ASSEMBLER_H_
OLDNEW
« no previous file with comments | « src/arm64/lithium-codegen-arm64.cc ('k') | src/assembler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698