llvm-project/clang/lib/Serialization
Bruno Ricci b1cc94b2e5 [AST] Only store the needed data in IfStmt
Only store the needed data in IfStmt. This cuts the size of IfStmt
by up to 3 pointers + 1 SourceLocation. The order of the children
is intentionally kept the same even though it would be more
convenient to put the optional trailing objects last. Additionally
use the newly available space in the bit-fields of Stmt to store
the location of the "if".

The result of this is that for the common case of an
if statement of the form:

if (some_cond)
  some_statement

the size of IfStmt is brought down to 8 bytes + 2 pointers,
instead of 8 bytes + 5 pointers + 2 SourceLocation.

Differential Revision: https://reviews.llvm.org/D53607

Reviewed By: rjmccall

llvm-svn: 345464
2018-10-27 21:12:20 +00:00
..
ASTCommon.cpp [OPENMP] Add support for OMP5 requires directive + unified_address clause 2018-09-26 04:28:39 +00:00
ASTCommon.h Remove \brief commands from doxygen comments. 2018-05-09 01:00:01 +00:00
ASTReader.cpp Add support for 'dynamic_allocators' clause on 'requires' directive. Differential Revision: https://reviews.llvm.org/D53079 2018-10-11 14:41:10 +00:00
ASTReaderDecl.cpp Distinguish `__block` variables that are captured by escaping blocks 2018-10-01 21:51:28 +00:00
ASTReaderInternals.h Remove trailing space 2018-07-30 19:24:48 +00:00
ASTReaderStmt.cpp [AST] Only store the needed data in IfStmt 2018-10-27 21:12:20 +00:00
ASTWriter.cpp Add support for 'dynamic_allocators' clause on 'requires' directive. Differential Revision: https://reviews.llvm.org/D53079 2018-10-11 14:41:10 +00:00
ASTWriterDecl.cpp Distinguish `__block` variables that are captured by escaping blocks 2018-10-01 21:51:28 +00:00
ASTWriterStmt.cpp [AST] Only store the needed data in IfStmt 2018-10-27 21:12:20 +00:00
CMakeLists.txt
GeneratePCH.cpp Apply clang-tidy's performance-unnecessary-value-param to parts of clang. 2017-03-21 21:35:04 +00:00
GlobalModuleIndex.cpp Support: Simplify endian stream interface. NFCI. 2018-05-18 19:46:24 +00:00
Module.cpp Remove trailing space 2018-07-30 19:24:48 +00:00
ModuleFileExtension.cpp [NFC] Header cleanup 2016-07-18 19:02:11 +00:00
ModuleManager.cpp Lift VFS from clang to llvm (NFC) 2018-10-10 13:27:25 +00:00
MultiOnDiskHashTable.h Support: Simplify endian stream interface. NFCI. 2018-05-18 19:46:24 +00:00