[clang] [clang][Modules] Keep existing global definition on type mismatch in GetOrCreateLLVMGlobal (PR #223877)

via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 13 15:49:41 PDT 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results

* 56921 tests passed
* 1839 tests skipped
* 2 tests failed

## Failed Tests
(click on a test name to see its output)

### Clang
<details>
<summary>Clang.Analysis/Scalable/ssaf-orchestrator-make/bad-args.test</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
not "C:/Python312/python.exe" "C:\_work\llvm-project\llvm-project\build\bin\clang-ssaf-orchestrator-make" 2>&1 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test --check-prefix=NO-EXTRACTORS
# executed command: not C:/Python312/python.exe 'C:\_work\llvm-project\llvm-project\build\bin\clang-ssaf-orchestrator-make'
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test' --check-prefix=NO-EXTRACTORS
# note: command had no output on stdout or stderr
# RUN: at line 5
not "C:/Python312/python.exe" "C:\_work\llvm-project\llvm-project\build\bin\clang-ssaf-orchestrator-make" --extract-summaries=PointerFlow 2>&1    | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test --check-prefix=NO-BUILD
# executed command: not C:/Python312/python.exe 'C:\_work\llvm-project\llvm-project\build\bin\clang-ssaf-orchestrator-make' --extract-summaries=PointerFlow
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test' --check-prefix=NO-BUILD
# note: command had no output on stdout or stderr
# RUN: at line 9
not "C:/Python312/python.exe" "C:\_work\llvm-project\llvm-project\build\bin\clang-ssaf-orchestrator-make" --extract-summaries=PointerFlow    --ssaf-clang=/no/such/clang -- make 2>&1    | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test --check-prefix=NO-CLANG
# executed command: not C:/Python312/python.exe 'C:\_work\llvm-project\llvm-project\build\bin\clang-ssaf-orchestrator-make' --extract-summaries=PointerFlow --ssaf-clang=/no/such/clang -- make
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test' --check-prefix=NO-CLANG
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test:13:13: error: NO-CLANG: expected string not found in input
# | # NO-CLANG: --ssaf-clang: not a file: /no/such/clang
# |             ^
# | <stdin>:1:68: note: scanning from here
# | clang-ssaf-orchestrator-make: error: required tools not resolvable:
# |                                                                    ^
# | <stdin>:2:2: note: possible intended match here
# |  --ssaf-clang: /no/such/clang: not found on PATH
# |  ^
# | 
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\clang\test\Analysis\Scalable\ssaf-orchestrator-make\bad-args.test
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |             1: clang-ssaf-orchestrator-make: error: required tools not resolvable: 
# | check:13'0                                                                       {   search range start (exclusive)
# | check:13'1                                                                           error: no match found in search range
# |             2:  --ssaf-clang: /no/such/clang: not found on PATH 
# | check:13'2      ?                                                 possible intended match
# | check:13'3                                                      } search range end (exclusive)
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>
<details>
<summary>Clang.Analysis/Scalable/ssaf-orchestrator-make/unittests.test</summary>

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
env PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=C:\_work\llvm-project\llvm-project\build\lib      "C:/Python312/python.exe" -m unittest discover    -s C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make/tests -t C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make    > C:\_work\llvm-project\llvm-project\build\tools\clang\test\Analysis\Scalable\ssaf-orchestrator-make\Output\unittests.test.tmp.log 2>&1
# executed command: env PYTHONDONTWRITEBYTECODE=1 'PYTHONPATH=C:\_work\llvm-project\llvm-project\build\lib' C:/Python312/python.exe -m unittest discover -s 'C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make/tests' -t 'C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make'
# .---redirected output from 'C:\_work\llvm-project\llvm-project\build\tools\clang\test\Analysis\Scalable\ssaf-orchestrator-make\Output\unittests.test.tmp.log'
# | ........EEEEEFFFF..EEEE.EE.................EEE.....EEE..EEEE.EEE...FF...........FF.FFFFFF.FFFF.FF...F.F...FF.....................E............EEEEE..FF..........EEEEEE............................................EEEE.EEEE...F...........EEEEEE.E.........EE..EEEEEEEE...........
# | ======================================================================
# | ERROR: test_a_member_that_is_not_an_object_is_not_an_input (tests.test_ar_shim.SsafStep.test_a_member_that_is_not_an_object_is_not_an_input)
# | ----------------------------------------------------------------------
# | Traceback (most recent call last):
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 88, in test_a_member_that_is_not_an_object_is_not_an_input
# |     self._summary("build/a.o")
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 37, in _summary
# |     records.get_path_for_artifact(
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\ssaf_artifact_repository.py", line 48, in get_path_for_artifact
# |     return coalesce_root_path(
# |            ^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\utils.py", line 15, in coalesce_root_path
# |     raise ValueError("path leaves %s: %s" % (root, coalesced))
# | ValueError: path leaves C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpnnwzx7t_\out\ssaf-artifacts: C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpnnwzx7t_\project\build\a.o.summary.json
# | 
# | ======================================================================
# | ERROR: test_a_member_the_run_never_touched_is_not_an_input (tests.test_ar_shim.SsafStep.test_a_member_the_run_never_touched_is_not_an_input)
# | ----------------------------------------------------------------------
# | Traceback (most recent call last):
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 56, in test_a_member_the_run_never_touched_is_not_an_input
# |     ar.invoke_ssaf_tools(shim, self.root)
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\shims\ar.py", line 61, in invoke_ssaf_tools
# |     input_build_artifact_ids = filter_build_artifacts(
# |                                ^^^^^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\shims\commands.py", line 41, in filter_build_artifacts
# |     artifact_of(ssaf_artifact_repo, build_artifact_id, SSAFArtifactKind.SUMMARY)
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\shims\commands.py", line 27, in artifact_of
# |     if not ssaf_artifact_repo.has_artifact(ssaf_artifact_id):
# |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\ssaf_artifact_repository.py", line 55, in has_artifact
# |     return os.path.exists(self.get_path_for_artifact(ssaf_artifact_id))
# |                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\ssaf_artifact_repository.py", line 48, in get_path_for_artifact
# |     return coalesce_root_path(
# |            ^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\utils.py", line 15, in coalesce_root_path
# |     raise ValueError("path leaves %s: %s" % (root, coalesced))
# | ValueError: path leaves C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpqm656fvx\out\ssaf-artifacts: C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpqm656fvx\project\build\a.o.summary.json
# | 
# | ======================================================================
# | ERROR: test_in_the_transformation_pass_the_edits_are_merged_instead (tests.test_ar_shim.SsafStep.test_in_the_transformation_pass_the_edits_are_merged_instead)
# | ----------------------------------------------------------------------
# | Traceback (most recent call last):
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 105, in test_in_the_transformation_pass_the_edits_are_merged_instead
# |     ar.invoke_ssaf_tools(shim, self.root)
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\shims\ar.py", line 61, in invoke_ssaf_tools
# |     input_build_artifact_ids = filter_build_artifacts(
# |                                ^^^^^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\shims\commands.py", line 41, in filter_build_artifacts
# |     artifact_of(ssaf_artifact_repo, build_artifact_id, SSAFArtifactKind.SUMMARY)
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\shims\commands.py", line 27, in artifact_of
# |     if not ssaf_artifact_repo.has_artifact(ssaf_artifact_id):
# |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\ssaf_artifact_repository.py", line 55, in has_artifact
# |     return os.path.exists(self.get_path_for_artifact(ssaf_artifact_id))
# |                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\ssaf_artifact_repository.py", line 48, in get_path_for_artifact
# |     return coalesce_root_path(
# |            ^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\utils.py", line 15, in coalesce_root_path
# |     raise ValueError("path leaves %s: %s" % (root, coalesced))
# | ValueError: path leaves C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpoad3nmmj\out\ssaf-artifacts: C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpoad3nmmj\project\build\a.o.summary.json
# | 
# | ======================================================================
# | ERROR: test_the_namespace_is_the_archives_file_name_not_its_path (tests.test_ar_shim.SsafStep.test_the_namespace_is_the_archives_file_name_not_its_path)
# | ----------------------------------------------------------------------
# | Traceback (most recent call last):
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 81, in test_the_namespace_is_the_archives_file_name_not_its_path
# |     self._summary("build/a.o")
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 37, in _summary
# |     records.get_path_for_artifact(
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\ssaf_artifact_repository.py", line 48, in get_path_for_artifact
# |     return coalesce_root_path(
# |            ^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\utils.py", line 15, in coalesce_root_path
# |     raise ValueError("path leaves %s: %s" % (root, coalesced))
# | ValueError: path leaves C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpl8m4zppb\out\ssaf-artifacts: C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpl8m4zppb\project\build\a.o.summary.json
# | 
# | ======================================================================
# | ERROR: test_the_summaries_that_exist_are_handed_to_the_linker (tests.test_ar_shim.SsafStep.test_the_summaries_that_exist_are_handed_to_the_linker)
# | ----------------------------------------------------------------------
# | Traceback (most recent call last):
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 69, in test_the_summaries_that_exist_are_handed_to_the_linker
# |     self._summary("build/a.o")
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_ar_shim.py", line 37, in _summary
# |     records.get_path_for_artifact(
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\ssaf_artifact_repository.py", line 48, in get_path_for_artifact
# |     return coalesce_root_path(
# |            ^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\utils.py", line 15, in coalesce_root_path
# |     raise ValueError("path leaves %s: %s" % (root, coalesced))
# | ValueError: path leaves C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmp6ly_vqb8\out\ssaf-artifacts: C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmp6ly_vqb8\project\build\a.o.summary.json
# | 
# | ======================================================================
# | ERROR: test_a_record_whose_output_extends_another_is_not_read_back (tests.test_build_graph.BuildstepRecords.test_a_record_whose_output_extends_another_is_not_read_back)
# | ----------------------------------------------------------------------
# | Traceback (most recent call last):
# |   File "C:\_work\llvm-project\llvm-project\clang\tools\clang-ssaf-orchestrator-make\tests\test_build_graph.py", line 129, in test_a_record_whose_output_extends_another_is_not_read_back
# |     self.graph.record_build_step(
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\build_graph.py", line 46, in record_build_step
# |     path = make_parents(self.get_buildstep_record_path(output_build_artifact_id))
# |                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\build_graph.py", line 37, in get_buildstep_record_path
# |     return coalesce_root_path(
# |            ^^^^^^^^^^^^^^^^^^^
# |   File "C:\_work\llvm-project\llvm-project\build\lib\clang_ssaf_orchestrator_make\utils.py", line 15, in coalesce_root_path
# |     raise ValueError("path leaves %s: %s" % (root, coalesced))
# | ValueError: path leaves C:\Users\ContainerAdministrator\AppData\Local\Temp\lit-tmp-3x8fd_w8\tmpmf322m6r\build-graph: C:\p\prg.o.buildstep.json
# | 
# | ======================================================================
# | ERROR: test_a_summary_beside_a_record_is_not_read_as_one (tests.test_build_graph.BuildstepRecords.te
# | ...
# `---data was truncated (10240/115719) (change limit with -D output_limit=N)
# note: command had no output on stdout or stderr
# error: command failed with exit status: 1

--

```
</details>

If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.

https://github.com/llvm/llvm-project/pull/223877


More information about the cfe-commits mailing list