Commit c24b9ca
authored
[OpenMP] Provide __kmp_unnamed_critical_addr on SPARC (llvm#138517)
`libomp.so` currently fails to link on SPARC, both Solaris/sparcv9 and
Linux/sparc64:
```
Undefined first referenced
symbol in file
__kmp_unnamed_critical_addr projects/openmp/runtime/src/CMakeFiles/omp.dir/kmp_gsupport.cpp.o
ld: fatal: symbol referencing errors
```
This patch provides the necessary definition. While at it, I noticed
that on non-x86 targets the symbol wasn't marked as `@object`, which
this patch corrects, too.
Tested on `sparcv9-sun-solaris2.11`, `sparc64-unknown-linux-gnu`,
`amd64-pc-solaris2.11`, and `x86_64-pc-linux-gnu`.1 parent 30ec488 commit c24b9ca
1 file changed
+6
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2470 | 2470 | | |
2471 | 2471 | | |
2472 | 2472 | | |
2473 | | - | |
| 2473 | + | |
2474 | 2474 | | |
2475 | 2475 | | |
2476 | 2476 | | |
| |||
2482 | 2482 | | |
2483 | 2483 | | |
2484 | 2484 | | |
| 2485 | + | |
2485 | 2486 | | |
2486 | 2487 | | |
2487 | | - | |
| 2488 | + | |
2488 | 2489 | | |
2489 | 2490 | | |
2490 | 2491 | | |
2491 | | - | |
| 2492 | + | |
2492 | 2493 | | |
2493 | 2494 | | |
2494 | 2495 | | |
| |||
2500 | 2501 | | |
2501 | 2502 | | |
2502 | 2503 | | |
| 2504 | + | |
2503 | 2505 | | |
2504 | 2506 | | |
2505 | 2507 | | |
2506 | 2508 | | |
2507 | | - | |
| 2509 | + | |
2508 | 2510 | | |
2509 | 2511 | | |
2510 | 2512 | | |
| |||
0 commit comments