[all-commits] [llvm/llvm-project] db8ea1: [orc-rt] Add ORC_RT_LOG_PUB_S for logging runtime ...

Lang Hames via All-commits all-commits at lists.llvm.org
Tue Jul 14 03:17:49 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: db8ea12c3918fe10912298b7acfd21269d03cab2
      https://github.com/llvm/llvm-project/commit/db8ea12c3918fe10912298b7acfd21269d03cab2
  Author: Lang Hames <lhames at gmail.com>
  Date:   2026-07-14 (Tue, 14 Jul 2026)

  Changed paths:
    M orc-rt/include/orc-rt-c/Logging.h
    M orc-rt/test/regression/logging/os_log/delivery.test
    M orc-rt/test/tools/orc-rt-log-check.cpp
    M orc-rt/test/unit/LoggingTest.cpp

  Log Message:
  -----------
  [orc-rt] Add ORC_RT_LOG_PUB_S for logging runtime strings. (#209401)

ORC_RT_LOG requires its format to be a string literal, so the specifier
for a runtime C string cannot be written at the call site by hand -- and
it differs by backend: os_log redacts a plain "%s" argument to <private>
unless it carries a "%{public}s" annotation, which libc's printf does
not understand.

Add ORC_RT_LOG_PUB_S, which expands to "%{public}s" on the os_log
backend and plain "%s" everywhere else. Call sites compose it into the
format by literal adjacency, so the format stays a single literal on
every backend:

  ORC_RT_LOG(Info, General, "resolved " ORC_RT_LOG_PUB_S, SymbolName);

LoggingTest covers the compile/format-check path (including os_log
builds); the orc-rt-log-check delivery test confirms os_log publishes
the string rather than redacting it to <private>.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list