Skip to content

Commit

Permalink
fixes #118
Browse files Browse the repository at this point in the history
  • Loading branch information
leissa committed Oct 24, 2022
1 parent 9e143f7 commit 28559ef
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion dialects/core/be/ll/ll.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,9 @@ std::string Emitter::emit_bb(BB& bb, const Def* def) {
// TODO array with size
// auto size = emit(mslot->arg(1));
auto [pointee, addr_space] = mslot->decurry()->args<2>();
print(lam2bb_[entry_].body().emplace_front(), "{} = alloca {}", name, convert(pointee));
// TODO placing allocas not in the entry block may cause severe performance problems
// print(lam2bb_[entry_].body().emplace_front(), "{} = alloca {}", name, convert(pointee));
print(bb.body().emplace_back(), "{} = alloca {}", name, convert(pointee));
return name;
} else if (auto load = match<mem::load>(def)) {
emit_unsafe(load->arg(0));
Expand Down

0 comments on commit 28559ef

Please sign in to comment.