blob: 0026832ed281bd3449e1d1bb705b55a7b05bd346 [file] [log] [blame]
Chad Rosier31a9bbc2013-02-26 20:22:30 +00001; RUN: llc < %s -fast-isel -verify-machineinstrs -mtriple=x86_64-apple-darwin10
Chad Rosier7925d282013-04-02 16:31:41 +00002; RUN: llc < %s -fast-isel -verify-machineinstrs -mtriple=x86_64-pc-win32 | FileCheck %s -check-prefix=WIN32
3; RUN: llc < %s -fast-isel -verify-machineinstrs -mtriple=x86_64-pc-win64 | FileCheck %s -check-prefix=WIN64
Chad Rosier31a9bbc2013-02-26 20:22:30 +00004
5; Previously, this would cause an assert.
6define i31 @t1(i31 %a, i31 %b, i31 %c) {
7entry:
8 %add = add nsw i31 %b, %a
9 %add1 = add nsw i31 %add, %c
10 ret i31 %add1
11}
Chad Rosier4b54f592013-03-14 21:25:04 +000012
13; We don't handle the Windows CC, yet.
14define i32 @foo(i32* %p) {
15entry:
Chad Rosier7925d282013-04-02 16:31:41 +000016; WIN32: foo
17; WIN32: movl (%rcx), %eax
18; WIN64: foo
19; WIN64: movl (%rdi), %eax
David Blaikiea79ac142015-02-27 21:17:42 +000020 %0 = load i32, i32* %p, align 4
Chad Rosier4b54f592013-03-14 21:25:04 +000021 ret i32 %0
22}