Skip to content
Unverified Commit 6ab3208d authored by Michael Park's avatar Michael Park
Browse files

Remove the unnecessary `is_nothrow_swappable` condition in `swap`.

Thanks to @lewissbaker who pointed out the unnecessary condition in
https://reviews.llvm.org/D81954#inline-756872. Since this codepath does not
make use of `swap` anyway (that codepath is a different branch), we can safely
remove this condition and produce better codegen when all types are nothrow
movable but are potentially-throwing swappable.

See codegen in https://gcc.godbolt.org/z/uDFZjz

Reviewed By: ldionne, #libc

Differential Revision: https://reviews.llvm.org/D83274
parent 82206e7f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment