diff options
| author | Scott McMurray <scottmcm@users.noreply.github.com> | 2018-03-23 01:30:23 -0700 |
|---|---|---|
| committer | Scott McMurray <scottmcm@users.noreply.github.com> | 2018-03-23 01:30:23 -0700 |
| commit | 68e0ea9d47f797f815225e4f2fbd9bb1cde6e19e (patch) | |
| tree | 31e5c47c48d12df28fa1efc437457d71549ea3a6 /src/test/incremental/thinlto | |
| parent | 52f7e8836cc2e6c0edfaf402ee40ca724a8c0989 (diff) | |
| download | rust-68e0ea9d47f797f815225e4f2fbd9bb1cde6e19e.tar.gz rust-68e0ea9d47f797f815225e4f2fbd9bb1cde6e19e.zip | |
Introduce unsafe offset_from on pointers
Adds intrinsics::exact_div to take advantage of the unsafe, which reduces the implementation from
```asm
sub rcx, rdx
mov rax, rcx
sar rax, 63
shr rax, 62
lea rax, [rax + rcx]
sar rax, 2
ret
```
down to
```asm
sub rcx, rdx
sar rcx, 2
mov rax, rcx
ret
```
(for `*const i32`)
Diffstat (limited to 'src/test/incremental/thinlto')
0 files changed, 0 insertions, 0 deletions
