about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2021-06-19 23:10:55 +0000
committerbors <bors@rust-lang.org>2021-06-19 23:10:55 +0000
commitf639657fe4a16ec7704e0af77d0e5d5f587b59df (patch)
treea7c164ff5a4367aff4fe181e3d30408aee91a1a2 /compiler/rustc_codegen_llvm/src
parent150fad30ea25e812d481a784d02c95d3394b234b (diff)
parentd8530d0fa31224a2506a0932af5ac18d86c1bb0f (diff)
downloadrust-f639657fe4a16ec7704e0af77d0e5d5f587b59df.tar.gz
rust-f639657fe4a16ec7704e0af77d0e5d5f587b59df.zip
Auto merge of #86433 - paolobarbolini:string-overlapping, r=m-ou-se
Use `copy_nonoverlapping` to copy `bytes` in `String::insert_bytes`

The second copy could be made using `ptr::copy_nonoverlapping` instead of `ptr::copy`, since aliasing won't allow `self` and `bytes` to overlap. LLVM even seems to recognize this, [replacing the second `memmove` with a `memcopy`](https://rust.godbolt.org/z/Yoaa6rrGn), so this makes it so it's always applied.
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
0 files changed, 0 insertions, 0 deletions