<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/64284>64284</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Link failure with llvm-mainline (version 18)
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
rgayatri23
</td>
</tr>
</table>
<pre>
While building OpenMP offload enabled Kokkos unit tests
Hardware - NVIDIA A100
Kokkos version - develop branch with sha `6cffdb416`
### WIth clang-mainline(version 18, git-sha - 63f8922f49b2)
Linking error
```shell
nvlink error : Multiple definition of '__omp_offloading_d61f715a_400003bc__ZNK6Kokkos4Impl11ParallelForINS0_8ViewFillINS_4ViewIPjJNS_11LayoutRightENS_6DeviceINS_12Experimental12OpenMPTargetENS_14AnonymousSpaceEEENS_12MemoryTraitsILj0EEEEEES5_S8_Li1EiEENS_11RangePolicyIJS8_NS_9IndexTypeIiEEEEES8_E12execute_implIvEEvv_l54_kernel_environment' in '/tmp/TestOpenMPTarget_Atomics.cpp-nvptx64-nvidia-cuda-sm_80-8ccbfc.cubin', first defined in '/tmp/TestOpenMPTarget_AtomicOperations_unsignedint.cpp-nvptx64-nvidia-cuda-sm_80-fc86d6.cubin'
nvlink error : Multiple definition of '__omp_offloading_d61f715a_400003bc__ZNK6Kokkos4Impl11ParallelForINS0_8ViewFillINS_4ViewIPjJNS_11LayoutRightENS_6DeviceINS_12Experimental12OpenMPTargetENS_14AnonymousSpaceEEENS_12MemoryTraitsILj0EEEEEES5_S8_Li1ElEENS_11RangePolicyIJS8_NS_9IndexTypeIlEEEEES8_E12execute_implIvEEvv_l54_kernel_environment' in '/tmp/TestOpenMPTarget_Atomics.cpp-nvptx64-nvidia-cuda-sm_80-8ccbfc.cubin', first defined in '/tmp/TestOpenMPTarget_AtomicOperations_unsignedint.cpp-nvptx64-nvidia-cuda-sm_80-fc86d6.cubin'
nvlink error : Multiple definition of '__omp_offloading_d61f715a_400003bc__ZNK6Kokkos4Impl11ParallelForINS0_16ViewValueFunctorINS_6DeviceINS_12Experimental12OpenMPTargetENS4_17OpenMPTargetSpaceEEEjLb1EEENS_11RangePolicyIJS5_NS_9IndexTypeIlEEEEES5_E12execute_implIvEEvv_l54_kernel_environment' in '/tmp/TestOpenMPTarget_Atomics.cpp-nvptx64-nvidia-cuda-sm_80-8ccbfc.cubin', first defined in '/tmp/TestOpenMPTarget_AtomicOperations_unsignedint.cpp-nvptx64-nvidia-cuda-sm_80-fc86d6.cubin'
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzsVt9vnDgQ_mu8LxYr2_xYeNiHvWZXR5tuo26USvdiGTOAE2Mj25Dsf38CErVXVbre070EWSDG880MMx_6LLxXrQHYo_QPlN5sxBg66_auFVcRnGLxprL1df-tUxpwNSpdK9PiLwOYz3fYNo22osZgRKWhxp_s05P1eDQq4AA-eERuEDn8KVz9LBzgCJ8fypvygA-UkHXvFTKB88oaHOEaJtB2wJUTRnb4WYUO-05glJFMNk1dJTRD2Sv69c7ideFvZeiw1MK0US-U0coAYvlbcJoj9gG3KkRzwAhncZMXjDVJUTHEijXYrTJP8yeCc9b9I0tG1uU70Hq1mUkr87T6YoxRfMCfRx3UoAHX0CijwpzYNhixHee2H_hrz5RpeZ3RZkdTwRNCCIkryflf50_Z2pKk7AdN6Z1wQmvQJ-vK84Xw_EHB80lpXZ4vPJlfyrvHj-cLp_RWXO0Yvqq2C8fzhWc3MCkJsx9lx5cBnOrBBKEpW8d3L1wLiytNDsaaa29HfxmEhONxsbLP0Ft3vXdCBV_ePpLjcl1Sfsn5raJHtfrRr8K0cGe1ktfy4yXn5wsvSlPDy_11gFKtqJwfKYMXkGMArvpBl9PxOE1cpwl_AmdAczCTctbMZSK2w8rMbUPsFPoBsdM9-PBj5fwQbK-k38phiMw0hJcsicykaiUiOdYi8j3PSZRLWTVyK8dKmSXcB9wo58M6IKh_M82XAZyY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