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

Show HN: Shellphone – Access your AI coding agent from your phone via QR code

https://github.com/laleshii/shellphone
1•laleshii•11s ago•0 comments

Takeaway and food delivery are having a growing impact on inflation

https://www.dnb.nl/en/general-news/background-2026/takeaway-and-food-delivery-services-are-having...
1•andrewstetsenko•18s ago•0 comments

Desperate US sailors trying to jump overboard on extended Middle East deployment

https://www.independent.co.uk/news/world/americas/middle-east-abraham-lincon-sailors-iran-b303171...
1•speckx•1m ago•0 comments

Show HN: Landing page demos that run the real app in a microVM per visitor

https://www.paperplanes.sh/demo
1•lasdw•1m ago•0 comments

DeepSeek has started hiring civil engineers, in electrical, HVAC etc.

https://twitter.com/yicaichina/status/2087369744277987522
1•theanonymousone•2m ago•0 comments

Maintainer's advice on contributing to open-source in 2026

https://martinsos.com/posts/contributing-in-2026
1•matijash•3m ago•0 comments

MinIO is now community-forked as Silo

https://github.com/pgsty/silo/releases/tag/RELEASE.2026-08-06T00-00-00Z
1•spapas82•3m ago•0 comments

Show HN: Track habits, metrics, time and whateven you think worth tracking

https://habitpocket.io/
2•bohdanstefaniuk•4m ago•1 comments

Hetzner Prices Rose 187–250%. The CPUs Barely Moved: 24 VM Deployments

https://webbynode.com/articles/hetzner-prices-rose-cpus-barely-moved
2•gsgreen•5m ago•1 comments

Do Your Emojis Make You Look Old?

https://www.nytimes.com/interactive/2026/08/12/upshot/emoji-generations.html
1•tysone•6m ago•0 comments

Text AI watermarks will always be trivial to remove

https://www.seangoedecke.com/text-ai-watermarks/
3•pseudolus•6m ago•0 comments

'Zoomsday' flaw lets anyone in a Zoom call take over any device

https://www.tomshardware.com/tech-industry/cyber-security/zoomsday-vulnerability-let-anyone-in-a-...
3•sbulaev•6m ago•0 comments

Show HN: Agent-to-agent discovery through Cloudflare Worker via MCP

https://aidress-agent.mehul-1fd.workers.dev/
1•mehulv24•7m ago•0 comments

Not so competent AI overlords

https://pauljacobson.me/2026/08/12/not-so-competent-ai-overlords/
1•speckx•8m ago•0 comments

The Cloudflare AI Psychosis

https://opensauce.it/cloudflare-ai-psychosis/
3•orliesaurus•8m ago•0 comments

Linux Patches Enable Apple M4 NVMe Support

https://www.phoronix.com/news/Linux-Apple-M4-NVMe-Patches
1•DemiGuru•8m ago•0 comments

Engineering managers are back in the codebase

https://leaddev.com/management/engineering-managers-are-back-in-the-codebase
1•mooreds•9m ago•0 comments

Sweden's IF Metall ends Tesla strike after carmaker buys out union members

https://www.reuters.com/world/middle-east/iran-parliament-speaker-says-lebanon-ceasefire-asset-re...
1•reimertz•10m ago•0 comments

Nova-Quantum – Bare-Metal LLM Kernel (41 MB ISO, Bootet Ohne OS)

https://nova-quantum-gray.vercel.app
1•ChristianSchmit•12m ago•0 comments

What's the next 1000x opportunity?

2•mvg777•12m ago•2 comments

DeepSeek-V4-Pro

https://twitter.com/deepseek_ai/status/2087864585504305397
1•tosh•12m ago•0 comments

Taffy: A flexible, high-performance, cross-platform UI layout library

https://github.com/DioxusLabs/taffy
1•robin_reala•17m ago•0 comments

Our Self-Building Slackbot

https://blog.val.town/slackbot-townie
1•stevekrouse•17m ago•0 comments

Show HN: Jump to Video, an audio-first way to catch the on-screen moment

https://podtastic.app/
1•benbowler•17m ago•0 comments

What's behind the rise of teens spying for Russia?

https://mssv.net/2026/08/13/whats-behind-the-rise-of-teens-spying-for-russia/
1•adrianhon•17m ago•0 comments

Digital Stamp Maker

https://digitalstampmaker.app/
1•yitaowang•19m ago•0 comments

The study that would tell us if faster AI coding models help doesn't exist

https://viborc.com/can-faster-ai-inference-give-developers-their-flow-back/
1•viborcip•20m ago•0 comments

Indie projects exploded after GPT/Claude Code, but traction stayed flat

https://www.orangecrumbs.com/stories/show-hn
3•oyster143•20m ago•1 comments

GitHub Actions Database

https://actionaut.dev/
1•alpha_trion•21m ago•1 comments

Circle – A new era for digital businesses

https://circle.so
1•janandonly•21m ago•0 comments