mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-07 19:36:06 +03:00
Use llvmdc helpers for store and bitcast in fp80 padding init code.
This commit is contained in:
parent
b2efd0d317
commit
14c3e022e4
1 changed files with 2 additions and 2 deletions
|
@ -94,9 +94,9 @@ llvm::AllocaInst* DtoAlloca(const LLType* lltype, const std::string& name)
|
||||||
if(lltype == LLType::X86_FP80Ty)
|
if(lltype == LLType::X86_FP80Ty)
|
||||||
{
|
{
|
||||||
llvm::AllocaInst* alloca = new llvm::AllocaInst(lltype, name, gIR->topallocapoint());
|
llvm::AllocaInst* alloca = new llvm::AllocaInst(lltype, name, gIR->topallocapoint());
|
||||||
LLValue* castv = new llvm::BitCastInst(alloca, getPtrToType(LLType::Int16Ty), "fp80toi16", gIR->scopebb());
|
LLValue* castv = DtoBitCast(alloca, getPtrToType(LLType::Int16Ty), "fp80toi16");
|
||||||
LLValue* padding = DtoGEPi1(castv, 5, "fp80padding");
|
LLValue* padding = DtoGEPi1(castv, 5, "fp80padding");
|
||||||
new llvm::StoreInst(llvm::Constant::getNullValue(LLType::Int16Ty), padding, gIR->scopebb());
|
DtoStore(llvm::Constant::getNullValue(LLType::Int16Ty), padding);
|
||||||
|
|
||||||
return alloca;
|
return alloca;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue