Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[libclang/python] Change all global variables to CAPS #132930

Merged
merged 1 commit into from
Mar 26, 2025

Conversation

DeinAlptraum
Copy link
Contributor

No description provided.

@llvmbot llvmbot added clang Clang issues not falling into any other category clang:as-a-library libclang and C++ API labels Mar 25, 2025
@llvmbot
Copy link
Member

llvmbot commented Mar 25, 2025

@llvm/pr-subscribers-clang

Author: Jannick Kremer (DeinAlptraum)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/132930.diff

7 Files Affected:

  • (modified) clang/bindings/python/clang/cindex.py (+5-5)
  • (modified) clang/bindings/python/tests/cindex/test_cdb.py (+10-10)
  • (modified) clang/bindings/python/tests/cindex/test_cursor.py (+15-15)
  • (modified) clang/bindings/python/tests/cindex/test_index.py (+3-3)
  • (modified) clang/bindings/python/tests/cindex/test_location.py (+8-8)
  • (modified) clang/bindings/python/tests/cindex/test_translation_unit.py (+16-16)
  • (modified) clang/bindings/python/tests/cindex/test_type.py (+4-4)
diff --git a/clang/bindings/python/clang/cindex.py b/clang/bindings/python/clang/cindex.py
index 3dffa88e60193..2319534a6f121 100644
--- a/clang/bindings/python/clang/cindex.py
+++ b/clang/bindings/python/clang/cindex.py
@@ -2802,7 +2802,7 @@ class _CXUnsavedFile(Structure):
 # Functions calls through the python interface are rather slow. Fortunately,
 # for most symboles, we do not need to perform a function call. Their spelling
 # never changes and is consequently provided by this spelling cache.
-spelling_cache = {
+SPELLING_CACHE = {
     # 0: CompletionChunk.Kind("Optional"),
     # 1: CompletionChunk.Kind("TypedText"),
     # 2: CompletionChunk.Kind("Text"),
@@ -2848,8 +2848,8 @@ def __repr__(self):
 
     @CachedProperty
     def spelling(self):
-        if self.__kindNumber in spelling_cache:
-            return spelling_cache[self.__kindNumber]
+        if self.__kindNumber in SPELLING_CACHE:
+            return SPELLING_CACHE[self.__kindNumber]
         return _CXString.from_result(
             conf.lib.clang_getCompletionChunkText(self.cs, self.key)
         )
@@ -3846,7 +3846,7 @@ def set_property(self, property, value):
 fields_visit_callback = CFUNCTYPE(c_int, Cursor, py_object)
 
 # Functions strictly alphabetical order.
-function_list: list[LibFunc] = [
+FUNCTION_LIST: list[LibFunc] = [
     (
         "clang_annotateTokens",
         [TranslationUnit, POINTER(Token), c_uint, POINTER(Cursor)],
@@ -4125,7 +4125,7 @@ def register_functions(lib: CDLL, ignore_errors: bool) -> None:
     def register(item: LibFunc) -> None:
         register_function(lib, item, ignore_errors)
 
-    for f in function_list:
+    for f in FUNCTION_LIST:
         register(f)
 
 
diff --git a/clang/bindings/python/tests/cindex/test_cdb.py b/clang/bindings/python/tests/cindex/test_cdb.py
index 6e31119206168..757a14fbaef2c 100644
--- a/clang/bindings/python/tests/cindex/test_cdb.py
+++ b/clang/bindings/python/tests/cindex/test_cdb.py
@@ -10,7 +10,7 @@
 import sys
 from pathlib import Path
 
-inputs_dir = os.path.join(os.path.dirname(__file__), "INPUTS")
+INPUTS_DIR = os.path.join(os.path.dirname(__file__), "INPUTS")
 
 
 @unittest.skipIf(sys.platform == "win32", "TODO: Fix these tests on Windows")
@@ -34,23 +34,23 @@ def test_create_fail(self):
 
     def test_create(self):
         """Check we can load a compilation database"""
-        CompilationDatabase.fromDirectory(inputs_dir)
+        CompilationDatabase.fromDirectory(INPUTS_DIR)
 
     def test_lookup_succeed(self):
         """Check we get some results if the file exists in the db"""
-        cdb = CompilationDatabase.fromDirectory(inputs_dir)
+        cdb = CompilationDatabase.fromDirectory(INPUTS_DIR)
         cmds = cdb.getCompileCommands("/home/john.doe/MyProject/project.cpp")
         self.assertNotEqual(len(cmds), 0)
 
     def test_lookup_succeed_pathlike(self):
         """Same as test_lookup_succeed, but with PathLikes"""
-        cdb = CompilationDatabase.fromDirectory(Path(inputs_dir))
+        cdb = CompilationDatabase.fromDirectory(Path(INPUTS_DIR))
         cmds = cdb.getCompileCommands(Path("/home/john.doe/MyProject/project.cpp"))
         self.assertNotEqual(len(cmds), 0)
 
     def test_all_compilecommand(self):
         """Check we get all results from the db"""
-        cdb = CompilationDatabase.fromDirectory(inputs_dir)
+        cdb = CompilationDatabase.fromDirectory(INPUTS_DIR)
         cmds = cdb.getAllCompileCommands()
         self.assertEqual(len(cmds), 3)
         expected = [
@@ -100,7 +100,7 @@ def test_all_compilecommand(self):
 
     def test_1_compilecommand(self):
         """Check file with single compile command"""
-        cdb = CompilationDatabase.fromDirectory(inputs_dir)
+        cdb = CompilationDatabase.fromDirectory(INPUTS_DIR)
         file = "/home/john.doe/MyProject/project.cpp"
         cmds = cdb.getCompileCommands(file)
         self.assertEqual(len(cmds), 1)
@@ -119,7 +119,7 @@ def test_1_compilecommand(self):
 
     def test_2_compilecommand(self):
         """Check file with 2 compile commands"""
-        cdb = CompilationDatabase.fromDirectory(inputs_dir)
+        cdb = CompilationDatabase.fromDirectory(INPUTS_DIR)
         cmds = cdb.getCompileCommands("/home/john.doe/MyProject/project2.cpp")
         self.assertEqual(len(cmds), 2)
         expected = [
@@ -154,7 +154,7 @@ def test_2_compilecommand(self):
 
     def test_compilecommand_iterator_stops(self):
         """Check that iterator stops after the correct number of elements"""
-        cdb = CompilationDatabase.fromDirectory(inputs_dir)
+        cdb = CompilationDatabase.fromDirectory(INPUTS_DIR)
         count = 0
         for cmd in cdb.getCompileCommands("/home/john.doe/MyProject/project2.cpp"):
             count += 1
@@ -162,7 +162,7 @@ def test_compilecommand_iterator_stops(self):
 
     def test_compilationDB_references(self):
         """Ensure CompilationsCommands are independent of the database"""
-        cdb = CompilationDatabase.fromDirectory(inputs_dir)
+        cdb = CompilationDatabase.fromDirectory(INPUTS_DIR)
         cmds = cdb.getCompileCommands("/home/john.doe/MyProject/project.cpp")
         del cdb
         gc.collect()
@@ -170,7 +170,7 @@ def test_compilationDB_references(self):
 
     def test_compilationCommands_references(self):
         """Ensure CompilationsCommand keeps a reference to CompilationCommands"""
-        cdb = CompilationDatabase.fromDirectory(inputs_dir)
+        cdb = CompilationDatabase.fromDirectory(INPUTS_DIR)
         cmds = cdb.getCompileCommands("/home/john.doe/MyProject/project.cpp")
         del cdb
         cmd0 = cmds[0]
diff --git a/clang/bindings/python/tests/cindex/test_cursor.py b/clang/bindings/python/tests/cindex/test_cursor.py
index 5f38b1fe0d825..82f40c60afa59 100644
--- a/clang/bindings/python/tests/cindex/test_cursor.py
+++ b/clang/bindings/python/tests/cindex/test_cursor.py
@@ -22,7 +22,7 @@
 
 from .util import get_cursor, get_cursors, get_tu
 
-children_test = """\
+CHILDREN_TEST = """\
 struct s0 {
   int a;
   int b;
@@ -42,7 +42,7 @@
 }
 """
 
-parent_test = """\
+PARENT_TEST = """\
         class C {
             void f();
         }
@@ -50,7 +50,7 @@ class C {
         void C::f() { }
     """
 
-template_arg_test = """\
+TEMPLATE_ARG_TEST = """\
         template <int kInt, typename T, bool kBool>
         void foo();
 
@@ -58,7 +58,7 @@ class C {
         void foo<-7, float, true>();
     """
 
-binops = """\
+BINOPS = """\
 struct C {
    int m;
  };
@@ -119,7 +119,7 @@ class C {
 
 class TestCursor(unittest.TestCase):
     def test_get_children(self):
-        tu = get_tu(children_test)
+        tu = get_tu(CHILDREN_TEST)
 
         it = tu.cursor.get_children()
         tu_nodes = list(it)
@@ -614,7 +614,7 @@ def test_underlying_type(self):
         self.assertEqual(underlying.kind, TypeKind.INT)
 
     def test_semantic_parent(self):
-        tu = get_tu(parent_test, "cpp")
+        tu = get_tu(PARENT_TEST, "cpp")
         curs = get_cursors(tu, "f")
         decl = get_cursor(tu, "C")
         self.assertEqual(len(curs), 2)
@@ -622,7 +622,7 @@ def test_semantic_parent(self):
         self.assertEqual(curs[0].semantic_parent, decl)
 
     def test_lexical_parent(self):
-        tu = get_tu(parent_test, "cpp")
+        tu = get_tu(PARENT_TEST, "cpp")
         curs = get_cursors(tu, "f")
         decl = get_cursor(tu, "C")
         self.assertEqual(len(curs), 2)
@@ -866,13 +866,13 @@ def test_get_arguments(self):
         self.assertEqual(arguments[1].spelling, "j")
 
     def test_get_num_template_arguments(self):
-        tu = get_tu(template_arg_test, lang="cpp")
+        tu = get_tu(TEMPLATE_ARG_TEST, lang="cpp")
         foos = get_cursors(tu, "foo")
 
         self.assertEqual(foos[1].get_num_template_arguments(), 3)
 
     def test_get_template_argument_kind(self):
-        tu = get_tu(template_arg_test, lang="cpp")
+        tu = get_tu(TEMPLATE_ARG_TEST, lang="cpp")
         foos = get_cursors(tu, "foo")
 
         self.assertEqual(
@@ -886,20 +886,20 @@ def test_get_template_argument_kind(self):
         )
 
     def test_get_template_argument_type(self):
-        tu = get_tu(template_arg_test, lang="cpp")
+        tu = get_tu(TEMPLATE_ARG_TEST, lang="cpp")
         foos = get_cursors(tu, "foo")
 
         self.assertEqual(foos[1].get_template_argument_type(1).kind, TypeKind.FLOAT)
 
     def test_get_template_argument_value(self):
-        tu = get_tu(template_arg_test, lang="cpp")
+        tu = get_tu(TEMPLATE_ARG_TEST, lang="cpp")
         foos = get_cursors(tu, "foo")
 
         self.assertEqual(foos[1].get_template_argument_value(0), -7)
         self.assertEqual(foos[1].get_template_argument_value(2), True)
 
     def test_get_template_argument_unsigned_value(self):
-        tu = get_tu(template_arg_test, lang="cpp")
+        tu = get_tu(TEMPLATE_ARG_TEST, lang="cpp")
         foos = get_cursors(tu, "foo")
 
         self.assertEqual(foos[1].get_template_argument_unsigned_value(0), 2**32 - 7)
@@ -931,7 +931,7 @@ def test_mangled_name(self):
         )
 
     def test_binop(self):
-        tu = get_tu(binops, lang="cpp")
+        tu = get_tu(BINOPS, lang="cpp")
 
         operators = {
             # not exposed yet
@@ -1004,7 +1004,7 @@ def accumulate_cursors(cursor: Cursor, all_cursors: list):
                 all_cursors = accumulate_cursors(child, all_cursors)
             return all_cursors
 
-        tu = get_tu(children_test)
+        tu = get_tu(CHILDREN_TEST)
         all_cursors = accumulate_cursors(tu.cursor, [])
         cursor_hashes = set()
         for cursor in all_cursors:
@@ -1028,7 +1028,7 @@ def test_has_attrs(self):
         self.assertFalse(B.get_definition().has_attrs())
 
     def test_specialized_template(self):
-        tu = get_tu(template_arg_test, lang="cpp")
+        tu = get_tu(TEMPLATE_ARG_TEST, lang="cpp")
         foos = get_cursors(tu, "foo")
         prime_foo = foos[1].specialized_template
 
diff --git a/clang/bindings/python/tests/cindex/test_index.py b/clang/bindings/python/tests/cindex/test_index.py
index 46ae2da18aa04..f3d3ac00e5f7b 100644
--- a/clang/bindings/python/tests/cindex/test_index.py
+++ b/clang/bindings/python/tests/cindex/test_index.py
@@ -7,7 +7,7 @@
 
 import unittest
 
-inputs_dir = os.path.join(os.path.dirname(__file__), "INPUTS")
+INPUTS_DIR = os.path.join(os.path.dirname(__file__), "INPUTS")
 
 
 class TestIndex(unittest.TestCase):
@@ -19,7 +19,7 @@ def test_create(self):
     def test_parse(self):
         index = Index.create()
         self.assertIsInstance(index, Index)
-        tu = index.parse(os.path.join(inputs_dir, "hello.cpp"))
+        tu = index.parse(os.path.join(INPUTS_DIR, "hello.cpp"))
         self.assertIsInstance(tu, TranslationUnit)
-        tu = index.parse(None, ["-c", os.path.join(inputs_dir, "hello.cpp")])
+        tu = index.parse(None, ["-c", os.path.join(INPUTS_DIR, "hello.cpp")])
         self.assertIsInstance(tu, TranslationUnit)
diff --git a/clang/bindings/python/tests/cindex/test_location.py b/clang/bindings/python/tests/cindex/test_location.py
index 19867877ea227..21c6169bb0a6f 100644
--- a/clang/bindings/python/tests/cindex/test_location.py
+++ b/clang/bindings/python/tests/cindex/test_location.py
@@ -16,7 +16,7 @@
 
 from .util import get_cursor, get_tu
 
-base_input = "int one;\nint two;\n"
+BASE_INPUT = "int one;\nint two;\n"
 
 
 class TestLocation(unittest.TestCase):
@@ -26,7 +26,7 @@ def assert_location(self, loc, line, column, offset):
         self.assertEqual(loc.offset, offset)
 
     def test_location(self):
-        tu = get_tu(base_input)
+        tu = get_tu(BASE_INPUT)
         one = get_cursor(tu, "one")
         two = get_cursor(tu, "two")
 
@@ -37,7 +37,7 @@ def test_location(self):
         self.assert_location(two.location, line=2, column=5, offset=13)
 
         # adding a linebreak at top should keep columns same
-        tu = get_tu("\n" + base_input)
+        tu = get_tu("\n" + BASE_INPUT)
         one = get_cursor(tu, "one")
         two = get_cursor(tu, "two")
 
@@ -48,7 +48,7 @@ def test_location(self):
         self.assert_location(two.location, line=3, column=5, offset=14)
 
         # adding a space should affect column on first line only
-        tu = get_tu(" " + base_input)
+        tu = get_tu(" " + BASE_INPUT)
         one = get_cursor(tu, "one")
         two = get_cursor(tu, "two")
 
@@ -57,7 +57,7 @@ def test_location(self):
 
         # define the expected location ourselves and see if it matches
         # the returned location
-        tu = get_tu(base_input)
+        tu = get_tu(BASE_INPUT)
 
         file = File.from_name(tu, "t.c")
         location = SourceLocation.from_position(tu, file, 1, 5)
@@ -83,20 +83,20 @@ def test_location(self):
         self.assertTrue(verified)
 
     def test_extent(self):
-        tu = get_tu(base_input)
+        tu = get_tu(BASE_INPUT)
         one = get_cursor(tu, "one")
         two = get_cursor(tu, "two")
 
         self.assert_location(one.extent.start, line=1, column=1, offset=0)
         self.assert_location(one.extent.end, line=1, column=8, offset=7)
         self.assertEqual(
-            base_input[one.extent.start.offset : one.extent.end.offset], "int one"
+            BASE_INPUT[one.extent.start.offset : one.extent.end.offset], "int one"
         )
 
         self.assert_location(two.extent.start, line=2, column=1, offset=9)
         self.assert_location(two.extent.end, line=2, column=8, offset=16)
         self.assertEqual(
-            base_input[two.extent.start.offset : two.extent.end.offset], "int two"
+            BASE_INPUT[two.extent.start.offset : two.extent.end.offset], "int two"
         )
 
         file = File.from_name(tu, "t.c")
diff --git a/clang/bindings/python/tests/cindex/test_translation_unit.py b/clang/bindings/python/tests/cindex/test_translation_unit.py
index 9387358f88ea2..272cf05bed7b7 100644
--- a/clang/bindings/python/tests/cindex/test_translation_unit.py
+++ b/clang/bindings/python/tests/cindex/test_translation_unit.py
@@ -24,7 +24,7 @@
 
 from .util import get_cursor, get_tu
 
-inputs_dir = os.path.join(os.path.dirname(__file__), "INPUTS")
+INPUTS_DIR = os.path.join(os.path.dirname(__file__), "INPUTS")
 
 
 @contextmanager
@@ -51,26 +51,26 @@ def save_tu_pathlike(tu):
 
 class TestTranslationUnit(unittest.TestCase):
     def test_spelling(self):
-        path = os.path.join(inputs_dir, "hello.cpp")
+        path = os.path.join(INPUTS_DIR, "hello.cpp")
         tu = TranslationUnit.from_source(path)
         self.assertEqual(tu.spelling, path)
 
     def test_cursor(self):
-        path = os.path.join(inputs_dir, "hello.cpp")
+        path = os.path.join(INPUTS_DIR, "hello.cpp")
         tu = get_tu(path)
         c = tu.cursor
         self.assertIsInstance(c, Cursor)
         self.assertIs(c.kind, CursorKind.TRANSLATION_UNIT)
 
     def test_parse_arguments(self):
-        path = os.path.join(inputs_dir, "parse_arguments.c")
+        path = os.path.join(INPUTS_DIR, "parse_arguments.c")
         tu = TranslationUnit.from_source(path, ["-DDECL_ONE=hello", "-DDECL_TWO=hi"])
         spellings = [c.spelling for c in tu.cursor.get_children()]
         self.assertEqual(spellings[-2], "hello")
         self.assertEqual(spellings[-1], "hi")
 
     def test_reparse_arguments(self):
-        path = os.path.join(inputs_dir, "parse_arguments.c")
+        path = os.path.join(INPUTS_DIR, "parse_arguments.c")
         tu = TranslationUnit.from_source(path, ["-DDECL_ONE=hello", "-DDECL_TWO=hi"])
         tu.reparse()
         spellings = [c.spelling for c in tu.cursor.get_children()]
@@ -150,10 +150,10 @@ def eq(expected, actual):
             else:
                 self.assert_normpaths_equal(expected[1], actual.include.name)
 
-        src = os.path.join(inputs_dir, "include.cpp")
-        h1 = os.path.join(inputs_dir, "header1.h")
-        h2 = os.path.join(inputs_dir, "header2.h")
-        h3 = os.path.join(inputs_dir, "header3.h")
+        src = os.path.join(INPUTS_DIR, "include.cpp")
+        h1 = os.path.join(INPUTS_DIR, "header1.h")
+        h2 = os.path.join(INPUTS_DIR, "header2.h")
+        h3 = os.path.join(INPUTS_DIR, "header3.h")
         inc = [(src, h1), (h1, h3), (src, h2), (h2, h3)]
 
         tu = TranslationUnit.from_source(src)
@@ -161,10 +161,10 @@ def eq(expected, actual):
             eq(i[0], i[1])
 
     def test_inclusion_directive(self):
-        src = os.path.join(inputs_dir, "include.cpp")
-        h1 = os.path.join(inputs_dir, "header1.h")
-        h2 = os.path.join(inputs_dir, "header2.h")
-        h3 = os.path.join(inputs_dir, "header3.h")
+        src = os.path.join(INPUTS_DIR, "include.cpp")
+        h1 = os.path.join(INPUTS_DIR, "header1.h")
+        h2 = os.path.join(INPUTS_DIR, "header2.h")
+        h3 = os.path.join(INPUTS_DIR, "header3.h")
         inc = [h1, h3, h2, h3, h1]
 
         tu = TranslationUnit.from_source(
@@ -244,7 +244,7 @@ def test_load_pathlike(self):
             del tu2
 
     def test_index_parse(self):
-        path = os.path.join(inputs_dir, "hello.cpp")
+        path = os.path.join(INPUTS_DIR, "hello.cpp")
         index = Index.create()
         tu = index.parse(path)
         self.assertIsInstance(tu, TranslationUnit)
@@ -341,7 +341,7 @@ def test_get_tokens_gc(self):
         gc.collect()  # Just in case.
 
     def test_fail_from_source(self):
-        path = os.path.join(inputs_dir, "non-existent.cpp")
+        path = os.path.join(INPUTS_DIR, "non-existent.cpp")
         try:
             tu = TranslationUnit.from_source(path)
         except TranslationUnitLoadError:
@@ -349,7 +349,7 @@ def test_fail_from_source(self):
         self.assertEqual(tu, None)
 
     def test_fail_from_ast_file(self):
-        path = os.path.join(inputs_dir, "non-existent.ast")
+        path = os.path.join(INPUTS_DIR, "non-existent.ast")
         try:
             tu = TranslationUnit.from_ast_file(path)
         except TranslationUnitLoadError:
diff --git a/clang/bindings/python/tests/cindex/test_type.py b/clang/bindings/python/tests/cindex/test_type.py
index 7b929065dec04..a9473e1dc2458 100644
--- a/clang/bindings/python/tests/cindex/test_type.py
+++ b/clang/bindings/python/tests/cindex/test_type.py
@@ -18,7 +18,7 @@
 
 from .util import get_cursor, get_cursors, get_tu
 
-struct_input = """\
+STRUCT_INPUT = """\
 
 typedef int I;
 
@@ -36,7 +36,7 @@
 """
 
 
-constarray_input = """
+CONSTARRAY_INPUT = """
 struct teststruct {
   void *A[2];
 };
@@ -45,7 +45,7 @@
 
 class TestType(unittest.TestCase):
     def test_a_struct(self):
-        tu = get_tu(struct_input)
+        tu = get_tu(STRUCT_INPUT)
 
         teststruct = get_cursor(tu, "teststruct")
         self.assertIsNotNone(teststruct, "Could not find teststruct.")
@@ -143,7 +143,7 @@ def test_references(self):
         t.get_declaration()
 
     def testConstantArray(self):
-        tu = get_tu(constarray_input)
+        tu = get_tu(CONSTARRAY_INPUT)
 
         teststruct = get_cursor(tu, "teststruct")
         self.assertIsNotNone(teststruct, "Didn't find teststruct??")

@DeinAlptraum DeinAlptraum merged commit 4125054 into llvm:main Mar 26, 2025
16 checks passed
@DeinAlptraum DeinAlptraum deleted the rename-global-caps branch March 26, 2025 03:41
@llvm-ci
Copy link
Collaborator

llvm-ci commented Mar 26, 2025

LLVM Buildbot has detected a new failure on builder lldb-aarch64-ubuntu running on linaro-lldb-aarch64-ubuntu while building clang at step 6 "test".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/59/builds/14935

Here is the relevant piece of the build log for the reference
Step 6 (test) failure: build (failure)
...
UNSUPPORTED: lldb-api :: lang/cpp/gmodules/pch-chain/TestPchChain.py (804 of 2110)
UNSUPPORTED: lldb-api :: lang/cpp/gmodules/template-with-same-arg/TestTemplateWithSameArg.py (805 of 2110)
UNSUPPORTED: lldb-api :: lang/cpp/gmodules/templates/TestGModules.py (806 of 2110)
PASS: lldb-api :: lang/cpp/global_operators/TestCppGlobalOperators.py (807 of 2110)
PASS: lldb-api :: lang/cpp/global_variables/TestCPPGlobalVariables.py (808 of 2110)
PASS: lldb-api :: lang/cpp/incompatible-class-templates/TestCppIncompatibleClassTemplates.py (809 of 2110)
PASS: lldb-api :: lang/cpp/keywords_enabled/TestCppKeywordsEnabled.py (810 of 2110)
PASS: lldb-api :: lang/cpp/inlines/TestInlines.py (811 of 2110)
PASS: lldb-api :: lang/cpp/incomplete-types/members/TestCppIncompleteTypeMembers.py (812 of 2110)
UNSUPPORTED: lldb-api :: lang/cpp/libcxx-internals-recognizer/TestLibcxxInternalsRecognizer.py (813 of 2110)
FAIL: lldb-api :: lang/cpp/incomplete-stl-types/TestStlIncompleteTypes.py (814 of 2110)
******************** TEST 'lldb-api :: lang/cpp/incomplete-stl-types/TestStlIncompleteTypes.py' FAILED ********************
Script:
--
/usr/bin/python3.10 /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/llvm-project/lldb/test/API/dotest.py -u CXXFLAGS -u CFLAGS --env LLVM_LIBS_DIR=/home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/./lib --env LLVM_INCLUDE_DIR=/home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/include --env LLVM_TOOLS_DIR=/home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/./bin --arch aarch64 --build-dir /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/lldb-test-build.noindex --lldb-module-cache-dir /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/lldb-test-build.noindex/module-cache-lldb/lldb-api --clang-module-cache-dir /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/lldb-test-build.noindex/module-cache-clang/lldb-api --executable /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/./bin/lldb --compiler /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/./bin/clang --dsymutil /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/./bin/dsymutil --make /usr/bin/gmake --llvm-tools-dir /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/./bin --lldb-obj-root /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/tools/lldb --lldb-libs-dir /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/./lib /home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/llvm-project/lldb/test/API/lang/cpp/incomplete-stl-types -p TestStlIncompleteTypes.py
--
Exit Code: -11

Command Output (stdout):
--
lldb version 21.0.0git (https://github.com/llvm/llvm-project.git revision 41250541e7253839367ab1219845b19118794d81)
  clang revision 41250541e7253839367ab1219845b19118794d81
  llvm revision 41250541e7253839367ab1219845b19118794d81
Skipping the following test categories: ['libc++', 'dsym', 'gmodules', 'debugserver', 'objc']

--
Command Output (stderr):
--
UNSUPPORTED: LLDB (/home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/bin/clang-aarch64) :: test_dsym (TestStlIncompleteTypes.TestStlIncompleteTypes) (test case does not fall in any category of interest for this run) 
PASS: LLDB (/home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/bin/clang-aarch64) :: test_dwarf (TestStlIncompleteTypes.TestStlIncompleteTypes)
PASS: LLDB (/home/tcwg-buildbot/worker/lldb-aarch64-ubuntu/build/bin/clang-aarch64) :: test_dwo (TestStlIncompleteTypes.TestStlIncompleteTypes)
----------------------------------------------------------------------
Ran 3 tests in 0.997s

OK (skipped=1)

--

********************
UNSUPPORTED: lldb-api :: lang/cpp/modules-import/TestCXXModulesImport.py (815 of 2110)
PASS: lldb-api :: lang/cpp/lambdas/TestLambdas.py (816 of 2110)
PASS: lldb-api :: lang/cpp/llvm-style/TestLLVMStyle.py (817 of 2110)
PASS: lldb-api :: lang/cpp/incomplete-types/TestCppIncompleteTypes.py (818 of 2110)
PASS: lldb-api :: lang/cpp/multiple-inheritance/TestCppMultipleInheritance.py (819 of 2110)
PASS: lldb-api :: lang/cpp/member-and-local-vars-with-same-name/TestMembersAndLocalsWithSameName.py (820 of 2110)
PASS: lldb-api :: lang/cpp/limit-debug-info/TestWithLimitDebugInfo.py (821 of 2110)
PASS: lldb-api :: lang/cpp/namespace_conflicts/TestNamespaceConflicts.py (822 of 2110)
PASS: lldb-api :: lang/cpp/nested-class-other-compilation-unit/TestNestedClassWithParentInAnotherCU.py (823 of 2110)
PASS: lldb-api :: iohandler/autosuggestion/TestAutosuggestion.py (824 of 2110)

@llvm-ci
Copy link
Collaborator

llvm-ci commented Mar 26, 2025

LLVM Buildbot has detected a new failure on builder sanitizer-x86_64-linux-android running on sanitizer-buildbot-android while building clang at step 2 "annotate".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/186/builds/7661

Here is the relevant piece of the build log for the reference
Step 2 (annotate) failure: 'python ../sanitizer_buildbot/sanitizers/zorg/buildbot/builders/sanitizers/buildbot_selector.py' (failure)
...
[       OK ] AddressSanitizer.AtoiAndFriendsOOBTest (2290 ms)
[ RUN      ] AddressSanitizer.HasFeatureAddressSanitizerTest
[       OK ] AddressSanitizer.HasFeatureAddressSanitizerTest (0 ms)
[ RUN      ] AddressSanitizer.CallocReturnsZeroMem
[       OK ] AddressSanitizer.CallocReturnsZeroMem (14 ms)
[ DISABLED ] AddressSanitizer.DISABLED_TSDTest
[ RUN      ] AddressSanitizer.IgnoreTest
[       OK ] AddressSanitizer.IgnoreTest (0 ms)
[ RUN      ] AddressSanitizer.SignalTest
[       OK ] AddressSanitizer.SignalTest (211 ms)
[ RUN      ] AddressSanitizer.ReallocTest
[       OK ] AddressSanitizer.ReallocTest (30 ms)
[ RUN      ] AddressSanitizer.WrongFreeTest
[       OK ] AddressSanitizer.WrongFreeTest (126 ms)
[ RUN      ] AddressSanitizer.LongJmpTest
[       OK ] AddressSanitizer.LongJmpTest (0 ms)
[ RUN      ] AddressSanitizer.ThreadStackReuseTest
[       OK ] AddressSanitizer.ThreadStackReuseTest (6 ms)
[ DISABLED ] AddressSanitizer.DISABLED_MemIntrinsicUnalignedAccessTest
[ DISABLED ] AddressSanitizer.DISABLED_LargeFunctionSymbolizeTest
[ DISABLED ] AddressSanitizer.DISABLED_MallocFreeUnwindAndSymbolizeTest
[ RUN      ] AddressSanitizer.UseThenFreeThenUseTest
[       OK ] AddressSanitizer.UseThenFreeThenUseTest (134 ms)
[ RUN      ] AddressSanitizer.FileNameInGlobalReportTest
[       OK ] AddressSanitizer.FileNameInGlobalReportTest (125 ms)
[ DISABLED ] AddressSanitizer.DISABLED_StressStackReuseAndExceptionsTest
[ RUN      ] AddressSanitizer.MlockTest
[       OK ] AddressSanitizer.MlockTest (0 ms)
[ DISABLED ] AddressSanitizer.DISABLED_DemoThreadedTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoStackTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoThreadStackTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFLowIn
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFLowLeft
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFLowRight
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFHigh
[ DISABLED ] AddressSanitizer.DISABLED_DemoOOM
[ DISABLED ] AddressSanitizer.DISABLED_DemoDoubleFreeTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoNullDerefTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoFunctionStaticTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoTooMuchMemoryTest
[ RUN      ] AddressSanitizer.LongDoubleNegativeTest
[       OK ] AddressSanitizer.LongDoubleNegativeTest (0 ms)
[----------] 19 tests from AddressSanitizer (28128 ms total)

[----------] Global test environment tear-down
[==========] 22 tests from 2 test suites ran. (28135 ms total)
[  PASSED  ] 22 tests.

  YOU HAVE 1 DISABLED TEST

Step 24 (run instrumented asan tests [aarch64/aosp_coral-userdebug/AOSP.MASTER]) failure: run instrumented asan tests [aarch64/aosp_coral-userdebug/AOSP.MASTER] (failure)
...
[ RUN      ] AddressSanitizer.HasFeatureAddressSanitizerTest
[       OK ] AddressSanitizer.HasFeatureAddressSanitizerTest (0 ms)
[ RUN      ] AddressSanitizer.CallocReturnsZeroMem
[       OK ] AddressSanitizer.CallocReturnsZeroMem (9 ms)
[ DISABLED ] AddressSanitizer.DISABLED_TSDTest
[ RUN      ] AddressSanitizer.IgnoreTest
[       OK ] AddressSanitizer.IgnoreTest (0 ms)
[ RUN      ] AddressSanitizer.SignalTest
[       OK ] AddressSanitizer.SignalTest (350 ms)
[ RUN      ] AddressSanitizer.ReallocTest
[       OK ] AddressSanitizer.ReallocTest (20 ms)
[ RUN      ] AddressSanitizer.WrongFreeTest
[       OK ] AddressSanitizer.WrongFreeTest (249 ms)
[ RUN      ] AddressSanitizer.LongJmpTest
[       OK ] AddressSanitizer.LongJmpTest (0 ms)
[ RUN      ] AddressSanitizer.ThreadStackReuseTest
[       OK ] AddressSanitizer.ThreadStackReuseTest (0 ms)
[ DISABLED ] AddressSanitizer.DISABLED_MemIntrinsicUnalignedAccessTest
[ DISABLED ] AddressSanitizer.DISABLED_LargeFunctionSymbolizeTest
[ DISABLED ] AddressSanitizer.DISABLED_MallocFreeUnwindAndSymbolizeTest
[ RUN      ] AddressSanitizer.UseThenFreeThenUseTest
[       OK ] AddressSanitizer.UseThenFreeThenUseTest (291 ms)
[ RUN      ] AddressSanitizer.FileNameInGlobalReportTest
[       OK ] AddressSanitizer.FileNameInGlobalReportTest (320 ms)
[ DISABLED ] AddressSanitizer.DISABLED_StressStackReuseAndExceptionsTest
[ RUN      ] AddressSanitizer.MlockTest
[       OK ] AddressSanitizer.MlockTest (0 ms)
[ DISABLED ] AddressSanitizer.DISABLED_DemoThreadedTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoStackTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoThreadStackTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFLowIn
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFLowLeft
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFLowRight
[ DISABLED ] AddressSanitizer.DISABLED_DemoUAFHigh
[ DISABLED ] AddressSanitizer.DISABLED_DemoOOM
[ DISABLED ] AddressSanitizer.DISABLED_DemoDoubleFreeTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoNullDerefTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoFunctionStaticTest
[ DISABLED ] AddressSanitizer.DISABLED_DemoTooMuchMemoryTest
[ RUN      ] AddressSanitizer.LongDoubleNegativeTest
[       OK ] AddressSanitizer.LongDoubleNegativeTest (0 ms)
[----------] 19 tests from AddressSanitizer (72387 ms total)

[----------] Global test environment tear-down
[==========] 22 tests from 2 test suites ran. (72393 ms total)
[  PASSED  ] 22 tests.

  YOU HAVE 1 DISABLED TEST

Serial 17031FQCB00176

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang:as-a-library libclang and C++ API clang Clang issues not falling into any other category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants