[PATCH] D53604: [AST] Widen the bit-fields of Stmt to 8 bytes
Bruno Ricci via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 23 13:03:18 PDT 2018
riccibruno created this revision.
riccibruno added a reviewer: rjmccall.
riccibruno added a project: clang.
Herald added a subscriber: cfe-commits.
Although some classes are using the tail padding of Stmt, most of
them are not. In particular the expression classes are not using it
since there is Expr in between, and Expr contains a single pointer.
This patch widen the bit-fields to Stmt to 8 bytes and move some
data from NullStmt, CompoundStmt, LabelStmt, AttributedStmt, SwitchStmt,
WhileStmt, DoStmt, ForStmt, GotoStmt, ContinueStmt, BreakStmt
and ReturnStmt to the newly available space.
In itself this patch do not achieve much but I plan to go through each of
the classes in the statement/expression hierarchy and use this newly
available space. A quick estimation gives me that this should shrink the
size of the statement/expression hierarchy by >10% when parsing all of Boost.
Repository:
rC Clang
https://reviews.llvm.org/D53604
Files:
include/clang/AST/Stmt.h
lib/AST/Stmt.cpp
lib/Serialization/ASTReaderStmt.cpp
lib/Serialization/ASTWriterStmt.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D53604.170733.patch
Type: text/x-patch
Size: 29608 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20181023/69ec8105/attachment-0001.bin>
More information about the cfe-commits
mailing list