[all-commits] [llvm/llvm-project] 4a7aa2: [X86][AsmParser] re-introduce 'offset' operator

Eric Astor via All-commits all-commits at lists.llvm.org
Mon Dec 30 11:45:14 PST 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 4a7aa252a32a94b1bb61b3dc7f027b4a27ae334f
      https://github.com/llvm/llvm-project/commit/4a7aa252a32a94b1bb61b3dc7f027b4a27ae334f
  Author: Eric Astor <epastor at google.com>
  Date:   2019-12-30 (Mon, 30 Dec 2019)

  Changed paths:
    M clang/lib/Sema/SemaStmtAsm.cpp
    M clang/test/CodeGen/ms-inline-asm-64.c
    M clang/test/CodeGen/ms-inline-asm.c
    M clang/test/CodeGen/ms-inline-asm.cpp
    M clang/test/Parser/ms-inline-asm.c
    M llvm/include/llvm/MC/MCParser/MCParsedAsmOperand.h
    M llvm/include/llvm/MC/MCParser/MCTargetAsmParser.h
    M llvm/lib/MC/MCParser/AsmParser.cpp
    M llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
    M llvm/lib/Target/X86/AsmParser/X86Operand.h
    M llvm/lib/Target/X86/X86AsmPrinter.cpp
    M llvm/test/CodeGen/X86/ms-inline-asm.ll
    A llvm/test/CodeGen/X86/offset-operator.ll
    A llvm/test/MC/X86/pr32530.s

  Log Message:
  -----------
  [X86][AsmParser] re-introduce 'offset' operator

Summary:
Amend MS offset operator implementation, to more closely fit with its MS counterpart:

    1. InlineAsm: evaluate non-local source entities to their (address) location
    2. Provide a mean with which one may acquire the address of an assembly label via MS syntax, rather than yielding a memory reference (i.e. "offset asm_label" and "$asm_label" should be synonymous
    3. address PR32530

Based on http://llvm.org/D37461

Fix broken test where the break appears unrelated.

- Set up appropriate memory-input rewrites for variable references.

- Intel-dialect assembly printing now correctly handles addresses by adding "offset".

- Pass offsets as immediate operands (using "r" constraint for offsets of locals).

Reviewed By: rnk

Differential Revision: https://reviews.llvm.org/D71436




More information about the All-commits mailing list