What is the different between memmove
and c++11 std::move
? Can I use std::move
on overlapped memory location? And which method has the higher speed performance?
A few ways:
In situations where you're copying POD types to a right-overlapping range, it is likely that memmove and std::move will have similar performance. In all other situations, only one of the two is appropriate, so you can't really compare performance.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.