mirror of
https://github.com/RPCSX/llvm.git
synced 2025-01-19 19:03:50 +00:00
Forgot the part where we handle the ".llvm.eh.catch.all.value".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99697 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
43de15f8a3
commit
e6b293b78d
@ -281,8 +281,17 @@ unsigned FunctionLoweringInfo::CreateRegForValue(const Value *V) {
|
||||
GlobalVariable *llvm::ExtractTypeInfo(Value *V) {
|
||||
V = V->stripPointerCasts();
|
||||
GlobalVariable *GV = dyn_cast<GlobalVariable>(V);
|
||||
assert ((GV || isa<ConstantPointerNull>(V)) &&
|
||||
"TypeInfo must be a global variable or NULL");
|
||||
|
||||
if (GV && GV->getName() == ".llvm.eh.catch.all.value") {
|
||||
assert(GV->hasInitializer() &&
|
||||
"The EH catch-all value must have an initializer");
|
||||
Value *Init = GV->getInitializer();
|
||||
GV = dyn_cast<GlobalVariable>(Init);
|
||||
if (!GV) V = cast<ConstantPointerNull>(Init);
|
||||
}
|
||||
|
||||
assert((GV || isa<ConstantPointerNull>(V)) &&
|
||||
"TypeInfo must be a global variable or NULL");
|
||||
return GV;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user