From 94e8ee22820f1e16224efc69d6f39ba207814b1e Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Thu, 21 Nov 2002 17:26:58 +0000 Subject: [PATCH] Fix a bug that prevented compilation of multiple functions git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4809 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/X86/InstSelectSimple.cpp | 1 + lib/Target/X86/X86ISelSimple.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/Target/X86/InstSelectSimple.cpp b/lib/Target/X86/InstSelectSimple.cpp index c3da2fe914e..7f163b8db2c 100644 --- a/lib/Target/X86/InstSelectSimple.cpp +++ b/lib/Target/X86/InstSelectSimple.cpp @@ -44,6 +44,7 @@ namespace { F = &MachineFunction::construct(&Fn, TM); visit(Fn); RegMap.clear(); + CurReg = MRegisterInfo::FirstVirtualRegister; F = 0; return false; // We never modify the LLVM itself. } diff --git a/lib/Target/X86/X86ISelSimple.cpp b/lib/Target/X86/X86ISelSimple.cpp index c3da2fe914e..7f163b8db2c 100644 --- a/lib/Target/X86/X86ISelSimple.cpp +++ b/lib/Target/X86/X86ISelSimple.cpp @@ -44,6 +44,7 @@ namespace { F = &MachineFunction::construct(&Fn, TM); visit(Fn); RegMap.clear(); + CurReg = MRegisterInfo::FirstVirtualRegister; F = 0; return false; // We never modify the LLVM itself. }