Bug #14231
closed__uint128_t check in hash.c is broken, use
Description
Current check for __uint128_t in hash.c is not valid, since it ignores
compilers other than gcc. We hit this on lcc on e2k platform.
Configure script properly checks from 128-bit data types support and
sets HAVE_UINT128_T accordingly. This approach is already used within
ruby at bignum.c, random.c, etc.
Probably hash.c is an overlooked remnant of old days. This patch fixes
this.
See also GitHub PR on this issue:
https://github.com/ruby/ruby/pull/1781
Files
Updated by bircoph (Andrew Savchenko) over 7 years ago
Looks like this version affects all ruby versions, though I tested only on 2.4.2 and trunk.
Updated by nobu (Nobuyoshi Nakada) over 7 years ago
Does this mean something is broken, or just performance improvement?
Updated by nobu (Nobuyoshi Nakada) over 7 years ago
- Status changed from Open to Closed
Applied in changeset trunk|r61471.
Use UINT128_T support flag from configure
Current check for __uint128_t in hash.c is not valid, since it ignores
compilers other than gcc. We hit this on lcc on e2k platform.
Configure script properly checks from 128-bit data types support and
sets HAVE_UINT128_T accordingly. This approach is already used within
ruby at bignum.c, random.c, etc.
Probably hash.c is an overlooked remnant of old days. This patch fixes
this.
[ruby-core:84438] [Bug #14231] [Fix GH-1781]
From: Andrew Savchenko [email protected]
Updated by naruse (Yui NARUSE) over 7 years ago
- Backport changed from 2.3: UNKNOWN, 2.4: UNKNOWN, 2.5: UNKNOWN to 2.3: REQUIRED, 2.4: REQUIRED, 2.5: REQUIRED
Updated by naruse (Yui NARUSE) over 7 years ago
- Backport changed from 2.3: REQUIRED, 2.4: REQUIRED, 2.5: REQUIRED to 2.3: REQUIRED, 2.4: REQUIRED, 2.5: DONE
ruby_2_5 r61579 merged revision(s) 61471,61472.
Updated by nagachika (Tomoyuki Chikanaga) about 7 years ago
- Backport changed from 2.3: REQUIRED, 2.4: REQUIRED, 2.5: DONE to 2.3: REQUIRED, 2.4: DONE, 2.5: DONE
ruby_2_4 r62863 merged revision(s) 61471,61472.