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

Unified Diff: src/ast/ast.h

Issue 2843293003: Optimized layout padding in 4 classes in ast.h (Closed)
Patch Set: Created 3 years, 8 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ast/ast.h
diff --git a/src/ast/ast.h b/src/ast/ast.h
index 9d7b4de82c5363cab8f17c42d414acd6a19ecefe..74587e52e7ad82865a0b86f61ec5e45ae86f91ae 100644
--- a/src/ast/ast.h
+++ b/src/ast/ast.h
@@ -977,11 +977,11 @@ class CaseClause final : public Expression {
CaseClause(Expression* label, ZoneList<Statement*>* statements, int pos);
int local_id(int n) const { return base_id() + parent_num_ids() + n; }
+ FeedbackSlot feedback_slot_;
Expression* label_;
Label body_target_;
ZoneList<Statement*>* statements_;
AstType* compare_type_;
- FeedbackSlot feedback_slot_;
};
@@ -2160,10 +2160,10 @@ class BinaryOperation final : public Expression {
BinaryOperation(Token::Value op, Expression* left, Expression* right, int pos)
: Expression(pos, kBinaryOperation),
- has_fixed_right_arg_(false),
- fixed_right_arg_value_(0),
left_(left),
- right_(right) {
+ right_(right),
+ has_fixed_right_arg_(false),
+ fixed_right_arg_value_(0) {
bit_field_ |= OperatorField::encode(op);
DCHECK(Token::IsBinaryOp(op));
}
@@ -2171,14 +2171,14 @@ class BinaryOperation final : public Expression {
static int parent_num_ids() { return Expression::num_ids(); }
int local_id(int n) const { return base_id() + parent_num_ids() + n; }
+ FeedbackSlot feedback_slot_;
+ Expression* left_;
+ Expression* right_;
+ Handle<AllocationSite> allocation_site_;
// TODO(rossberg): the fixed arg should probably be represented as a Constant
// type for the RHS. Currenty it's actually a Maybe<int>
bool has_fixed_right_arg_;
int fixed_right_arg_value_;
- Expression* left_;
- Expression* right_;
- Handle<AllocationSite> allocation_site_;
- FeedbackSlot feedback_slot_;
class OperatorField
: public BitField<Token::Value, Expression::kNextBitFieldIndex, 7> {};
@@ -2306,11 +2306,11 @@ class CompareOperation final : public Expression {
static int parent_num_ids() { return Expression::num_ids(); }
int local_id(int n) const { return base_id() + parent_num_ids() + n; }
+ FeedbackSlot feedback_slot_;
Expression* left_;
Expression* right_;
-
AstType* combined_type_;
- FeedbackSlot feedback_slot_;
+
class OperatorField
: public BitField<Token::Value, Expression::kNextBitFieldIndex, 7> {};
};
@@ -2909,9 +2909,9 @@ class NativeFunctionLiteral final : public Expression {
name_(name),
extension_(extension) {}
+ FeedbackSlot literal_feedback_slot_;
const AstRawString* name_;
v8::Extension* extension_;
- FeedbackSlot literal_feedback_slot_;
};
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698