Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace slow implementation with single-header, plain c++ version ? #92

Open
hzeller opened this issue Mar 18, 2023 · 0 comments
Open

Comments

@hzeller
Copy link

hzeller commented Mar 18, 2023

I heard once that fasm-parsing was eating a significant amount of time in some projects and wanted to have a quick look.

But when attempting to look at it a while back I couldn't get it even to compile because of a forest of intertangled Python dependencies . Looks like the early days were centered around Python for interactive and debugging reasons.
Given that fasm is used as an important part of actual flows these days, it is probably time to slim down the dependencies, and focus on it not being a bottleneck in production flows (Maybe still keep a Python implementation to focus for the interactive experiments.)

Since this project didn't compile but I still wanted to explore the format I ended up writing a parser in a header-only C++ implementation (including a C binding) to play with it. Content is parsed, values decoded and the feature names and bits are returned via callbacks. It parses FASM at about 1GiB/s per core.

Since I am not actively working in a project using fasm, I just leave it here in case you want to pick it up.
https://github.com/hzeller/simple-fasm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant