JDK-4495754 : Add library support for common bit manipulation operations
  • Type: Enhancement
  • Component: core-libs
  • Sub-Component: java.lang
  • Affected Version: 1.4.0,1.4.1,5.0
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic,solaris_7,windows_2000
  • CPU: generic,x86,sparc
  • Submitted: 2001-08-23
  • Updated: 2017-05-16
  • Resolved: 2003-08-15
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
5.0 tigerFixed
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Relates :  
Relates :  
Relates :  
Description

Name: bsC130419			Date: 08/23/2001

Java adds the arithmetic shift operator, but roll and count leading zeros would
be very nice intrinsic routines (bytecodes anyone).   These are very important
for bit-twidling, and have fast processor-specific equivalents on most
processors.
(Review ID: 130571) 
======================================================================

Comments
CONVERTED DATA BugTraq+ Release Management Values COMMIT TO FIX: tiger FIXED IN: tiger INTEGRATED IN: tiger tiger-b16
14-06-2004

WORK AROUND Name: bsC130419 Date: 08/23/2001 write functions for these ======================================================================
11-06-2004

EVALUATION It certainly is NOT worthy of a byte code. Might be worth a library routine. ###@###.### 2001-10-23 We intend to add a fairly complete set of "bit-twiddling" methods to Integer and perhaps Long in the next major release (code-named "Tiger"). In addition to the requested methods, this set might include count one bits (AKA population count), get leading one bit, count trailing zeros and get trailing one bit. Other suggestions welcome. ###@###.### 2001-10-23 Byte swapping routines for shorts, ints, and longs would be useful for New I/O and could be intrinsified down to one or two machine instructions on most processors we support. Putting such routines in the public API would be beneficial to customers. ###@###.### 2003-04-23
23-04-2003