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

Side by Side Diff: src/objects.h

Issue 75973005: Remove unused StubType's, freeing 2 bits in Code objects. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 1 month 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
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/objects.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 5015 matching lines...) Expand 10 before | Expand all | Expand 10 after
5026 5026
5027 // No more than 16 kinds. The value is currently encoded in four bits in 5027 // No more than 16 kinds. The value is currently encoded in four bits in
5028 // Flags. 5028 // Flags.
5029 STATIC_ASSERT(NUMBER_OF_KINDS <= 16); 5029 STATIC_ASSERT(NUMBER_OF_KINDS <= 16);
5030 5030
5031 static const char* Kind2String(Kind kind); 5031 static const char* Kind2String(Kind kind);
5032 5032
5033 // Types of stubs. 5033 // Types of stubs.
5034 enum StubType { 5034 enum StubType {
5035 NORMAL, 5035 NORMAL,
5036 FIELD, 5036 FAST
5037 CONSTANT,
5038 CALLBACKS,
5039 INTERCEPTOR,
5040 TRANSITION,
5041 NONEXISTENT
5042 }; 5037 };
5043 5038
5044 typedef int ExtraICState; 5039 typedef int ExtraICState;
5045 5040
5046 static const ExtraICState kNoExtraICState = 0; 5041 static const ExtraICState kNoExtraICState = 0;
5047 5042
5048 static const int kPrologueOffsetNotSet = -1; 5043 static const int kPrologueOffsetNotSet = -1;
5049 5044
5050 #ifdef ENABLE_DISASSEMBLER 5045 #ifdef ENABLE_DISASSEMBLER
5051 // Printing 5046 // Printing
(...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after
5457 class FullCodeFlagsHasDeoptimizationSupportField: 5452 class FullCodeFlagsHasDeoptimizationSupportField:
5458 public BitField<bool, 0, 1> {}; // NOLINT 5453 public BitField<bool, 0, 1> {}; // NOLINT
5459 class FullCodeFlagsHasDebugBreakSlotsField: public BitField<bool, 1, 1> {}; 5454 class FullCodeFlagsHasDebugBreakSlotsField: public BitField<bool, 1, 1> {};
5460 class FullCodeFlagsIsCompiledOptimizable: public BitField<bool, 2, 1> {}; 5455 class FullCodeFlagsIsCompiledOptimizable: public BitField<bool, 2, 1> {};
5461 5456
5462 static const int kAllowOSRAtLoopNestingLevelOffset = kFullCodeFlags + 1; 5457 static const int kAllowOSRAtLoopNestingLevelOffset = kFullCodeFlags + 1;
5463 static const int kProfilerTicksOffset = kAllowOSRAtLoopNestingLevelOffset + 1; 5458 static const int kProfilerTicksOffset = kAllowOSRAtLoopNestingLevelOffset + 1;
5464 5459
5465 // Flags layout. BitField<type, shift, size>. 5460 // Flags layout. BitField<type, shift, size>.
5466 class ICStateField: public BitField<InlineCacheState, 0, 3> {}; 5461 class ICStateField: public BitField<InlineCacheState, 0, 3> {};
5467 class TypeField: public BitField<StubType, 3, 3> {}; 5462 class TypeField: public BitField<StubType, 3, 1> {};
5468 class CacheHolderField: public BitField<InlineCacheHolderFlag, 6, 1> {}; 5463 class CacheHolderField: public BitField<InlineCacheHolderFlag, 6, 1> {};
5469 class KindField: public BitField<Kind, 7, 4> {}; 5464 class KindField: public BitField<Kind, 7, 4> {};
5470 class IsPregeneratedField: public BitField<bool, 11, 1> {}; 5465 class IsPregeneratedField: public BitField<bool, 11, 1> {};
5471 class ExtraICStateField: public BitField<ExtraICState, 12, 5> {}; 5466 class ExtraICStateField: public BitField<ExtraICState, 12, 5> {};
5472 class ExtendedExtraICStateField: public BitField<ExtraICState, 12, 5467 class ExtendedExtraICStateField: public BitField<ExtraICState, 12,
5473 PlatformSmiTagging::kSmiValueSize - 12 + 1> {}; // NOLINT 5468 PlatformSmiTagging::kSmiValueSize - 12 + 1> {}; // NOLINT
5474 STATIC_ASSERT(ExtraICStateField::kShift == ExtendedExtraICStateField::kShift); 5469 STATIC_ASSERT(ExtraICStateField::kShift == ExtendedExtraICStateField::kShift);
5475 5470
5476 // KindSpecificFlags1 layout (STUB and OPTIMIZED_FUNCTION) 5471 // KindSpecificFlags1 layout (STUB and OPTIMIZED_FUNCTION)
5477 static const int kStackSlotsFirstBit = 0; 5472 static const int kStackSlotsFirstBit = 0;
(...skipping 5092 matching lines...) Expand 10 before | Expand all | Expand 10 after
10570 } else { 10565 } else {
10571 value &= ~(1 << bit_position); 10566 value &= ~(1 << bit_position);
10572 } 10567 }
10573 return value; 10568 return value;
10574 } 10569 }
10575 }; 10570 };
10576 10571
10577 } } // namespace v8::internal 10572 } } // namespace v8::internal
10578 10573
10579 #endif // V8_OBJECTS_H_ 10574 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698