If ISD::ANY_EXTEND fails, try ISD::ZERO_EXTEND and ISD::SIGN_EXTEND before giving up. This fixes 445.gobmk on

X86-64 in fast isel.

llvm-svn: 56088
This commit is contained in:
Owen Anderson 2008-09-11 02:41:37 +00:00
parent e5ca04e70d
commit 41baf8b22a
1 changed files with 7 additions and 0 deletions

View File

@ -857,6 +857,13 @@ bool X86FastISel::X86SelectCall(Instruction *I) {
case CCValAssign::AExt: {
bool Emitted = X86FastEmitExtend(ISD::ANY_EXTEND, VA.getLocVT(),
Arg, ArgVT, Arg);
if (!Emitted)
Emitted = X86FastEmitExtend(ISD::ZERO_EXTEND, VA.getLocVT(),
Arg, ArgVT, Arg);
if (!Emitted)
Emitted = X86FastEmitExtend(ISD::SIGN_EXTEND, VA.getLocVT(),
Arg, ArgVT, Arg);
assert(Emitted && "Failed to emit a aext!");
ArgVT = VA.getLocVT();
break;