Jump to content

Recommended Posts

Hello all,

Sorry if this is not the right forum for this message, but I was wondering what tool is most commonly used to parse SystemC? I am looking for a freely available tool, if possible. I did some of my own searching and came across several tools such as Pinapa/PinaVM, KaSCPar, SystemPerl, etc., but none of them seems to have been updated in the past five years or so. I've tried installing some of them, but I invariably get errors most likely because they haven't been kept up to date with the latest versions of SystemC, g++, etc. Does anyone know of a tool that is actively maintained and is commonly used to parse SystemC? There must be at least one tool out there. Any help is greatly appreciated.

Thanks,

Gilbert

Link to post
Share on other sites

Hello @Gilbert Pajela,

SystemC is C++, so it would be better to utilize C++ Tooling support to parse SystemC.

And since @Roman Popov already mentioned Clang and LLVM tooling infrastructure you would have to fiddle with it to get necessary results.

After Googling a bit found a reference to this paper: https://ieeexplore.ieee.org/document/6646649,

and this project on GitHub: https://github.com/anikau31/systemc-clang

Which have been updated quite recently.

Hope it helps.

Regards,

Ameya Vikram Singh

Link to post
Share on other sites

If you need more flexibility than systemc-clang allows you may use libclang. This is a Python binding of the Clang library (some intro can be found here: https://shaharmike.com/cpp/libclang/ or here: https://eli.thegreenplace.net/2011/07/03/parsing-c-in-python-with-clang). This way you can easily deal with the Clang AST and its cross references  and alike.

Best regards

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...