JDK-8373261 : [lworld] VerifyError: Strict fields not a subset of initial strict instance fields
  • Type: Bug
  • Component: tools
  • Sub-Component: javac
  • Affected Version: repo-valhalla
  • Priority: P3
  • Status: Open
  • Resolution: Unresolved
  • Submitted: 2025-12-08
  • Updated: 2025-12-08
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
repo-valhallaUnresolved
Related Reports
Blocks :  
Description
Attached simple Test.java triggers a VerifyError:

java --enable-preview -Xint Test.java
Exception in thread "main" java.lang.VerifyError: Strict fields not a subset of initial strict instance fields: i4:I
Exception Details:
  Location:
    Test$Val2.<init>(Z)V @0: aload_0
  Reason:
    Invalid use of strict instance fields
  Current Frame:
    bci: @0
    flags: { flagThisUninit }
    locals: { uninitializedThis, integer }
    stack: { }
  Bytecode:
    0000000: 2a03 b500 012a 1b99 0007 01a7 000a bb00
    0000010: 0759 b700 09b5 000d 2ab7 0011 b1       
  Stackmap Table:

	at Test.main(Test.java:28)


It seems to be triggered by this line "this.val1 = b ? null : new Val1();"
Comments
Verified in the bytecode of Test$Val2 that there is a spurious i4 reference in early larval frames.
08-12-2025