Hi Martin,

On 2018-09-03 06:01 AM, Martin Jambor wrote:
> Hi,
> 
> On Fri, Aug 31 2018, Michael Ploujnikov wrote:
>> I've done some more digging into the current uses of
>> numbered_clone_function_name and checked if any tests fail if I change
>> it to suffixed_function_name:
>>
>>   - gcc/cgraphclones.c:  DECL_NAME (new_decl) = numbered_clone_function_name 
>> (thunk->decl, "artificial_thunk");
>>     - no new tests fail, inconclusive
>>     - and despite the comment on redirect_callee_duplicating_thunks
>>       about "one or more" duplicates it doesn't seem like
>>       duplicate_thunk_for_node would be called more than once for each
>>       node, assuming each node is named uniquely, but I'm far from an
>>       expert in this area
> 
> The comment means that if there is a chain of thunks, the method clones
> all of them.  Nevertheless, you need name numbering here for the same
> reason why you need them for constprop.
> 
> 
>>   - gcc/omp-expand.c:  DECL_NAME (kern_fndecl) = 
>> numbered_clone_function_name (kern_fndecl, "kernel");
>>     - no new tests fail, inconclusive
>>     - I didn't see (and couldn't figure out a way to get) any of the
>>       existing omp/acc tests actually exercise this codeptah
> 
> I guess this one should not need it.  Build with
> --enable-offload-targets=hsa and run gomp.exp to try yourself.  I can
> run run-time HSA tests for you if you want.
> 
> Martin
> 

I've tried building with numbered_clone_function_name replaced by
suffixed_function_name and with --enable-offload-targets=hsa and
didn't see any errors in gomp.exp. I don't have a readily available
HSA setup so if you could do a quick test, I would really appreciate
it!

- Michael

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to