From 4dbc74a953ae1b34ce64a4eaef3aa7feb73663b9 Mon Sep 17 00:00:00 2001 From: Yong He Date: Mon, 13 Feb 2023 10:38:14 -0800 Subject: Add Loop Unrolling Pass. (#2644) Co-authored-by: Yong He --- source/slang/slang-ast-modifier.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'source/slang/slang-ast-modifier.h') diff --git a/source/slang/slang-ast-modifier.h b/source/slang/slang-ast-modifier.h index 42b79ca4a..4ab295da6 100644 --- a/source/slang/slang-ast-modifier.h +++ b/source/slang/slang-ast-modifier.h @@ -616,8 +616,15 @@ class AttributeUsageAttribute : public Attribute class UnrollAttribute : public Attribute { SLANG_AST_CLASS(UnrollAttribute) - - IntegerLiteralValue getCount(); + +}; + +// An `[unroll]` or `[unroll(count)]` attribute +class ForceUnrollAttribute : public Attribute +{ + SLANG_AST_CLASS(ForceUnrollAttribute) + + int32_t maxIterations = 0; }; // An `[maxiters(count)]` -- cgit v1.2.3