]> git.lizzy.rs Git - rust.git/commit
trans_arg_expr: Omit extra copies for rvalues
authorBjörn Steinbrink <bsteinbr@gmail.com>
Sat, 3 Aug 2013 10:35:33 +0000 (12:35 +0200)
committerBjörn Steinbrink <bsteinbr@gmail.com>
Sat, 3 Aug 2013 13:03:58 +0000 (15:03 +0200)
commita51e3e46effc07f5e7ce5a698ddc8be65244b3a5
treef42224d47438ebcf99894a3ecae2e943a1958608
parent2765811cb6530eb73c5450bd25e915e67bd512cf
trans_arg_expr: Omit extra copies for rvalues

rvalues aren't going to be used anywhere but as the argument, so
there's no point in copying them. LLVM used to eliminate the copy
later, but why bother emitting it in the first place?
src/librustc/middle/trans/callee.rs