Skip to content

8293474: RISC-V: Unify the way of moving function pointer #33

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

DingliZhang
Copy link
Member

@DingliZhang DingliZhang commented Sep 27, 2024

Please review this backport to riscv-port-jdk11u.
Backport of JDK-8293474.
Applies not cleanly due to context difference, and changes in shenandoahBarrierSetAssembler_riscv.cpp have been modified previously.

Testing:

  • Tier1 passed without new failure on lp4a (release).

Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issue

  • JDK-8293474: RISC-V: Unify the way of moving function pointer (Enhancement - P4)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/riscv-port-jdk11u.git pull/33/head:pull/33
$ git checkout pull/33

Update a local copy of the PR:
$ git checkout pull/33
$ git pull https://git.openjdk.org/riscv-port-jdk11u.git pull/33/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 33

View PR using the GUI difftool:
$ git pr show -t 33

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/riscv-port-jdk11u/pull/33.diff

Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Sep 27, 2024

👋 Welcome back dzhang! A progress list of the required criteria for merging this PR into riscv-port will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk
Copy link

openjdk bot commented Sep 27, 2024

@DingliZhang This change now passes all automated pre-integration checks.

After integration, the commit message for the final commit will be:

8293474: RISC-V: Unify the way of moving function pointer

Reviewed-by: gcao, fyang

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 15 new commits pushed to the riscv-port branch:

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the riscv-port branch, type /integrate in a new comment.

@openjdk openjdk bot changed the title Backport fc5f97fe379825cb927666ae26aef00082cfae56 8293474: RISC-V: Unify the way of moving function pointer Sep 27, 2024
@openjdk
Copy link

openjdk bot commented Sep 27, 2024

This backport pull request has now been updated with issue from the original commit.

@openjdk openjdk bot added backport rfr Pull request is ready for review labels Sep 27, 2024
@mlbridge
Copy link

mlbridge bot commented Sep 27, 2024

Webrevs

Copy link
Member

@zifeihan zifeihan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Oct 9, 2024
@DingliZhang
Copy link
Member Author

Thanks all for the review.
/integrate

@openjdk
Copy link

openjdk bot commented Oct 9, 2024

Going to push as commit d46c73c.
Since your change was applied there have been 15 commits pushed to the riscv-port branch:

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Oct 9, 2024
@openjdk openjdk bot closed this Oct 9, 2024
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Oct 9, 2024
@openjdk
Copy link

openjdk bot commented Oct 9, 2024

@DingliZhang Pushed as commit d46c73c.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@andreas-schwab
Copy link

andreas-schwab commented Oct 9, 2024

This is causing a crash during boostrap, please revert.

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (output.cpp:1491), pid=174079, tid=174883
#  guarantee((int)(blk_starts[i+1] - blk_starts[i]) >= (current_offset - blk_offset)) failed: shouldn't increase block size
#
# JRE version: OpenJDK Runtime Environment (11.0.24+8) (build 11.0.24+8-suse-370.1-riscv64)
# Java VM: OpenJDK 64-Bit Server VM (11.0.24+8-suse-370.1-riscv64, mixed mode, tiered, compressed oops, g1 gc, linux-riscv64)
# Core dump will be written. Default location: /.build/cores/174079
#
# An error report file with more information is saved as:
# /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/make/hs_err_pid174079.log
[thread 174088 also had an error]
#
# Compiler replay data is saved as:
# /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/make/replay_pid174079.log
#
# If you would like to submit a bug report, please visit:
#   https://bugreport.java.com/bugreport/crash.jsp
#
/usr/bin/bash: line 1: 174079 Aborted                 /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/jdk/bin/jlink -J-Djlink.debug=true --module-path /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/images/jmods --endian little --release-info /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/jdk/release --order-resources=**module-info.class,@/home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/link_opt/classlist,/java.base/java/**,/java.base/jdk/**,/java.base/sun/**,/java.base/com/**,/jdk.localedata/** --dedup-legal-notices=error-if-not-same-content --generate-jli-classes=@/home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/link_opt/default_jli_trace.txt --add-modules java.base,java.compiler,java.datatransfer,java.desktop,java.instrument,java.logging,java.management,java.management.rmi,java.naming,java.net.http,java.prefs,java.rmi,java.scripting,java.se,java.security.jgss,java.security.sasl,java.smartcardio,java.sql,java.sql.rowset,java.transaction.xa,java.xml,java.xml.crypto,jdk.accessibility,jdk.attach,jdk.charsets,jdk.compiler,jdk.crypto.cryptoki,jdk.crypto.ec,jdk.dynalink,jdk.editpad,jdk.hotspot.agent,jdk.httpserver,jdk.internal.ed,jdk.internal.jvmstat,jdk.internal.le,jdk.internal.opt,jdk.jartool,jdk.javadoc,jdk.jcmd,jdk.jconsole,jdk.jdeps,jdk.jdi,jdk.jdwp.agent,jdk.jfr,jdk.jlink,jdk.jshell,jdk.jsobject,jdk.jstatd,jdk.localedata,jdk.management,jdk.management.agent,jdk.management.jfr,jdk.naming.dns,jdk.naming.ldap,jdk.naming.rmi,jdk.net,jdk.pack,jdk.rmic,jdk.scripting.nashorn,jdk.scripting.nashorn.shell,jdk.sctp,jdk.security.auth,jdk.security.jgss,jdk.unsupported,jdk.unsupported.desktop,jdk.xml.dom,jdk.zipfs --output /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/images/jdk > >(/usr/bin/tee -a /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/images/jdk.log) 2> >(/usr/bin/tee -a /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/images/jdk.log 1>&2)

@andreas-schwab
Copy link

andreas-schwab commented Oct 10, 2024

With slowdebug:

 1894	Epilog	===  [[]]   [-2147234809]
# pop frame 112
	add  sp, sp, #112
	ld  ra, [sp,#-16]
	ld  fp, [sp,#-8]
	# touch polling page
	li  t0, #0x7f4cb960e000
	ld  zr, [t0] n_size (272), current_offset (1316), instr_offset (1036)
Could not load hsdis-riscv64.so; library not loadable; PrintAssembly is disabled
 ------------------- 
# To suppress the following error report, specify this argument
# after -XX: or in .hotspotrc:  SuppressErrorAt=/output.cpp:1416
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/src/hotspot/share/opto/output.cpp:1416), pid=366339, tid=366381
#  assert(false) failed: wrong size of mach node

@DingliZhang
Copy link
Member Author

This is causing a crash during boostrap, please revert.

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (output.cpp:1491), pid=174079, tid=174883
#  guarantee((int)(blk_starts[i+1] - blk_starts[i]) >= (current_offset - blk_offset)) failed: shouldn't increase block size
#
# JRE version: OpenJDK Runtime Environment (11.0.24+8) (build 11.0.24+8-suse-370.1-riscv64)
# Java VM: OpenJDK 64-Bit Server VM (11.0.24+8-suse-370.1-riscv64, mixed mode, tiered, compressed oops, g1 gc, linux-riscv64)
# Core dump will be written. Default location: /.build/cores/174079
#
# An error report file with more information is saved as:
# /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/make/hs_err_pid174079.log
[thread 174088 also had an error]
#
# Compiler replay data is saved as:
# /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/make/replay_pid174079.log
#
# If you would like to submit a bug report, please visit:
#   https://bugreport.java.com/bugreport/crash.jsp
#
/usr/bin/bash: line 1: 174079 Aborted                 /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/jdk/bin/jlink -J-Djlink.debug=true --module-path /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/images/jmods --endian little --release-info /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/jdk/release --order-resources=**module-info.class,@/home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/link_opt/classlist,/java.base/java/**,/java.base/jdk/**,/java.base/sun/**,/java.base/com/**,/jdk.localedata/** --dedup-legal-notices=error-if-not-same-content --generate-jli-classes=@/home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/link_opt/default_jli_trace.txt --add-modules java.base,java.compiler,java.datatransfer,java.desktop,java.instrument,java.logging,java.management,java.management.rmi,java.naming,java.net.http,java.prefs,java.rmi,java.scripting,java.se,java.security.jgss,java.security.sasl,java.smartcardio,java.sql,java.sql.rowset,java.transaction.xa,java.xml,java.xml.crypto,jdk.accessibility,jdk.attach,jdk.charsets,jdk.compiler,jdk.crypto.cryptoki,jdk.crypto.ec,jdk.dynalink,jdk.editpad,jdk.hotspot.agent,jdk.httpserver,jdk.internal.ed,jdk.internal.jvmstat,jdk.internal.le,jdk.internal.opt,jdk.jartool,jdk.javadoc,jdk.jcmd,jdk.jconsole,jdk.jdeps,jdk.jdi,jdk.jdwp.agent,jdk.jfr,jdk.jlink,jdk.jshell,jdk.jsobject,jdk.jstatd,jdk.localedata,jdk.management,jdk.management.agent,jdk.management.jfr,jdk.naming.dns,jdk.naming.ldap,jdk.naming.rmi,jdk.net,jdk.pack,jdk.rmic,jdk.scripting.nashorn,jdk.scripting.nashorn.shell,jdk.sctp,jdk.security.auth,jdk.security.jgss,jdk.unsupported,jdk.unsupported.desktop,jdk.xml.dom,jdk.zipfs --output /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/images/jdk > >(/usr/bin/tee -a /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/images/jdk.log) 2> >(/usr/bin/tee -a /home/abuild/rpmbuild/BUILD/jdk11u-jdk-11.0.24-8/build/support/images/jdk.log 1>&2)

I use this as bootjdk and compiled on the commit d46c73c4d90670a06f8351bde444a3f4e5c0fc41 using the following command:

bash configure \
--disable-warnings-as-errors \
--with-boot-jdk=/home/dingli/jdk-bin/openjdk-11/jdk

time make bootcycle-images

It can be built successfully.

Could you please try the same bootjdk ? Also can you give reproduction conditions? Thanks a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

4 participants