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).

Temporal is code-first. We built the visual authoring layer it's missing

https://www.workflowbuilder.io/blog/temporal-workflow-editor-durable-execution-visual-authoring
1•maciek996•37s ago•0 comments

Bluesky will launch Reddit style communities

https://www.engadget.com/2192047/bluesky-will-launch-communities-this-year/
1•NordStreamYacht•1m ago•0 comments

Show HN: Fundamentalio – open-source AI-powered stock analysis tool

https://github.com/DjNero11/fundamentalio
1•DjNero•1m ago•0 comments

Olric: Distributed, in-memory key/value store and cache in Golang

https://github.com/olric-data/olric
1•mastabadtomm•2m ago•0 comments

Space Jam 1996

https://www.spacejam.com/1996/
2•valisvalis•4m ago•0 comments

Making Local LLM Fast

https://bogdan.nimblex.net/programming/2026/06/10/making-local-llm-fast.html
1•bogdan_r•5m ago•0 comments

The AI Agent in the Billing Department of Verizon Is a Mentally Handicapped Thug

https://samhenrycliff.medium.com/the-ai-agent-in-the-billing-department-of-verizon-wireless-is-a-...
1•6stringmerc•6m ago•0 comments

Archive-Minter – An offline-first web archiver built in Rust

https://github.com/DionisGedeshi/archive-minter
1•dioni_•8m ago•0 comments

USB Power Delivery: Plugging into the Benefits

https://www.aptiv.com/en/insights/article/usb-power-delivery-plugging-into-the-benefits
1•mooreds•10m ago•0 comments

iFixit tears down Trump Mobile [video]

https://www.youtube.com/watch?v=XHpP5otFv4M
1•peteforde•10m ago•0 comments

Mozilla to increase its free Firefox VPN limits and locations until Aug 31

https://blog.mozilla.org/en/firefox/firefox-built-in-vpn-summer/
1•exploraz•11m ago•0 comments

FlowG v0.59.0 with Dark Mode support

https://flowg.cloud/blog/darkmode
1•linkdd•14m ago•0 comments

A 5.3M-year-old deep-sea whale necropolis in the Diamantina Zone

https://www.nature.com/articles/s41586-026-10546-z
2•whicks•19m ago•0 comments

US Military Shahed-136 Kamikaze Drone Clone Getting Hivemind Swarming Capability

https://www.twz.com/air/u-s-militarys-lucas-kamikaze-drone-is-getting-hivemind-swarming-capability
1•prmph•19m ago•1 comments

Big tech apps that make life easy are scamming you

https://restofworld.org/2026/tech-facebook-google-whatsapp-scams/
1•donohoe•20m ago•0 comments

Show HN: EzziwebTools – A collection of 30 free tools

https://ezziwebtools.com
1•Ezzymd•20m ago•0 comments

Anthropic apologizes for invisible Claude Fable guardrails

https://www.theverge.com/ai-artificial-intelligence/948280/anthropic-claude-fable-invisible-disti...
1•rarisma•21m ago•0 comments

Show HN: AlfinaAI – AI stock and IPO analysis for retail investors

https://alfina.ai
2•stockanalyst987•23m ago•0 comments

InventorySpread – Newsletter ad slots priced below affiliate revenue

https://inventoryspread.com
1•Northtide•24m ago•1 comments

Active-active fixed our counters but broke everything else

https://useautumn.com/blog/active-active-redis-cache
2•johnyeocx•27m ago•0 comments

Python tool for converting files and office documents to Markdown

https://github.com/microsoft/markitdown
2•mooreds•28m ago•0 comments

Creating Photo Essays About Community: A Guide to Our Where We Are Contest

https://www.nytimes.com/2024/02/14/learning/creating-photo-essays-about-community-a-guide-to-our-...
1•tlyleung•29m ago•0 comments

Geopolitics fuel grain market volatility

https://www.kpler.com/blog/geopolitics-fuel-grain-market-volatility
1•mooreds•29m ago•0 comments

A Commons of Software Productive Infrastructure, by and for Capital

https://marewolf.me/posts/draupnir/26/software-productive-infrastructure.html
1•simonmic•29m ago•0 comments

Brit workers waste nearly six hours a week 'botsitting'

https://www.theregister.com/ai-and-ml/2026/06/10/brit-workers-waste-nearly-six-hours-a-week-botsi...
4•theanonymousone•30m ago•1 comments

Parallelogram – catch fine-tuning dataset bugs before training

https://www.parallelogram.dev/
1•thatayotlhe04•30m ago•0 comments

Hedge Funds Are Expanding Desks Designed to Profit from Natural-Catastrophe Risk

https://www.bloomberg.com/news/articles/2026-06-07/hedge-funds-are-hiring-experts-in-catastrophe-...
2•giuliomagnifico•31m ago•0 comments

Bootstrapping Rust Considered Harmful

https://www.ntecs.de/blog/2026-02-01-bootstrapping-rust-considered-harmful/
1•birdculture•33m ago•0 comments

I procrastinate by building tools to stop me from procrastinating: A sad story

2•thisislorenzov•34m ago•3 comments

Show HN: LoadLore – what if your team's way of working was installable?

https://loadlore.dev
1•whitephoenix•34m ago•0 comments