-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rlibc's memcpy get miscompiled #31505
Comments
I've filed a LLVM bug for this: https://llvm.org/bugs/show_bug.cgi?id=26554 |
Good job! What a nightmare of a bug to identify. |
any feedback from llvm upstream ? this bug completely breaks rustc build under OpenBSD |
This is fixed in the 3.8 release branch only, llvm-mirror/llvm@fdf40be |
Looks like they picked up a bunch of fixes, one of which is even quite relevant to us! Closes rust-lang#31505
I wonder how you managed to disable sse and sse2 in LLVM on x86_64 - is there a patch for that? |
@petevine Try to avoid passing floating points to/from functions |
Ah, thanks - does soft-float work on x86_64 presently? |
Looks like they picked up a bunch of fixes, one of which is even quite relevant to us! Closes #31505
rlibc's memcpy get miscompiled with
-O --target=x86_64-sun-solaris -C target-feature=-mmx,-sse,-sse2
At 0x18
lea esi, [rsi+0]
zeroes the upper 32-bits ofrsi
which is a 64-bit pointer.Curiously some targets has the loop unrolled. I don't see any reason for this.
Assembler output of various targets:
x86_64-rumprun-netbsd:
x86_64-sun-solaris:
x86_64-unknown-linux-gnu:
x86_64-unknown-linux-musl:
x86_64-unknown-freebsd:
The text was updated successfully, but these errors were encountered: