Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-20 Thread Richard Biener
On Wed, Sep 19, 2018 at 5:11 PM Julian Brown wrote: > > On Fri, 14 Sep 2018 22:49:35 -0400 > Julian Brown wrote: > > > > > On 12/09/18 16:16, Richard Biener wrote: > > > > It may well be that there's a better way to solve the problem, or > > > > at least to do the lookups. > > > > > > > > It may

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-19 Thread Julian Brown
On Fri, 14 Sep 2018 22:49:35 -0400 Julian Brown wrote: > > > On 12/09/18 16:16, Richard Biener wrote: > > > It may well be that there's a better way to solve the problem, or > > > at least to do the lookups. > > > > > > It may also be that there are some unintended consequences, such > > > a

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-14 Thread Julian Brown
On Wed, 12 Sep 2018 13:34:06 -0400 Julian Brown wrote: > On Wed, 12 Sep 2018 17:31:58 +0100 > Andrew Stubbs wrote: > > > On 12/09/18 16:16, Richard Biener wrote: > > > I think the symptom GCN sees needs to be better understood - like > > > wheter it is generally OK to mangle things arbitraril

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-12 Thread Julian Brown
On Wed, 12 Sep 2018 17:31:58 +0100 Andrew Stubbs wrote: > On 12/09/18 16:16, Richard Biener wrote: > > I think the symptom GCN sees needs to be better understood - like > > wheter it is generally OK to mangle things arbitrarily. > > The name mangling is a horrible workaround for a bug in the H

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-12 Thread Andrew Stubbs
On 12/09/18 16:16, Richard Biener wrote: I think the symptom GCN sees needs to be better understood - like wheter it is generally OK to mangle things arbitrarily. The name mangling is a horrible workaround for a bug in the HSA runtime code (which we do not own, cannot fix, and would want to su

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-12 Thread Richard Biener
On Wed, Sep 12, 2018 at 5:07 PM Jeff Law wrote: > > On 9/12/18 8:42 AM, Richard Biener wrote: > > On Wed, Sep 12, 2018 at 12:56 AM Jeff Law wrote: > >> > >> On 9/5/18 5:48 AM, a...@codesourcery.com wrote: > >>> > >>> The HSA GPU drivers can't cope with binaries that have the same symbol > >>> de

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-12 Thread Jeff Law
On 9/12/18 8:42 AM, Richard Biener wrote: > On Wed, Sep 12, 2018 at 12:56 AM Jeff Law wrote: >> >> On 9/5/18 5:48 AM, a...@codesourcery.com wrote: >>> >>> The HSA GPU drivers can't cope with binaries that have the same symbol >>> defined >>> multiple times, even though the names are not exported.

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-12 Thread Richard Biener
On Wed, Sep 12, 2018 at 12:56 AM Jeff Law wrote: > > On 9/5/18 5:48 AM, a...@codesourcery.com wrote: > > > > The HSA GPU drivers can't cope with binaries that have the same symbol > > defined > > multiple times, even though the names are not exported. This happens > > whenever > > there are fil

Re: [PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-11 Thread Jeff Law
On 9/5/18 5:48 AM, a...@codesourcery.com wrote: > > The HSA GPU drivers can't cope with binaries that have the same symbol defined > multiple times, even though the names are not exported. This happens whenever > there are file-scope static variables with matching names. I believe it's > also >

[PATCH 03/25] Improve TARGET_MANGLE_DECL_ASSEMBLER_NAME.

2018-09-05 Thread ams
The HSA GPU drivers can't cope with binaries that have the same symbol defined multiple times, even though the names are not exported. This happens whenever there are file-scope static variables with matching names. I believe it's also an issue with switch tables. This is a bug, but outside our