VStudio compiler errors and placing Function*->ExFunc map under ManagedStatic control.
authorChuck Rose III <cfr@adobe.com>
Fri, 27 Jul 2007 18:26:35 +0000 (18:26 +0000)
committerChuck Rose III <cfr@adobe.com>
Fri, 27 Jul 2007 18:26:35 +0000 (18:26 +0000)
commit936baaa5aeddb78ff41b1f655101b4d88c47473b
treebdb4bb7687a121daf32ab68e13ac0f16da72bc78
parent7c2c2e71edf27bd23fd37eb479caa6abf5a2c9cc
VStudio compiler errors and placing Function*->ExFunc map under ManagedStatic control.

This commit fixes two things.  One is a pair of VStudio compiler errors stemming from variables
which defined within the for loop statement and also within the body of the for loop.  I fixed these
by renaming one of the two variables.  Additionally, I've made the Function*->ExFunc map in
ExternalFunctions.cpp a ManagedStatic object, so that cleanup will be done on llvm_shutdown.  In repeated
uses of the interpreter, where the same Function* address may get used for completely differnet functions,
this was causing a crash.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40558 91177308-0d34-0410-b5e6-96231b3b80d8
lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp
lib/Transforms/Scalar/LoopUnswitch.cpp
utils/TableGen/RegisterInfoEmitter.cpp