mirror of
https://gitee.com/openharmony/arkcompiler_runtime_core
synced 2024-11-27 00:41:14 +00:00
!2647 Do not align spill slots count for Irtoc Fastpath
Merge pull request !2647 from Sidorov Aleksei/fix_fastpath_spills
This commit is contained in:
commit
b3e635129a
@ -147,7 +147,7 @@ Codegen::Codegen(Graph *graph)
|
||||
codeBuilder_(allocator_->New<CodeInfoBuilder>(graph->GetArch(), allocator_)),
|
||||
slowPaths_(graph->GetLocalAllocator()->Adapter()),
|
||||
slowPathsMap_(graph->GetLocalAllocator()->Adapter()),
|
||||
frameLayout_(CFrameLayout(graph->GetArch(), graph->GetStackSlotsCount())),
|
||||
frameLayout_(CFrameLayout(graph->GetArch(), graph->GetStackSlotsCount(), !graph->GetMode().IsFastPath())),
|
||||
osrEntries_(graph->GetLocalAllocator()->Adapter()),
|
||||
vregIndices_(GetAllocator()->Adapter()),
|
||||
runtime_(graph->GetRuntime()),
|
||||
|
@ -181,7 +181,7 @@ void CodegenFastPath::CreateFrameInfo()
|
||||
FrameInfo::CallersRelativeFp::Encode(true) | FrameInfo::CalleesRelativeFp::Encode(false) |
|
||||
FrameInfo::PushCallers::Encode(true));
|
||||
frame->SetSpillsCount(GetGraph()->GetStackSlotsCount());
|
||||
CFrameLayout fl(GetGraph()->GetArch(), GetGraph()->GetStackSlotsCount());
|
||||
CFrameLayout fl(GetGraph()->GetArch(), GetGraph()->GetStackSlotsCount(), false);
|
||||
|
||||
frame->SetCallersOffset(fl.GetOffset<CFrameLayout::OffsetOrigin::SP, CFrameLayout::OffsetUnit::SLOTS>(
|
||||
fl.GetStackStartSlot() + fl.GetCallerLastSlot(false)));
|
||||
|
@ -63,8 +63,8 @@ private:
|
||||
|
||||
class CFrameLayout {
|
||||
public:
|
||||
constexpr CFrameLayout(Arch arch, size_t spillsCount)
|
||||
: arch_(arch), spillsCount_(AlignSpillCount(arch, spillsCount))
|
||||
constexpr CFrameLayout(Arch arch, size_t spillsCount, bool alignSpills = true)
|
||||
: arch_(arch), spillsCount_(alignSpills ? AlignSpillCount(arch, spillsCount) : spillsCount)
|
||||
{
|
||||
}
|
||||
~CFrameLayout() = default;
|
||||
|
Loading…
Reference in New Issue
Block a user