summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/aggregate-assign-call.c
Commit message (Collapse)AuthorAgeFilesLines
* Generalize NRVO to cover C structs.Akira Hatanaka2018-03-291-9/+1
| | | | | | | | | | | This commit generalizes NRVO to cover C structs (both trivial and non-trivial structs). rdar://problem/33599681 Differential Revision: https://reviews.llvm.org/D44968 llvm-svn: 328809
* [CodeGen] Eagerly emit lifetime.end markers for callsGeorge Burgess IV2018-03-101-0/+101
In C, we'll wait until the end of the scope to clean up aggregate temporaries used for returns from calls. This means in cases like: { // Assuming that `Bar` is large enough to warrant indirect returns struct Bar b = {}; b = foo(&b); b = foo(&b); b = foo(&b); b = foo(&b); } ...We'll allocate space for 5 Bars on the stack (`b`, and 4 temporaries). This becomes painful in things like large switch statements. If cleaning up sooner is trivial, we should do it. llvm-svn: 327229
OpenPOWER on IntegriCloud