Skip to content
This repository has been archived by the owner on Oct 21, 2023. It is now read-only.

8240567: MethodTooLargeException thrown while creating a jlink image #1

Closed
wants to merge 87 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
87 commits
Select commit Hold shift + click to select a range
39af10c
8240567: MethodTooLargeException thrown while creating a jlink image
koppor Jun 11, 2023
a0da729
Disable bundle deletion
koppor Jun 12, 2023
b1c3867
Disable tests
koppor Jun 12, 2023
678e403
Setup sync action
koppor Jun 13, 2023
e285ec3
Create workflow in UI
koppor Jun 13, 2023
f033d75
Realle merge branch
koppor Jun 13, 2023
0953722
Add debug
koppor Jun 13, 2023
3a7cfc2
Try without action
koppor Jun 13, 2023
64290ec
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 13, 2023
123b965
No updates on push
koppor Jun 13, 2023
fa7060c
8309934: Update GitHub Actions to use JDK 17 for building jtreg
sormuras Jun 13, 2023
4e52725
Add upload after build
koppor Jun 14, 2023
c56feae
Build only platforms we fetch the binaries for
koppor Jun 14, 2023
5d3d3d4
Really specify build targets
koppor Jun 14, 2023
8243c93
Try to remove debug build
koppor Jun 14, 2023
cebb28d
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 16, 2023
25de8d1
Try to get it running on push
koppor Jun 16, 2023
a564617
Try to build release only
koppor Jun 16, 2023
2478ee7
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 16, 2023
2eae862
Trigger build after sync
koppor Jun 16, 2023
a7d2fe1
Try to fix call
koppor Jun 16, 2023
10e1400
Try to fix rsync parameters
koppor Jun 16, 2023
15515e2
try to fix path
koppor Jun 16, 2023
f057536
Fix dir again
koppor Jun 16, 2023
80d2435
Try to fix download
koppor Jun 17, 2023
41219ca
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 17, 2023
dfd5cd1
Test JDK upload
koppor Jun 19, 2023
96168de
Fix indent
koppor Jun 19, 2023
01044c2
Try to fix secret passing
koppor Jun 19, 2023
8490f00
Try to fix call
koppor Jun 19, 2023
1b55ac6
Fix "secrets: inherit"
koppor Jun 21, 2023
f7f8bf7
Fix missing checkout for test
koppor Jun 21, 2023
3e048b8
One more try
koppor Jun 21, 2023
6d0456b
Fix name
koppor Jun 21, 2023
af09477
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 22, 2023
a22c753
Try in main.yml (and use actions/download-artifact@v3)
koppor Jun 22, 2023
e208e0a
Remove test step
koppor Jun 22, 2023
6695b40
Fix inputs. vs. secrets. (and remove obsolete files)
koppor Jun 22, 2023
c694dda
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 23, 2023
be49724
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 24, 2023
d611cc0
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 27, 2023
074e7de
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 28, 2023
e99f7d0
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 29, 2023
c74193c
Fix threshold
koppor Jun 29, 2023
2b237ca
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jun 30, 2023
f615612
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 1, 2023
3368302
Add parameterization for the number of moduleDescriptors per helper m…
koppor Jul 1, 2023
dad33c8
Fix nit (indent)
koppor Jul 1, 2023
e62e7aa
Add description
koppor Jul 1, 2023
1bc4f79
Apply suggestions from code review
koppor Jul 1, 2023
732e7cf
Reuse helper array list
koppor Jul 1, 2023
1b5b9d7
Port JDK master changes
koppor Jul 1, 2023
1ea4c47
(backport-fix) Use JDK21's features, not JDK22
koppor Jul 1, 2023
3d7dcc8
Fix ArrayList initialization and off-by-one errors
koppor Jul 1, 2023
860d0f4
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 2, 2023
5f77e7f
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 4, 2023
0e4253c
Reposition DEDUP_LIST_VAR and BUILDER_VAR
koppor Jul 3, 2023
ce0b578
Add --system-modules [batch-size=<N>]
koppor Jul 3, 2023
b3835aa
Refine comment
koppor Jul 3, 2023
d96e467
Update src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/S…
koppor Jul 4, 2023
827636c
Update src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/S…
koppor Jul 4, 2023
8840c72
Update src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/S…
koppor Jul 4, 2023
4930dee
Replace non-final wrapper by local variable
koppor Jul 4, 2023
b127267
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 5, 2023
94db69b
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 6, 2023
86f2562
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 7, 2023
daeeeb7
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 8, 2023
15e61b2
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 10, 2023
94dc1a7
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 12, 2023
1ecbbc6
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 13, 2023
7a12819
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 14, 2023
c677b03
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 15, 2023
0afed81
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 19, 2023
62d2a9f
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 20, 2023
f1e5956
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 25, 2023
c96d177
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 27, 2023
b4a7c92
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 28, 2023
da1d0a8
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Jul 29, 2023
a729b3f
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Aug 1, 2023
bc204c3
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Aug 2, 2023
10ef6dd
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Aug 3, 2023
e3d0cfe
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Aug 4, 2023
57fe348
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Aug 5, 2023
b67614c
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Aug 8, 2023
fa77b68
Merge remote-tracking branch 'upstream/master' into jdk21-fix-8240567
actions-user Aug 10, 2023
d769e13
Update main.yml fix build
Siedlerchr Aug 14, 2023
d74a4cb
Fix variable
koppor Aug 15, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/actions/upload-bundles/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ inputs:
debug-suffix:
description: 'File name suffix denoting debug level, possibly empty'
required: false
DEPLOY_KEY:
required: true

runs:
using: composite
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-cross-compile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -181,4 +181,4 @@ jobs:
uses: ./.github/actions/do-build
with:
make-target: 'hotspot ${{ inputs.make-arguments }}'
platform: linux-${{ matrix.target-cpu }}
platform: linux-${{ matrix.target-cpu }}
6 changes: 1 addition & 5 deletions .github/workflows/build-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ on:
debug-levels:
required: false
type: string
default: '[ "debug", "release" ]'
default: '[ "release" ]'
gcc-major-version:
required: true
type: string
Expand Down Expand Up @@ -74,10 +74,6 @@ jobs:
fail-fast: false
matrix:
debug-level: ${{ fromJSON(inputs.debug-levels) }}
include:
- debug-level: debug
flags: --with-debug-level=fastdebug
suffix: -debug

steps:
- name: 'Checkout the JDK source'
Expand Down
6 changes: 1 addition & 5 deletions .github/workflows/build-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ on:
debug-levels:
required: false
type: string
default: '[ "debug", "release" ]'
default: '[ "release" ]'
xcode-toolset-version:
required: true
type: string
Expand All @@ -61,10 +61,6 @@ jobs:
fail-fast: false
matrix:
debug-level: ${{ fromJSON(inputs.debug-levels) }}
include:
- debug-level: debug
flags: --with-debug-level=fastdebug
suffix: -debug

steps:
- name: 'Checkout the JDK source'
Expand Down
7 changes: 1 addition & 6 deletions .github/workflows/build-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ on:
debug-levels:
required: false
type: string
default: '[ "debug", "release" ]'
default: '[ "release" ]'
msvc-toolset-version:
required: true
type: string
Expand All @@ -54,7 +54,6 @@ on:
make-arguments:
required: false
type: string

env:
# These are needed to make the MSYS2 bash work properly
MSYS2_PATH_TYPE: minimal
Expand All @@ -72,10 +71,6 @@ jobs:
fail-fast: false
matrix:
debug-level: ${{ fromJSON(inputs.debug-levels) }}
include:
- debug-level: debug
flags: --with-debug-level=fastdebug
suffix: -debug

steps:
- name: 'Checkout the JDK source'
Expand Down
143 changes: 78 additions & 65 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,18 @@ name: 'OpenJDK GHA Sanity Checks'

on:
push:
branches-ignore:
- master
- pr/*
workflow_call:
inputs:
configure-arguments:
description: 'Additional configure arguments'
required: false
type: string
make-arguments:
description: 'Additional make arguments'
required: false
type: string
workflow_dispatch:
inputs:
platforms:
description: 'Platform(s) to execute on (comma separated, e.g. "linux-x64, macos, aarch64")'
required: true
default: 'linux-x64, linux-x86, linux-x64-variants, linux-cross-compile, macos-x64, macos-aarch64, windows-x64, windows-aarch64, docs'
configure-arguments:
description: 'Additional configure arguments'
required: false
Expand Down Expand Up @@ -68,56 +71,18 @@ jobs:
docs: ${{ steps.include.outputs.docs }}

steps:
# This function must be inlined in main.yml, or we'd be forced to checkout the repo
- name: 'Check what jobs to run'
- name: 'Set what jobs to run'
id: include
run: |
# Determine which platform jobs to run

# Returns 'true' if the input platform list matches any of the platform monikers given as argument,
# 'false' otherwise.
# arg $1: platform name or names to look for
function check_platform() {
if [[ $GITHUB_EVENT_NAME == workflow_dispatch ]]; then
input='${{ github.event.inputs.platforms }}'
elif [[ $GITHUB_EVENT_NAME == push ]]; then
if [[ '${{ !secrets.JDK_SUBMIT_FILTER || startsWith(github.ref, 'refs/heads/submit/') }}' == 'false' ]]; then
# If JDK_SUBMIT_FILTER is set, and this is not a "submit/" branch, don't run anything
>&2 echo 'JDK_SUBMIT_FILTER is set and not a "submit/" branch'
echo 'false'
return
else
input='${{ secrets.JDK_SUBMIT_PLATFORMS }}'
fi
fi

normalized_input="$(echo ,$input, | tr -d ' ')"
if [[ "$normalized_input" == ",," ]]; then
# For an empty input, assume all platforms should run
echo 'true'
return
else
# Check for all acceptable platform names
for part in $* ; do
if echo "$normalized_input" | grep -q -e ",$part," ; then
echo 'true'
return
fi
done
fi

echo 'false'
}

echo "linux-x64=$(check_platform linux-x64 linux x64)" >> $GITHUB_OUTPUT
echo "linux-x86=$(check_platform linux-x86 linux x86)" >> $GITHUB_OUTPUT
echo "linux-x64-variants=$(check_platform linux-x64-variants variants)" >> $GITHUB_OUTPUT
echo "linux-cross-compile=$(check_platform linux-cross-compile cross-compile)" >> $GITHUB_OUTPUT
echo "macos-x64=$(check_platform macos-x64 macos x64)" >> $GITHUB_OUTPUT
echo "macos-aarch64=$(check_platform macos-aarch64 macos aarch64)" >> $GITHUB_OUTPUT
echo "windows-x64=$(check_platform windows-x64 windows x64)" >> $GITHUB_OUTPUT
echo "windows-aarch64=$(check_platform windows-aarch64 windows aarch64)" >> $GITHUB_OUTPUT
echo "docs=$(check_platform docs)" >> $GITHUB_OUTPUT
echo "linux-x64=true" >> $GITHUB_OUTPUT
echo "linux-x86=false" >> $GITHUB_OUTPUT
echo "linux-x64-variants=false" >> $GITHUB_OUTPUT
echo "linux-cross-compile=false" >> $GITHUB_OUTPUT
echo "macos-x64=true" >> $GITHUB_OUTPUT
echo "macos-aarch64=true" >> $GITHUB_OUTPUT
echo "windows-x64=true" >> $GITHUB_OUTPUT
echo "windows-aarch64=false" >> $GITHUB_OUTPUT
echo "docs=false" >> $GITHUB_OUTPUT

###
### Build jobs
Expand All @@ -130,7 +95,7 @@ jobs:
with:
platform: linux-x64
gcc-major-version: '10'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
configure-arguments: ${{ github.event.inputs.configure-arguments }}
make-arguments: ${{ github.event.inputs.make-arguments }}
# The linux-x64 jdk bundle is used as buildjdk for the cross-compile job
Expand All @@ -144,7 +109,7 @@ jobs:
platform: linux-x86
gcc-major-version: '10'
gcc-package-suffix: '-multilib'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
apt-architecture: 'i386'
# Some multilib libraries do not have proper inter-dependencies, so we have to
# install their dependencies manually.
Expand All @@ -163,7 +128,7 @@ jobs:
make-target: 'hotspot'
debug-levels: '[ "debug" ]'
gcc-major-version: '10'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
extra-conf-options: '--disable-precompiled-headers'
configure-arguments: ${{ github.event.inputs.configure-arguments }}
make-arguments: ${{ github.event.inputs.make-arguments }}
Expand All @@ -178,7 +143,7 @@ jobs:
make-target: 'hotspot'
debug-levels: '[ "debug" ]'
gcc-major-version: '10'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
extra-conf-options: '--with-jvm-variants=zero --disable-precompiled-headers'
configure-arguments: ${{ github.event.inputs.configure-arguments }}
make-arguments: ${{ github.event.inputs.make-arguments }}
Expand All @@ -193,7 +158,7 @@ jobs:
make-target: 'hotspot'
debug-levels: '[ "debug" ]'
gcc-major-version: '10'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
extra-conf-options: '--with-jvm-variants=minimal --disable-precompiled-headers'
configure-arguments: ${{ github.event.inputs.configure-arguments }}
make-arguments: ${{ github.event.inputs.make-arguments }}
Expand All @@ -209,7 +174,7 @@ jobs:
# Technically this is not the "debug" level, but we can't inject a new matrix state for just this job
debug-levels: '[ "debug" ]'
gcc-major-version: '10'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
extra-conf-options: '--with-debug-level=optimized --disable-precompiled-headers'
configure-arguments: ${{ github.event.inputs.configure-arguments }}
make-arguments: ${{ github.event.inputs.make-arguments }}
Expand All @@ -223,8 +188,8 @@ jobs:
uses: ./.github/workflows/build-cross-compile.yml
with:
gcc-major-version: '10'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-cross-version: '10.4.0-4ubuntu1~22.04cross1'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
apt-gcc-cross-version: '10.5.0-1ubuntu1~22.04cross1'
configure-arguments: ${{ github.event.inputs.configure-arguments }}
make-arguments: ${{ github.event.inputs.make-arguments }}
if: needs.select.outputs.linux-cross-compile == 'true'
Expand Down Expand Up @@ -290,7 +255,7 @@ jobs:
# build JDK, and we do not need the additional testing of the graphs.
extra-conf-options: '--disable-full-docs'
gcc-major-version: '10'
apt-gcc-version: '10.4.0-4ubuntu1~22.04'
apt-gcc-version: '10.5.0-1ubuntu1~22.04'
configure-arguments: ${{ github.event.inputs.configure-arguments }}
make-arguments: ${{ github.event.inputs.make-arguments }}
if: needs.select.outputs.docs == 'true'
Expand All @@ -301,6 +266,7 @@ jobs:

test-linux-x64:
name: linux-x64
if: false
needs:
- build-linux-x64
uses: ./.github/workflows/test.yml
Expand All @@ -311,6 +277,7 @@ jobs:

test-linux-x86:
name: linux-x86
if: false
needs:
- build-linux-x86
uses: ./.github/workflows/test.yml
Expand All @@ -321,6 +288,7 @@ jobs:

test-macos-x64:
name: macos-x64
if: false
needs:
- build-macos-x64
uses: ./.github/workflows/test.yml
Expand All @@ -331,6 +299,7 @@ jobs:

test-windows-x64:
name: windows-x64
if: false
needs:
- build-windows-x64
uses: ./.github/workflows/test.yml
Expand All @@ -343,7 +312,7 @@ jobs:
remove-bundles:
name: 'Remove bundle artifacts'
runs-on: ubuntu-22.04
if: always()
if: false
needs:
- build-linux-x64
- build-linux-x86
Expand Down Expand Up @@ -385,3 +354,47 @@ jobs:
-X DELETE "$url" \
|| echo "Failed to remove bundle"
done

upload-bundles:
name: Upload to builds.jabref.org
runs-on: ubuntu-22.04
needs:
- build-linux-x64
- build-macos-x64
- build-macos-aarch64
- build-windows-x64
steps:
- name: Get bundles-linux-x64
uses: actions/download-artifact@v3
with:
name: bundles-linux-x64
path: bundles
- name: Get bundles-macos-aarch64
uses: actions/download-artifact@v3
with:
name: bundles-macos-aarch64
path: bundles
- name: Get bundles-macos-x64
uses: actions/download-artifact@v3
with:
name: bundles-macos-x64
path: bundles
- name: Get bundles-windows-x64
uses: actions/download-artifact@v3
with:
name: bundles-windows-x64
path: bundles
- name: Remove obsolete files
run: |
rm bundles/symbols*
rm bundles/tests*
- name: rsync
uses: Pendect/action-rsyncer@v2.0.0
env:
DEPLOY_KEY: ${{ secrets.BUILDJABREFPRIVATEKEY }}
with:
flags: -vazr --itemize-changes --stats --partial-dir=/tmp/partial
options: ''
ssh_options: '-p 9922'
src: 'bundles/'
dest: jrrsync@build-upload.jabref.org:/var/www/files.jabref.org/www/jdks/
34 changes: 34 additions & 0 deletions .github/workflows/sync-fork.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: 'Upstream Sync'

on:
schedule:
- cron: '5 2 * * *'
workflow_dispatch:

jobs:
sync_latest_from_upstream:
runs-on: ubuntu-latest
name: Sync latest commits from upstream repo

steps:
- name: Checkout target repo
uses: actions/checkout@v3
with:
ref: jdk21-fix-8240567
fetch-depth: '0'

- name: Sync upstream changes
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Actions"
git remote add upstream https://github.com/openjdk/jdk21.git
git fetch upstream
git merge upstream/master
git push

build:
# The GitHub trigger "push" does not trigger if a push happens inside a workflow.
# Thus, we manually trigger building
needs: sync_latest_from_upstream
uses: ./.github/workflows/main.yml
secrets: inherit
Loading