[PATCH] D123534: [dwarf] Emit a DIGlobalVariable for constant strings.

Mitch Phillips via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 26 16:10:21 PDT 2022

hctim marked an inline comment as done.
hctim added inline comments.

Comment at: clang/test/CodeGen/debug-info-variables.c:1
+// RUN: %clang_cc1 %s -debug-info-kind=standalone -S -emit-llvm -o - | FileCheck %s
dblaikie wrote:
> Presumably named variables are already tested elsewhere - so I probably wouldn't test them here, and would give this file a more specific name related to string literals. Alternatively/perhaps the other thing to do would be to find some test that already covers global variable debug info, and test string literals there?
I found `debug-info-global-constant.c` and `debug-info-static.c`, but neither of them test DILocalVariables or strings.

This test was cargo-culted from `debug-info-gline-tables-only.c` which does the inverse :).

I was hoping that this test would become the main "simple global variables" test :)

  rG LLVM Github Monorepo



More information about the cfe-commits mailing list