Skip to content
This repository was archived by the owner on Apr 28, 2023. It is now read-only.

Commit 720d077

Browse files
committed
emit declarations for register promotion
1 parent 822494f commit 720d077

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/core/polyhedral/codegen_cuda.cc

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -707,7 +707,10 @@ void emitPromotedArrayViewsHalide(stringstream& ss, const Scop& scop) {
707707
t = i.type();
708708
}
709709
}
710-
ss << "__shared__ " << t << " " << viewName;
710+
if (p.second.kind == Scop::PromotedDecl::Kind::SharedMem) {
711+
ss << "__shared__ ";
712+
}
713+
ss << t << " " << viewName;
711714
for (auto s : p.second.sizes) {
712715
ss << "[" << s << "]";
713716
}

0 commit comments

Comments
 (0)