JDK-8254144 : Non-x86 Zero builds fail with return-type warning in os_linux_zero.cpp
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 8,11,15,16
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2020-10-07
  • Updated: 2024-12-06
  • Resolved: 2020-10-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.
JDK 11 JDK 15 JDK 16 Other
11.0.10Fixed 15.0.2Fixed 16 b20Fixed openjdk8u282Fixed
Related Reports
Relates :  
Description
src/hotspot/os_cpu/linux_zero/os_linux_zero.cpp: In function long long unsigned int __sync_val_compare_and_swap_8(volatile void*, long long unsigned int, long long unsigned int):

src/hotspot/os_cpu/linux_zero/os_linux_zero.cpp:499:3: warning: no return statement in function returning non-void [-Wreturn-type]
   }
 
There is ShouldNotCallThis(), but no return.

This readily reproduces in 11u. It does not seem to reproduce in HEAD, but it is a bug nevertheless.
Comments
I've reviewed the follow-on. Please use both bug IDs for the 8u commit.
19-10-2020

Ok, fine, I'll work under JDK-8197981 to get this to 11u and 8u.
19-10-2020

This is JDK-8199973. https://hg.openjdk.java.net/jdk7u/jdk7u/hotspot/rev/ce3abb5889fb Your patch misses the same case in *BSD.
17-10-2020

Fix Request (8u) Same reason as for 15u. Patch applies cleanly. Patched JDK passes Linux x86_64 Zero bootcycle-images.
14-10-2020

Fix Request (11u) Same reason as for 15u. Patch applies cleanly. Patched JDK passes Linux x86_64 Zero bootcycle-images.
14-10-2020

Fix Request (15u) This makes Zero compilation pass without ignoring compiler warnings. Patch applies cleanly to 15u, passes Linux x86_64 fastdebug Zero bootcycle build.
12-10-2020

Changeset: 8f9e4792 Author: Aleksey Shipilev <shade@openjdk.org> Date: 2020-10-08 08:11:26 +0000 URL: https://git.openjdk.java.net/jdk/commit/8f9e4792
08-10-2020