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

Side by Side Diff: src/objects.h

Issue 650058: Improve string runtime compare performance for flat strings. (Closed)
Patch Set: Created 10 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 | « no previous file | src/runtime.cc » ('j') | src/runtime.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 4033 matching lines...) Expand 10 before | Expand all | Expand 10 after
4044 }; 4044 };
4045 4045
4046 4046
4047 // The SeqString abstract class captures sequential string values. 4047 // The SeqString abstract class captures sequential string values.
4048 class SeqString: public String { 4048 class SeqString: public String {
4049 public: 4049 public:
4050 4050
4051 // Casting. 4051 // Casting.
4052 static inline SeqString* cast(Object* obj); 4052 static inline SeqString* cast(Object* obj);
4053 4053
4054 // Dispatched behaviour.
4055 // For regexp code.
4056 uint16_t* SeqStringGetTwoByteAddress();
4057
4058 private: 4054 private:
4059 DISALLOW_IMPLICIT_CONSTRUCTORS(SeqString); 4055 DISALLOW_IMPLICIT_CONSTRUCTORS(SeqString);
4060 }; 4056 };
4061 4057
4062 4058
4063 // The AsciiString class captures sequential ascii string objects. 4059 // The AsciiString class captures sequential ascii string objects.
4064 // Each character in the AsciiString is an ascii character. 4060 // Each character in the AsciiString is an ascii character.
4065 class SeqAsciiString: public SeqString { 4061 class SeqAsciiString: public SeqString {
4066 public: 4062 public:
4067 // Dispatched behavior. 4063 // Dispatched behavior.
(...skipping 912 matching lines...) Expand 10 before | Expand all | Expand 10 after
4980 } else { 4976 } else {
4981 value &= ~(1 << bit_position); 4977 value &= ~(1 << bit_position);
4982 } 4978 }
4983 return value; 4979 return value;
4984 } 4980 }
4985 }; 4981 };
4986 4982
4987 } } // namespace v8::internal 4983 } } // namespace v8::internal
4988 4984
4989 #endif // V8_OBJECTS_H_ 4985 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « no previous file | src/runtime.cc » ('j') | src/runtime.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698