Observe:
$ CONF=linux-x86_64-server-fastdebug make images run-test TEST=tools/javac/lambda/T8031967.java
STDOUT:
STDERR:
/Test.java:3: error: cannot find symbol
GroupLayout l = new GroupLayout();
^
symbol: class GroupLayout
location: class Test
/Test.java:3: error: cannot find symbol
GroupLayout l = new GroupLayout();
^
symbol: class GroupLayout
location: class Test
java.lang.IllegalStateException: java.lang.StackOverflowError
at jdk.compiler/com.sun.tools.javac.api.JavacTaskImpl.analyze(JavacTaskImpl.java:383)
at T8031967.runTestCase(T8031967.java:108)
at T8031967.run(T8031967.java:55)
at T8031967.main(T8031967.java:49)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:564)
at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
at java.base/java.lang.Thread.run(Thread.java:831)
Caused by: java.lang.StackOverflowError
at jdk.compiler/com.sun.tools.javac.comp.Resolve.resolveIdent(Resolve.java:2651)
at jdk.compiler/com.sun.tools.javac.comp.Attr.visitIdent(Attr.java:4020)
at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCIdent.accept(JCTree.java:2407)
x86_32 defaults to 320K stack size, x86_64 (and pretty much every other platform) defaults to 1M stack size. Setting -Xss1M explicitly makes the test pass.