-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Open
Labels
C-optimizationCategory: An issue highlighting optimization opportunities or PRs implementing suchCategory: An issue highlighting optimization opportunities or PRs implementing suchT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.
Description
I wouldn't expect any panics other than panic_on_ord_violation
and input arguments check, which should get optimized out.
https://rust.godbolt.org/z/h5P6Er8zr
.LBB2_96:
lea rax, [rip + .Lanon.c0a2eb89440bc2e212dbf84361b066b5.10]
mov qword ptr [rsp + 24], rax
mov qword ptr [rsp + 32], 1
mov qword ptr [rsp + 40], 8
xorps xmm0, xmm0
movups xmmword ptr [rsp + 48], xmm0
lea rsi, [rip + .Lanon.c0a2eb89440bc2e212dbf84361b066b5.13]
lea rdi, [rsp + 24]
call qword ptr [rip + core::panicking::panic_fmt::h22107f1a113fdabe@GOTPCREL]
.LBB2_97:
lea rax, [rip + .Lanon.c0a2eb89440bc2e212dbf84361b066b5.10]
mov qword ptr [rsp + 24], rax
mov qword ptr [rsp + 32], 1
mov qword ptr [rsp + 40], 8
xorps xmm0, xmm0
movups xmmword ptr [rsp + 48], xmm0
lea rsi, [rip + .Lanon.c0a2eb89440bc2e212dbf84361b066b5.14]
lea rdi, [rsp + 24]
call qword ptr [rip + core::panicking::panic_fmt::h22107f1a113fdabe@GOTPCREL]
.LBB2_95:
ud2
.LBB2_15:
lea rdx, [rip + .Lanon.c0a2eb89440bc2e212dbf84361b066b5.12]
mov rsi, r13
call qword ptr [rip + core::panicking::panic_bounds_check::hdaa6e5107cd75dd9@GOTPCREL]
.LBB2_24:
lea rdx, [rip + .Lanon.c0a2eb89440bc2e212dbf84361b066b5.11]
mov rsi, r13
call qword ptr [rip + core::panicking::panic_bounds_check::hdaa6e5107cd75dd9@GOTPCREL]
Metadata
Metadata
Assignees
Labels
C-optimizationCategory: An issue highlighting optimization opportunities or PRs implementing suchCategory: An issue highlighting optimization opportunities or PRs implementing suchT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.