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

Side by Side Diff: src/objects.h

Issue 2087009: Custom call IC-s for String.prototype.{charAt,charCodeAt}. (Closed)
Patch Set: ARM port. Created 10 years, 7 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 2006-2009 the V8 project authors. All rights reserved. 1 // Copyright 2006-2009 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 392 matching lines...) Expand 10 before | Expand all | Expand 10 after
403 const uint32_t kAsciiStringTag = 0x4; 403 const uint32_t kAsciiStringTag = 0x4;
404 404
405 // If bit 7 is clear, the low-order 2 bits indicate the representation 405 // If bit 7 is clear, the low-order 2 bits indicate the representation
406 // of the string. 406 // of the string.
407 const uint32_t kStringRepresentationMask = 0x03; 407 const uint32_t kStringRepresentationMask = 0x03;
408 enum StringRepresentationTag { 408 enum StringRepresentationTag {
409 kSeqStringTag = 0x0, 409 kSeqStringTag = 0x0,
410 kConsStringTag = 0x1, 410 kConsStringTag = 0x1,
411 kExternalStringTag = 0x3 411 kExternalStringTag = 0x3
412 }; 412 };
413 const uint32_t kIsConsStringMask = 0x1;
413 414
414 415
415 // A ConsString with an empty string as the right side is a candidate 416 // A ConsString with an empty string as the right side is a candidate
416 // for being shortcut by the garbage collector unless it is a 417 // for being shortcut by the garbage collector unless it is a
417 // symbol. It's not common to have non-flat symbols, so we do not 418 // symbol. It's not common to have non-flat symbols, so we do not
418 // shortcut them thereby avoiding turning symbols into strings. See 419 // shortcut them thereby avoiding turning symbols into strings. See
419 // heap.cc and mark-compact.cc. 420 // heap.cc and mark-compact.cc.
420 const uint32_t kShortcutTypeMask = 421 const uint32_t kShortcutTypeMask =
421 kIsNotStringMask | 422 kIsNotStringMask |
422 kIsSymbolMask | 423 kIsSymbolMask |
(...skipping 4828 matching lines...) Expand 10 before | Expand all | Expand 10 after
5251 } else { 5252 } else {
5252 value &= ~(1 << bit_position); 5253 value &= ~(1 << bit_position);
5253 } 5254 }
5254 return value; 5255 return value;
5255 } 5256 }
5256 }; 5257 };
5257 5258
5258 } } // namespace v8::internal 5259 } } // namespace v8::internal
5259 5260
5260 #endif // V8_OBJECTS_H_ 5261 #endif // V8_OBJECTS_H_
OLDNEW
« src/codegen.h ('K') | « src/jump-target-light.cc ('k') | src/string.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698