Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upTracking issue for 128-bit integer support (RFC 1504) #35118
Comments
nikomatsakis
added
T-lang
B-unstable
B-RFC-approved
labels
Jul 29, 2016
This comment has been minimized.
This comment has been minimized.
|
Is |
This comment has been minimized.
This comment has been minimized.
|
That's a good point, I don't see any reason why it shouldn't be allowed. |
This comment has been minimized.
This comment has been minimized.
|
The return type of the |
This comment has been minimized.
This comment has been minimized.
|
Intrinsics are stuff internal to the compiler, therefore changes to them doesn’t need discussion in the RFCs. |
This comment has been minimized.
This comment has been minimized.
|
I know, I just wanted to mention it here since I didn't see enums discussed in the RFC. |
japaric
referenced this issue
Aug 14, 2016
Closed
Provide support for arbitrary width atomics from 16bit to 2x word size (u16, u32, u64, u128) #24564
nagisa
referenced this issue
Aug 24, 2016
Closed
Initial implementation of the 128-bit integers #35954
bors
added a commit
that referenced
this issue
Dec 4, 2016
bors
added a commit
that referenced
this issue
Dec 4, 2016
bors
added a commit
that referenced
this issue
Dec 4, 2016
bors
added a commit
that referenced
this issue
Dec 4, 2016
bors
added a commit
that referenced
this issue
Dec 8, 2016
bors
added a commit
that referenced
this issue
Dec 8, 2016
bors
added a commit
that referenced
this issue
Dec 8, 2016
bors
added a commit
that referenced
this issue
Dec 14, 2016
bors
added a commit
that referenced
this issue
Dec 20, 2016
bors
added a commit
that referenced
this issue
Dec 21, 2016
This comment has been minimized.
This comment has been minimized.
|
How should FFI with this type be handled? Is there any standard ABI support for these types? AFAICT, the answer is "no", which means this type should be FFI-unsafe, and the FFI unsafety lint should be updated to reject |
This comment has been minimized.
This comment has been minimized.
|
cc @est31 |
This comment has been minimized.
This comment has been minimized.
|
On Windows there is most definitely no standard i128 yet because the standard compiler (msvc) does not support |
This comment has been minimized.
This comment has been minimized.
It depends on the architecture. SysV defines the ABI for 64 bit architectures. For x86, its most likely its not defined. Same goes for windows: it should in theory be defined for 64 bit (just sadly nobody adheres to it, its a gigantic mess), but not on x86. This directly maps the support of the i128 type in C, and I think generally it makes little sense to have FFI for types that don't exist in C. |
This comment has been minimized.
This comment has been minimized.
|
bug report in llvm about the x86_64 ABI problems: https://llvm.org/bugs/show_bug.cgi?id=31362 |
This comment has been minimized.
This comment has been minimized.
|
Also one in GCC: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78799 |
bors
added a commit
that referenced
this issue
Dec 21, 2016
bors
added a commit
that referenced
this issue
Dec 30, 2016
alexcrichton
added a commit
to alexcrichton/rust
that referenced
this issue
Mar 23, 2018
kennytm
added a commit
to kennytm/rust
that referenced
this issue
Mar 24, 2018
bors
added a commit
that referenced
this issue
Mar 24, 2018
bors
added a commit
that referenced
this issue
Mar 25, 2018
bors
added a commit
that referenced
this issue
Mar 26, 2018
This comment has been minimized.
This comment has been minimized.
|
I think this is done |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Could someone update the OP too create more check boxes for repr128? |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
I think that is fixed, although not in the nicest way. I closed the issue. |
This comment has been minimized.
This comment has been minimized.
|
@ebfull see my comment here: #35118 (comment) i128 works on the entire x86 family as well as the ARM family. This covers all of the tier 1 platforms. What you are doing in zkcrypto/pairing#80 is exactly what I wanted to prevent by blocking stabilisation until all platforms support i128 lol, but people thought otherwise. |
This comment has been minimized.
This comment has been minimized.
|
@est31 I'm not doing zkcrypto/pairing#80 until it works on all platforms, which I mention in that issue. In the mean time all I will do is remove the |
This comment has been minimized.
This comment has been minimized.
|
@ebfull not blaming you. I'm partially blaming myself, thought that lowering worked already. Partially I'm blaming those people who decided to stabilize before all platforms support it. And the backend vendors who refuse to take {u,i}128 seriously. Sadly, this is more of a "stable beta" release of i128 than an arrival of a feature that can be relied upon. |
This comment has been minimized.
This comment has been minimized.
hdevalence
commented
Apr 1, 2018
|
It would be nice if there was a (documented) way to set a cargo feature as the default on a given architecture. From what I can tell this isn't quite possible, since the architecture-selection code happens with The motivation is that even if |
This comment has been minimized.
This comment has been minimized.
|
You can set cfg flags from the build script.
…On Sun, Apr 1, 2018 at 7:19 PM, Henry de Valence ***@***.***> wrote:
It would be nice if there was a (documented) way to set a cargo feature as
the default on a given architecture. From what I can tell this isn't quite
possible, since the architecture-selection code happens with #[cfg(...)]s
while the crate is being compiled, by which point the crate's features are
already selected. Am I missing something?
The motivation is that even if u128s are available, it may not be
desirable to use them, unless they actually correspond to instructions
available on that platform.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#35118 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAC3n0sF6mXohDEJzN0dV2ggaYT631BTks5tkWB7gaJpZM4JYhaE>
.
|
dtolnay
referenced this issue
May 17, 2018
Closed
i128 and u128 integers missing Deserialize impls #1136
Centril
added
disposition-merge
finished-final-comment-period
and removed
final-comment-period
labels
May 24, 2018
This comment has been minimized.
This comment has been minimized.
|
@mark-i-m any developments re. |
This comment has been minimized.
This comment has been minimized.
|
Not that I'm aware of... but I just did the stabilization. I'm not sure if if anyone has claimed ownership of that task yet... |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Nothing has changed re EDIT: That, or if days suddenly become 48-hour long. |
Centril
referenced this issue
Nov 19, 2018
Open
Tracking issue for feature(repr128); enums with 128-bit discriminants #56071
This comment has been minimized.
This comment has been minimized.
|
Closing this in favor of the targeted issue #56071 since all remaining work has been done. |
nikomatsakis commentedJul 29, 2016
•
edited by nagisa
Tracking issue for rust-lang/rfcs#1504.
cc @Amanieu
Blocking stabilization:
Interaction with FFI? (#35118 (comment))- #44261separately feature gate- #44262repr(i128)repr128feature