mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-23 02:32:11 +00:00
Check multiple return values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48267 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
38459f01c0
commit
045497ae27
@ -420,7 +420,8 @@ struct VISIBILITY_HIDDEN ExitInMainOptimization : public LibCallOptimization {
|
||||
// to exit have the same type.
|
||||
Function *from = ci->getParent()->getParent();
|
||||
if (from->hasExternalLinkage())
|
||||
if (from->getReturnType() == ci->getOperand(1)->getType())
|
||||
if (from->getReturnType() == ci->getOperand(1)->getType()
|
||||
&& !isa<StructType>(from->getReturnType()))
|
||||
if (from->getName() == "main") {
|
||||
// Okay, time to actually do the optimization. First, get the basic
|
||||
// block of the call instruction
|
||||
|
Loading…
x
Reference in New Issue
Block a user