Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-30 Thread Jiangli Zhou
On Wed, 17 Jan 2024 00:14:58 GMT, Jiangli Zhou wrote: > Please review this PR with a simple solution for resolving duplicate `Thread` > symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there > was an alternative suggestion to redefine the symbol at build time, such as > us

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-30 Thread Ioi Lam
On Tue, 30 Jan 2024 12:13:00 GMT, Andrew Haley wrote: > > The only "perfect" solution is putting the HotSpot code in a namespace. > > This is going to be a huge undertaking. I don't think we have enough > > interest in the OpenJDK community to make such a change now. > > I don't think that put

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-30 Thread Andrew Haley
On Tue, 30 Jan 2024 12:01:56 GMT, Ioi Lam wrote: > The only "perfect" solution is putting the HotSpot code in a namespace. This > is going to be a huge undertaking. I don't think we have enough interest in > the OpenJDK community to make such a change now. I don't think that putting all of the

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-30 Thread Ioi Lam
On Tue, 30 Jan 2024 10:27:08 GMT, Andrew Haley wrote: > > > > Maybe we could live with symbol redefinition using #define > > > > (conditionally for static linking in OpenJDK, as Coleen suggested > > > > earlier) for now, until the tooling can support symbol localizing > > > > better. Then loca

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-30 Thread Andrew Haley
On Tue, 30 Jan 2024 04:20:21 GMT, Jiangli Zhou wrote: > > > Maybe we could live with symbol redefinition using #define (conditionally > > > for static linking in OpenJDK, as Coleen suggested earlier) for now, > > > until the tooling can support symbol localizing better. Then localizing > > > s

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-29 Thread Jiangli Zhou
On Mon, 29 Jan 2024 09:42:20 GMT, Andrew Haley wrote: > > Maybe we could live with symbol redefinition using #define (conditionally > > for static linking in OpenJDK, as Coleen suggested earlier) for now, until > > the tooling can support symbol localizing better. Then localizing symbols > > u

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-29 Thread Andrew Haley
On Wed, 24 Jan 2024 22:30:38 GMT, Jiangli Zhou wrote: > Maybe we could live with symbol redefinition using #define (conditionally for > static linking in OpenJDK, as Coleen suggested earlier) for now, until the > tooling can support symbol localizing better. Then localizing symbols using > too

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-24 Thread Jiangli Zhou
On Wed, 24 Jan 2024 09:29:16 GMT, Andrew Haley wrote: > > > I think you should be able to use ld and objcopy to merge the .o files > > > and hide all of the symbols you don't want to export. > > > > > > We also discussed about `objcopy` in [#14808 > > (comment)](https://github.com/openjdk/jdk

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-24 Thread Andrew Haley
On Wed, 17 Jan 2024 00:14:58 GMT, Jiangli Zhou wrote: > Please review this PR with a simple solution for resolving duplicate `Thread` > symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there > was an alternative suggestion to redefine the symbol at build time, such as > us

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-21 Thread Jiangli Zhou
On Sat, 20 Jan 2024 18:00:15 GMT, Andrew Haley wrote: > > > You could support one build by adding something like > > > -DSUPPORTS_STATIC_LINK for both .so and .a builds for Google, then use > > > that to protect the renaming. > > > > > > Thanks, @coleenp. I think that could work for all diffe

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-20 Thread Andrew Haley
On Fri, 19 Jan 2024 20:21:21 GMT, Jiangli Zhou wrote: > > You could support one build by adding something like -DSUPPORTS_STATIC_LINK > > for both .so and .a builds for Google, then use that to protect the > > renaming. > > Thanks, @coleenp. I think that could work for all different cases. I'l

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-19 Thread Jiangli Zhou
On Fri, 19 Jan 2024 14:00:58 GMT, Coleen Phillimore wrote: > You could support one build by adding something like -DSUPPORTS_STATIC_LINK > for both .so and .a builds for Google, then use that to protect the renaming. Thanks, @coleenp. I think that could work for all different cases. I'll reflec

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-19 Thread Jiangli Zhou
On Fri, 19 Jan 2024 08:58:29 GMT, Andrew Haley wrote: > > > > It seems that we may be converging on using hotspot namespace? > > > > > > > > > Based on previous discussions I had been expecting to see a JEP on this > > > after last US summer. I was surprised to see this PR pop up in this form.

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-19 Thread Coleen Phillimore
On Wed, 17 Jan 2024 00:14:58 GMT, Jiangli Zhou wrote: > Please review this PR with a simple solution for resolving duplicate `Thread` > symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there > was an alternative suggestion to redefine the symbol at build time, such as > us

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-19 Thread Andrew Haley
On Fri, 19 Jan 2024 02:09:15 GMT, Jiangli Zhou wrote: > > > It seems that we may be converging on using hotspot namespace? > > > > > > Based on previous discussions I had been expecting to see a JEP on this > > after last US summer. I was surprised to see this PR pop up in this form. > > Ah,

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-18 Thread Jiangli Zhou
On Fri, 19 Jan 2024 01:57:58 GMT, David Holmes wrote: > > It seems that we may be converging on using hotspot namespace? > > Based on previous discussions I had been expecting to see a JEP on this after > last US summer. I was surprised to see this PR pop up in this form. Ah, I see. Thanks for

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-18 Thread David Holmes
On Thu, 18 Jan 2024 18:56:23 GMT, Jiangli Zhou wrote: > It seems that we may be converging on using hotspot namespace? Based on previous discussions I had been expecting to see a JEP on this after last US summer. I was surprised to see this PR pop up in this form. - PR Comment: ht

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-18 Thread Jiangli Zhou
On Wed, 17 Jan 2024 23:06:19 GMT, Coleen Phillimore wrote: >> Please review this PR with a simple solution for resolving duplicate >> `Thread` symbol issue. In https://github.com/openjdk/jdk/pull/14808 >> comments, there was an alternative suggestion to redefine the symbol at >> build time, su

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-17 Thread David Holmes
On Wed, 17 Jan 2024 00:14:58 GMT, Jiangli Zhou wrote: > Please review this PR with a simple solution for resolving duplicate `Thread` > symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there > was an alternative suggestion to redefine the symbol at build time, such as > us

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-17 Thread David Holmes
On Wed, 17 Jan 2024 00:14:58 GMT, Jiangli Zhou wrote: > Please review this PR with a simple solution for resolving duplicate `Thread` > symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there > was an alternative suggestion to redefine the symbol at build time, such as > us

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-17 Thread Coleen Phillimore
On Wed, 17 Jan 2024 00:14:58 GMT, Jiangli Zhou wrote: > Please review this PR with a simple solution for resolving duplicate `Thread` > symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there > was an alternative suggestion to redefine the symbol at build time, such as > us

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-17 Thread Jiangli Zhou
On Wed, 17 Jan 2024 10:07:15 GMT, Andrew Haley wrote: >> Please review this PR with a simple solution for resolving duplicate >> `Thread` symbol issue. In https://github.com/openjdk/jdk/pull/14808 >> comments, there was an alternative suggestion to redefine the symbol at >> build time, such as

Re: RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-17 Thread Andrew Haley
On Wed, 17 Jan 2024 00:14:58 GMT, Jiangli Zhou wrote: > Please review this PR with a simple solution for resolving duplicate `Thread` > symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there > was an alternative suggestion to redefine the symbol at build time, such as > us

RFR: 8311846: Resolve duplicate 'Thread' related symbols with JDK static linking

2024-01-16 Thread Jiangli Zhou
Please review this PR with a simple solution for resolving duplicate `Thread` symbol issue. In https://github.com/openjdk/jdk/pull/14808 comments, there was an alternative suggestion to redefine the symbol at build time, such as using`-DThread=HotSpotThread`. That would not address issues when