frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Ask HN: Help with doing statistics over machine code

2•phafu•1y ago
I'd like to do some statistics over the machine code gcc generates, such as a histogram of used instructions, average volatile/preserved registers usage of functions etc. For now just x86_64 SysV-ABI would be enough.

However I'm not aware of any pre-existing tool that lets me easily do this. The options I currently see are either make gcc output assembly and write a parser for the GNU Assembler format (possibly by reusing the asm-parser of the compiler-explorer project), or write a tool that reads (disassembles) object files directly using elfutils.

Any hints, prior work, further ideas, links to useful resources, or any other kind of help would be much appreciated.

Comments

baobun•1y ago
"Static analysis" should be a relevant search term. Assuming you don't need to tie the instructions back to C code then the "gcc" part seems circumstancial for implementation? I guess you might want to parse the ASM into an Abstract Syntax Tree (AST) represenation and work on that?

If you do want to tie it back to the source, this looks relevant: http://icps.u-strasbg.fr/~pop/gcc-ast.html

phafu•1y ago
For my purpose I don't need to get back to the original source, no.

The gcc part is only relevant with regards to what dialect of assembler I need to parse. If I go that route, I'd write a parser for the GNU assembler, and that would of course work with any code in that dialect, regardless from which compiler it came from (I haven't checked whether other compilers can produce GNU assembler though).

Pilots taken to hospital after reported cockpit stabbing on Israel-bound flight

https://www.bbc.co.uk/news/live/cw980g1lem5pt
1•FridayoLeary•1m ago•0 comments

Show HN: AgentX – Run Claude Code, Codex or Any LLM from Your Chats and GitHub

https://github.com/anis-marrouchi/agentx
1•marrouchi•2m ago•0 comments

Fighting back against AI chatbots at work

2•FunForEveryone•2m ago•0 comments

The Internet has a second audience

https://blog.cloudflare.com/agentic-web/
1•torutofu•3m ago•0 comments

CanMV-K230D-Zero Development Board – RISC-V, 128MB LPDDR4 on MCU SoC

https://www.kendryte.com/k230_canmv/en/main/userguide/boards/canmv_k230d.html
1•peter_d_sherman•3m ago•0 comments

The last time my family was replaced by technology

https://manuel.darcemont.fr/posts/the-last-time-my-family-was-replaced-by-technology/
2•megalomanu•4m ago•0 comments

Reusable, testable decisions for agent orchestration with Jev

https://www.agentconnect.md/blog/introducing-jev-support/
2•zfy0701•6m ago•0 comments

Show HN: Overads, a superapp for marketing (content, publishing, ads, CRM)

https://overads.io
1•ishqdehlvi•6m ago•0 comments

Two Reports

https://terrytao.wordpress.com/2026/09/30/two-reports/
1•smilelamp•6m ago•0 comments

Show HN: SFML – A markup language for software factories, Terraform for agents

https://sfml.craftmill.dev/
1•mcwhittemore•7m ago•0 comments

How to update missing windows drivers in Windows 11?

2•lucytaylor01•8m ago•0 comments

We Will Forget How to Code. And That's OK

https://bosnadev.com/2026/09/28/we-will-forget-how-to-code
1•mirzap•9m ago•0 comments

Dubai to Tel Aviv flight made emergency landing due to fight between pilots

https://www.timesofisrael.com/liveblog_entry/hijacking-ruled-out-as-flydubai-flight-to-tel-aviv-l...
1•souvlakee•9m ago•1 comments

Nobody Is Thinking Anymore

https://yusufaytas.com/nobody-is-thinking-anymore
5•yusufaytas•9m ago•0 comments

Show HN: Four frontier models argue over your AI agent's riskiest code

https://truverif.ai/panel-review
1•vivekpolavarapu•9m ago•0 comments

Delegation Runs on Proof

https://www.forjal.com/research/delegation-runs-on-proof
2•Lucasllfs•9m ago•0 comments

Paper Console: A handmade thermal printer for news, weather, puzzles, and more

https://travismiller.design/paper-console/
1•sasvari•11m ago•0 comments

Sweaty Agent builder vs. Chill [video]

https://www.youtube.com/shorts/adzrrT1Z5gY
1•davletdz•12m ago•0 comments

Show HN: Limereach – a launch board where you engage before you post

https://limereach.com
1•pho3n1x•13m ago•0 comments

Behavioral Drift: Know When Your Agent Has Changed, Before Your Customers Do

https://medium.com/@MirArshadTalpur/behavioral-drift-know-when-your-agent-has-changed-before-your...
1•Arshad-Talpur•13m ago•1 comments

Show HN: Get your girlfriend back with AI

https://getdazzle.app/
1•dohoudjann•14m ago•1 comments

Vorlagenplatz

https://ailaunch.dev/p/vorlagenplatz
1•pb193105•14m ago•0 comments

Show HN: AilaFlow – AI workflow automation for teams with Human-AI interfaces

https://github.com/ailaflow/ailaflow
1•b4rtazz•15m ago•1 comments

Heimr 570M: a local model that stays fast as the context grows

https://sevren.ai/blog/heimr-570m
1•ilreb•16m ago•0 comments

Firefox Nova Is Here

https://blog.mozilla.org/addons/2026/09/29/nova-is-here-what-changes-for-your-firefox-theme/
2•_grilled_cheese•18m ago•1 comments

Vite+ 1.0

https://voidzero.dev/posts/announcing-vite-plus-1-0
2•TheAlexLichter•18m ago•0 comments

xAI. AI coworkers that learn from your team

https://x.ai/news/team-bots
1•iugtmkbdfil834•20m ago•0 comments

The road to daily-drivable mainline phones

https://nura.eco/blog/2026/09/29/road-to-main-category/
1•pamcake•21m ago•0 comments

Legal Graffiti Walls Around the World

https://www.legal-walls.net
1•bookofjoe•22m ago•0 comments

QLCodePreview, syntax highlighting in Finder's Quick Look

https://konstruukt.com/projects/qlcodepreview/
1•realityloop•23m ago•1 comments