llvm-project/clang/lib
Arnold Schwaighofer 7b871611b9 SwiftCC: Perform physical layout when computing coercion types
We need to take type alignment padding into account whe computing physical
layouts.

The layout must be compatible with the input layout, offsets are defined in
terms of offsets within a packed struct which are computed in terms of the alloc
size of a type.

Usingthe store size we would insert padding for the following type for example:

struct {

  int3 v;
  long long l;
} __attribute((packed))

On x86-64 int3 is padded to int4 alignment. The swiftcc type would be
<{ <3 x float>, [4 x i8], i64 }> which is not compatible with <{ <3 x float>,
i64 }>.

The latter has i64 at offset 16 and the former at offset 20.

rdar://32618125

llvm-svn: 305956
2017-06-21 21:43:40 +00:00
..
ARCMigrate Added LLVM_FALLTHROUGH to address warning: this statement may fall through. NFC. 2017-06-03 06:23:19 +00:00
AST Support MS builtins using 'long' on LP64 platforms 2017-06-21 02:20:46 +00:00
ASTMatchers [ASTMatchers] Fix use after free. 2017-06-09 17:55:42 +00:00
Analysis Changed wording in comment 2017-06-21 05:41:39 +00:00
Basic [AArch64] ADD ARMv.2-A FP16 vector intrinsics 2017-06-20 18:54:57 +00:00
CodeGen SwiftCC: Perform physical layout when computing coercion types 2017-06-21 21:43:40 +00:00
Driver Revert r305678: [driver][macOS] Pick the system version for the 2017-06-21 10:27:24 +00:00
Edit [clang] Fix format specifiers fixits for nested macros 2017-06-20 20:46:58 +00:00
Format clang-format: introduce InlineOnly short function style 2017-06-21 13:56:02 +00:00
Frontend Fixed compiler warnings after r305890. 2017-06-21 12:34:27 +00:00
FrontendTool Add -frewrite-imports flag. 2017-06-09 21:24:02 +00:00
Headers [DOXYGEN] Corrected several typos and incorrect parameters description that Sony's techinical writer found during review. 2017-06-06 22:58:01 +00:00
Index [index] Nested class declarations should be annotated with the 2017-06-21 13:51:04 +00:00
Lex [preprocessor] Fix assertion hit when 'SingleFileParseMode' option is enabled and #if with an undefined identifier and without #else 2017-06-21 18:52:44 +00:00
Parse [Parser][ObjC] Use an artificial EOF token while parsing lexed ObjC methods 2017-06-19 17:53:21 +00:00
Rewrite Added LLVM_FALLTHROUGH to address warning: this statement may fall through. NFC. 2017-06-03 06:29:40 +00:00
Sema Function with unparsed body is a definition 2017-06-21 12:46:57 +00:00
Serialization [ODRHash] Supply more information when generic error message is emitted. 2017-06-21 01:43:13 +00:00
StaticAnalyzer [analyzer] Bump a few default performance thresholds. 2017-06-21 11:29:35 +00:00
Tooling Method loadFromCommandLine should be able to report errors 2017-05-24 11:57:37 +00:00
CMakeLists.txt