[issue19904] Add 128-bit integer support to struct

2019-05-27 Thread Joannah Nanjekye
Change by Joannah Nanjekye : -- nosy: +nanjekyejoannah ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue19904] Add 128-bit integer support to struct

2015-08-27 Thread Zachary Ware
Changes by Zachary Ware zachary.w...@gmail.com: -- stage: - needs patch versions: +Python 3.6 -Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19904 ___

[issue19904] Add 128-bit integer support to struct

2014-10-14 Thread Stefan Krah
Changes by Stefan Krah stefan-use...@bytereef.org: -- nosy: -skrah ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19904 ___ ___ Python-bugs-list

[issue19904] Add 128-bit integer support to struct

2013-12-09 Thread Fil Mackay
Fil Mackay added the comment: So where do we go from here - is there enough support for this to proceed, or vote the idea off the island :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19904

[issue19904] Add 128-bit integer support to struct

2013-12-09 Thread Gregory P. Smith
Gregory P. Smith added the comment: Pick two suitable letters for the int128 and uint128 cases and create a patch for an implementation with tests (targeting Python 3.5). The implementation needs to compile and work even when the platform C compiler Python is compiled with does not have a

[issue19904] Add 128-bit integer support to struct

2013-12-08 Thread Francisco Martín Brugué
Francisco Martín Brugué added the comment: If performance is the reason for the feature: My impression is that the goal of the struct module is not necessarily top performance. I'm not sure if it applies but on #19905 (message 205345 [1]) is said its a dependency for that issue [1]

[issue19904] Add 128-bit integer support to struct

2013-12-08 Thread Meador Inge
Changes by Meador Inge mead...@gmail.com: -- nosy: +meador.inge ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19904 ___ ___ Python-bugs-list

[issue19904] Add 128-bit integer support to struct

2013-12-08 Thread Fil Mackay
Fil Mackay added the comment: Stefan, performance is not the principle motivator here: the intention is that it is just sensible to support this integer type, just like supporting int64 since it is an intrinsic type supported by CPU's. Of course any integer length could be handled by

[issue19904] Add 128-bit integer support to struct

2013-12-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Of course any integer length could be handled by memoryview unpacker, but this would not really make sense for int64. My view is that any intrinsic type (ie. register type) is the key point at which it should be supported by struct, and not a custom

[issue19904] Add 128-bit integer support to struct

2013-12-08 Thread Fil Mackay
Fil Mackay added the comment: Antoine, No, the SIMD vector should be treated as a int128 (for eg.), not as 4 python ints. It is the unpacking process that unpacks into 4 python ints. The two shouldn't be confused - you definitely want to be able to treat the vector in both states (packed and

[issue19904] Add 128-bit integer support to struct

2013-12-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: The two shouldn't be confused - you definitely want to be able to treat the vector in both states (packed and unpacked). Why do you need the packed state as a 128-bit int, rather than as a bytes object? You are not doing arithmetic on it, AFAIU. --

[issue19904] Add 128-bit integer support to struct

2013-12-08 Thread Fil Mackay
Fil Mackay added the comment: Antoine, I don't think register types matter here. The struct module provides interoperability with low-level *data types* (in C and other common languages), not CPU *registers*. OK, see where you're coming from. I guess my thinking was such that struct (and

[issue19904] Add 128-bit integer support to struct

2013-12-07 Thread Stefan Krah
Stefan Krah added the comment: If performance is the reason for the feature: My impression is that the goal of the struct module is not necessarily top performance. E.g. in memoryview the custom unpackers for comparisons are 30-60 times faster than using the struct module. -- nosy:

[issue19904] Add 128-bit integer support to struct

2013-12-06 Thread Mark Dickinson
Mark Dickinson added the comment: Do you have a particular application / use-case in mind? Would int.from_bytes and int.to_bytes fill the need? -- nosy: +mark.dickinson ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19904

[issue19904] Add 128-bit integer support to struct

2013-12-06 Thread Raymond Hettinger
Changes by Raymond Hettinger raymond.hettin...@gmail.com: -- versions: -Python 2.7, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19904 ___

[issue19904] Add 128-bit integer support to struct

2013-12-06 Thread Fil Mackay
Fil Mackay added the comment: The use case is interacting with C structures that have 128/256/512 bit integers in them. These require correct memory alignment, and can't reliably be hacked with multiple int64's. These size ints come from the fact that CPU's now have registers of these sizes,

[issue19904] Add 128-bit integer support to struct

2013-12-06 Thread Fil Mackay
Fil Mackay added the comment: I noticed that python 2.7 has been removed - why would this not be appropriate for this version? Given the current level of use of this version, I see it's inclusion as very important - without having to be relegated to 3.x only. --

[issue19904] Add 128-bit integer support to struct

2013-12-06 Thread Alex Gaynor
Changes by Alex Gaynor alex.gay...@gmail.com: -- nosy: +alex ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19904 ___ ___ Python-bugs-list mailing

[issue19904] Add 128-bit integer support to struct

2013-12-06 Thread Tim Peters
Tim Peters added the comment: Fil, here's the release schedule for Python 2.8: http://www.python.org/dev/peps/pep-0404/ In short, 2.8 will never be released (well, never by us), and only bugfixes can be applied to the 2.7 line. That's why 2.7 was removed. Regardless of its merits, this

[issue19904] Add 128-bit integer support to struct

2013-12-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: any form of integer SIMD operation (vectors) Wouldn't these be appropriately represented by a tuple of integers (or floats)? For example, a SIMD vector of four 32-bit integers could be represented as four Python ints. Or would that be terrible for

[issue19904] Add 128-bit integer support to struct

2013-12-05 Thread Fil Mackay
New submission from Fil Mackay: I've been looking at adding 128-bit support to the struct module. Currently only named integer types are supported, which vary in implementation. These include: short int long long long Depending on the platform, none may translate to 128-bit integer (the case