llvm.org GIT mirror llvm / 466958c
Implement the SVR4 byval alignment for aggregates. Fixing a FIXME. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@153876 91177308-0d34-0410-b5e6-96231b3b80d8 Roman Divacky 8 years ago
1 changed file(s) with 10 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
445445 // Darwin passes everything on 4 byte boundary.
446446 if (TM.getSubtarget().isDarwin())
447447 return 4;
448 // FIXME SVR4 TBD
448
449 // 16byte and wider vectors are passed on 16byte boundary.
450 if (VectorType *VTy = dyn_cast(Ty))
451 if (VTy->getBitWidth() >= 128)
452 return 16;
453
454 // The rest is 8 on PPC64 and 4 on PPC32 boundary.
455 if (PPCSubTarget.isPPC64())
456 return 8;
457
449458 return 4;
450459 }
451460