mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 04:22:20 +02:00
Early code generation support
This commit is contained in:
parent
0b48a60592
commit
71d4dd0e90
26 changed files with 2422 additions and 1576 deletions
|
@ -758,6 +758,20 @@ BfIRValue BfIRConstHolder::CreateConstAgg(BfIRType type, const BfSizedArray<BfIR
|
|||
return irValue;
|
||||
}
|
||||
|
||||
BfIRValue BfIRConstHolder::CreateConstAggCE(BfIRType type, addr_ce addr)
|
||||
{
|
||||
BfConstantAggCE* constant = mTempAlloc.Alloc<BfConstantAggCE>();
|
||||
constant->mConstType = BfConstType_AggCE;
|
||||
constant->mType = type = type;
|
||||
constant->mCEAddr = addr;
|
||||
auto irValue = BfIRValue(BfIRValueFlags_Const, mTempAlloc.GetChunkedId(constant));
|
||||
|
||||
#ifdef CHECK_CONSTHOLDER
|
||||
irValue.mHolder = this;
|
||||
#endif
|
||||
return irValue;
|
||||
}
|
||||
|
||||
BfIRValue BfIRConstHolder::CreateConstArrayZero(BfIRType type, int count)
|
||||
{
|
||||
BfConstantArrayZero* constant = mTempAlloc.Alloc<BfConstantArrayZero>();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue