diff options
| author | Florian Zeitz <florob@babelmonkeys.de> | 2017-07-26 16:27:25 +0200 |
|---|---|---|
| committer | Florian Zeitz <florob@babelmonkeys.de> | 2017-07-26 16:27:25 +0200 |
| commit | ac43d58d3aca4b578864ec6dbb24d68a9f9c201c (patch) | |
| tree | bf2c1da06c63a8ccdc6a0d6bee3ed7ca144f6bf7 /src/rustllvm/RustWrapper.cpp | |
| parent | d721c1f9e3caf1f4a0e0afb0151ec127d4fd2771 (diff) | |
| download | rust-ac43d58d3aca4b578864ec6dbb24d68a9f9c201c.tar.gz rust-ac43d58d3aca4b578864ec6dbb24d68a9f9c201c.zip | |
trans: Optimize initialization using repeat expressions
This elides initialization for zero-sized arrays: * for zero-sized elements we previously emitted an empty loop * for arrays with a length of zero we previously emitted a loop with zero iterations This emits llvm.memset() instead of a loop over each element when: * all elements are zero integers * elements are byte sized
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
