JDK-6366196 : regression in CharacterRangeTable format
  • Type: Bug
  • Component: tools
  • Sub-Component: javac
  • Affected Version: 6
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: generic,solaris_9
  • CPU: generic,x86
  • Submitted: 2005-12-21
  • Updated: 2010-04-02
  • Resolved: 2006-03-23
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.
JDK 6
6 b78Fixed
Related Reports
Duplicate :  
Relates :  
Description
Starting from jdk6.0-b27 javac generates different source code 
position in
CharacterRangeTable attribute (under -Xjcov mode).
Originally a source position in the CRT was packed as 
(linenumber<<10)|position_in_line.Starting from b27 it seems 
represented as a position from a beginning of source file.

A problem is that the change breaks JCov utilities and JDK SQE 
cannot generate
coverage reports because of this.

Comments
SUGGESTED FIX There are several ways to fix this regression. - Peter Ahe has suggested to add fields that was removed with the position change back to trees. But there will be memory impact and will affect multiple javac files. - Alternatively we may dynamically generate line/column numbers from the source positions. But this will potentially make javac slower in jcov mode.
23-02-2006

EVALUATION This regression is caused by fixing 4994049. Before the change, source positions are represented as line and column number packed in a single integer. After the change, they are represented as character offsets from the beginning of the source file. The CharacterRangeTable generation code should be modified to use the line/column information, not the source offsets.
23-02-2006