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

Unified Diff: src/property-details.h

Issue 25696004: Add support to load/store byte fields. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Also adjust HLoadNamedField::InferRange. Created 7 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: src/property-details.h
diff --git a/src/property-details.h b/src/property-details.h
index 7f44b79277c5188596e55b37c66eee4f02ed3199..659fbd1da6e2b5829cb0d3d5a0e4d305c106ba9b 100644
--- a/src/property-details.h
+++ b/src/property-details.h
@@ -82,6 +82,7 @@ class Representation {
public:
enum Kind {
kNone,
+ kByte,
kSmi,
kInteger32,
kDouble,
@@ -95,6 +96,7 @@ class Representation {
static Representation None() { return Representation(kNone); }
static Representation Tagged() { return Representation(kTagged); }
+ static Representation Byte() { return Representation(kByte); }
static Representation Smi() { return Representation(kSmi); }
static Representation Integer32() { return Representation(kInteger32); }
static Representation Double() { return Representation(kDouble); }
@@ -139,6 +141,7 @@ class Representation {
Kind kind() const { return static_cast<Kind>(kind_); }
bool IsNone() const { return kind_ == kNone; }
+ bool IsByte() const { return kind_ == kByte; }
bool IsTagged() const { return kind_ == kTagged; }
bool IsSmi() const { return kind_ == kSmi; }
bool IsSmiOrTagged() const { return IsSmi() || IsTagged(); }
@@ -148,7 +151,7 @@ class Representation {
bool IsHeapObject() const { return kind_ == kHeapObject; }
bool IsExternal() const { return kind_ == kExternal; }
bool IsSpecialization() const {
- return kind_ == kInteger32 || kind_ == kDouble || kind_ == kSmi;
+ return IsByte() || IsSmi() || IsInteger32() || IsDouble();
}
const char* Mnemonic() const;

Powered by Google App Engine
This is Rietveld 408576698