JDK-8295666 : Linux x86 build fails after 8292591
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 20
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: x86
  • Submitted: 2022-10-19
  • Updated: 2024-05-14
  • Resolved: 2022-10-21
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 20
20 b21Fixed
Related Reports
Relates :  
Relates :  
Description
src/hotspot/os/linux/systemMemoryBarrier_linux.cpp:65:18: error: 'SYS_membarrier' was not declared in this scope
   return syscall(SYS_membarrier, cmd, flags, cpu_id); // cpu_id only on >= 5.10
                  ^~~~~~~~~~~~~~

We need to add a SYS_membarrier definition in systemMemoryBarrier_linux.cpp for x86 as well:

#ifndef SYS_membarrier
  #if defined(AMD64)
  #define SYS_membarrier 324
  #elif defined(PPC64)
  #define SYS_membarrier 365
  #elif defined(AARCH64)
  #define SYS_membarrier 283
  #elif defined(ALPHA)
  #define SYS_membarrier 517
  #else
  #error define SYS_membarrier for the arch
  #endif
#endif // SYS_membarrier

Comments
Changeset: 15bebf92 Author: Boris Ulasevich <bulasevich@openjdk.org> Date: 2022-10-21 08:59:24 +0000 URL: https://git.openjdk.org/jdk/commit/15bebf922fb3fe46b755c85bc0a459b3c1e34c98
21-10-2022

A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/10771 Date: 2022-10-19 16:15:18 +0000
20-10-2022