JDK-8256862 : Several java/foreign tests fail on x86_32 platforms
  • Type: Bug
  • Component: tools
  • Sub-Component: jextract
  • Affected Version: 16
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • CPU: x86
  • Submitted: 2020-11-23
  • Updated: 2021-02-10
  • Resolved: 2020-11-26
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 16
16 b27Fixed
Related Reports
CSR :  
Relates :  
Description
The following tests fail on x86_32 linux:

 java/foreign/StdLibTest.java 
java/foreign/TestCircularInit1.java 
java/foreign/TestCircularInit2.java 
java/foreign/TestCondy.java 
java/foreign/TestDowncall.java 
java/foreign/TestFunctionDescriptor.java 
java/foreign/TestIllegalLink.java 
java/foreign/TestNative.java 
java/foreign/TestNativeScope.java 
java/foreign/TestUpcall.java 
java/foreign/TestUpcallHighArity.java 
java/foreign/TestUpcallStubs.java 
java/foreign/TestVarArgs.java 
java/foreign/callarranger/TestSysVCallArranger.java 
java/foreign/callarranger/TestWindowsCallArranger.java 
java/foreign/stackwalk/TestStackWalk.java 
java/foreign/valist/VaListTest.java 

These tests should just be disabled on that platform, since there is no CLinker implementation on that platform yet.
Comments
Changeset: 734d3c3b Author: Jorn Vernee <jvernee@openjdk.org> Date: 2020-11-26 11:21:10 +0000 URL: https://github.com/openjdk/jdk/commit/734d3c3b
26-11-2020

Okay then, let's disable these tests for x86_32 then.
23-11-2020

[~shade] CLinker should be implementable, but probably takes quite a bit of work (especially with how 32-bit platforms can support different calling conventions). E.g. adding the Windows-x64 and AArch64 ports each took several months all in all. This work would be better to do in the openjdk/panama-foreign repo, on the foreign-abi branch: https://github.com/openjdk/panama-foreign/tree/foreign-abi And then we can push support to mainline in the next incubator round. There is no quick-fix to get just the tests working I'm afraid. This is a case of the foreign linker just not supporting 32 bit ABIs yet. (though, the patch I have is an attempt to clean up the behaviour of unsupported ABIs, it doesn't provide a full implementation.
23-11-2020

Are these implementable on x86_32? If so, I could take a stab at doing them.
23-11-2020