[all-commits] [llvm/llvm-project] 87db09: MC: Support quoted symbol names

Fangrui Song via All-commits all-commits at lists.llvm.org
Wed May 7 23:08:42 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 87db0943e4d07640e4df3206045826c0688ed3b9
      https://github.com/llvm/llvm-project/commit/87db0943e4d07640e4df3206045826c0688ed3b9
  Author: Fangrui Song <i at maskray.me>
  Date:   2025-05-08 (Thu, 08 May 2025)

  Changed paths:
    M llvm/lib/MC/MCContext.cpp
    M llvm/lib/MC/MCSymbol.cpp
    M llvm/test/MC/AsmParser/quoted.s
    M llvm/test/MC/COFF/safeseh.s
    M llvm/test/MC/ELF/symbol-names.s

  Log Message:
  -----------
  MC: Support quoted symbol names

gas has supported " quoted symbols since 2015:
https://sourceware.org/pipermail/binutils/2015-August/090003.html

We don't handle \\ or \" , leading to clang -c --save-temps vs clang -c
difference for the following C code:

```
int x asm("a\"\\b");
```

Fix #138390

MC/COFF/safeseh.h looks incorrect. \01 in `.safeseh "\01foo"` is not a
correct escape sequence. Change it to \\

Pull Request: https://github.com/llvm/llvm-project/pull/138817



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