[PATCH] D113096: [X86][MS-InlineAsm] Add constraint *m for memory access w/ global var
Kan Shengchen via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Nov 3 04:41:26 PDT 2021
skan created this revision.
Herald added subscribers: pengfei, hiraditya.
skan requested review of this revision.
Herald added projects: clang, LLVM.
Herald added subscribers: llvm-commits, cfe-commits.
Constraint `*m` should be used when the address of a variable is passed
as a value. And the constraint is missing for MS inline assembly when sth
is written to the address of the variable.
The missing would cause FE delete the definition of the static varible,
and then result in "undefined reference to xxx" issue.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D113096
Files:
clang/test/CodeGen/X86/ms_fmul.c
clang/test/CodeGen/ms-inline-asm-static-variable.c
clang/test/CodeGen/ms-inline-asm-variables.c
llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
llvm/test/CodeGen/X86/ms-inline-asm-array.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D113096.384399.patch
Type: text/x-patch
Size: 4556 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20211103/4569afc5/attachment-0001.bin>
More information about the cfe-commits
mailing list