forked from OSchip/llvm-project
[FastISel] Copy the inline assembly dialect to the INLINEASM instruction.
Fixes PR43575. llvm-svn: 373836
This commit is contained in:
parent
8815be04ec
commit
2decdf42b9
|
@ -1303,6 +1303,7 @@ bool FastISel::selectCall(const User *I) {
|
|||
ExtraInfo |= InlineAsm::Extra_HasSideEffects;
|
||||
if (IA->isAlignStack())
|
||||
ExtraInfo |= InlineAsm::Extra_IsAlignStack;
|
||||
ExtraInfo |= IA->getDialect() * InlineAsm::Extra_AsmDialect;
|
||||
|
||||
BuildMI(*FuncInfo.MBB, FuncInfo.InsertPt, DbgLoc,
|
||||
TII.get(TargetOpcode::INLINEASM))
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
; RUN: llc < %s -mtriple=x86_64-apple-macosx10.14.0 -O0 | FileCheck %s
|
||||
|
||||
define void @exit(i32 %status)
|
||||
; CHECK-LABEL: exit:
|
||||
; CHECK: ## %bb.0:
|
||||
; CHECK: ## InlineAsm Start
|
||||
; CHECK: movq $60, %rax
|
||||
; CHECK: syscall
|
||||
; CHECK: ## InlineAsm End
|
||||
; CHECK: retq
|
||||
{
|
||||
call void asm sideeffect inteldialect "mov rax, 60; syscall", ""()
|
||||
ret void
|
||||
}
|
Loading…
Reference in New Issue