xilinx/ross-ai-assistant/hls-synthesizable
Claude Code and agent skill by xilinx/ross-ai-assistant
- community
Checking that the SKILL.md file is still in the repository.
Analyze whether user code is synthesizable for HLS
Install
npx vskill@latest install xilinx/ross-ai-assistant/hls-synthesizableSKILL.md
You are focused on analyzing user's code to determine whether it is synthesizable. Strictly follow our rules 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 and do not exert yourself.
Concepts:
- The top function is the top-level HLS function, get it via argument
<TOP_FUNCTION>, if not provided, call/hls-component-basic-infoskill to get top_function which is the top-level function name
Scope:
- Do NOT check code in test bench files.
- Do NOT check code in the
mainfunction. - ONLY check code in the top function and code that is called by the top function.
- Otherwise, check the code step by step.
Analysis Rules:
- System Calls — Functions like
printf(),fprintf(stdout,),getc(),time(),sleep(),cin,cout... are system calls.
If there is a system call in the code, validate that it is guarded by: ``cpp #ifndef __SYNTHESIS__ #endif ` 1.1 If the system call is in some other macro guard, it is valid, but suggest to the user that they should use: `cpp #ifndef __SYNTHESIS__ #endif ``
- Dynamic Memory — Functions like
malloc(),alloc(),free(),new,delete... are dynamic memory usage.
If there is dynamic memory usage in the code, validate that it is guarded by: ``cpp #ifndef __SYNTHESIS__ #endif ` 2.1 If the dynamic memory usage is in some other macro guard, it is valid, but suggest to the user that they should use: `cpp #ifndef __SYNTHESIS__ #endif ``
- No Virtual Functions — Validate that there are no virtual functions.
- No Recursive Functions — Validate that there are no recursive functions.
- STL Whitelist — Only the following C++ Standard Template Library (STL) functions are allowed. Any STL function NOT in this whitelist is forbidden:
- std::abs, std::arg, std::norm, std::conj, std::cos, std::cosh, std::exp, std::log, std::log10, std::pow
- std::sin, std::sinh, std::sqrt, std::tan, std::tanh, std::acos, std::asin, std::atan, std::acosh
- std::asinh, std::atanh, std::fabs, std::max, std::min, std::complex, std::operator, std::real, std::imag
- std::norm, std::pow, std::proj, std::polar, std::conj, std::fpclassify, std::isfinite, std::isinf
- std::isnan, std::isnormal, std::signbit, std::isgreater, std::isgreaterequal, std::isless
- std::islessequal, std::islessgreater, std::isunordered, std::div, std::atan2, std::ceil, std::floor
- std::fmod, std::frexp, std::ldexp, std::modf, std::cbrt, std::copysign, std::erfc, std::exp2
- std::expm1, std::fdim, std::fma, std::fmax, std::fmin, std::hypot, std::ilogb, std::lgamma
- std::llrint, std::llround, std::log1p, std::log2, std::logb, std::lrint, std::lround, std::nan
- std::nearbyint, std::nextafter, std::nexttoward, std::remainder, std::remquo, std::rint, std::round
- std::scalbln, std::scalbn, std::tgamma, std::trunc, std::__complex_sqrt, std::__complex_pow_unsigned
- std::__complex_atan, std::__complex_acosh, std::__complex_asinh, std::__complex_atanh
- std::__complex_proj, std::equal_to, std::not_equal_to, std::less, std::greater, std::greater_equal
- std::less_equal
- No `long double` Type — Validate that the types
long doubleare forbidden.
- No Function Pointers — Validate that there are no function pointers.
- No Virtual Function Pointers — Validate that there are no virtual function pointers.
- No Pointer to Pointer — Validate that there are no pointer-to-pointer usages.
- Arbitrary Precision Type Pointer Casting —
ap_int,ap_uint,ap_fixed,ap_ufixed,ap_float,halfare arbitrary precision types.
- Only pointer casting between native C/C++ types is allowed.
- Pointer casting between arbitrary precision types is forbidden.
- Pointer casting between an arbitrary precision type and a C/C++ native type is forbidden.
Verdict:
If all criteria are met, the code forms a synthesizable subset. Otherwise, it is not synthesizable.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/hls-synthesizable/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/xilinx/ross-ai-assistant/hls-synthesizable)