frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Ask HN: Help with doing statistics over machine code

2•phafu•8mo 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•8mo 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•8mo 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).

Minimal Launcher for Android

https://github.com/tanujnotes/Olauncher
2•vishnukvmd•2m ago•0 comments

Show HN: BlueMouse – open-source, local Socratic firewall for AI coding

https://github.com/peijun1700/bluemouse
1•bluemouse_ai•4m ago•0 comments

Romantics of the Distant

https://write.as/thoughts-on-nanofactories/romantics-of-the-distant
1•soundworlds•5m ago•0 comments

Fomu.cli

https://github.com/yuya-fujimoto/fomu.cli
1•yuyafujimoto•6m ago•0 comments

I Built an Accountability App After Failing Every Productivity System for 6 Year

https://testflight.apple.com/join/pSZMCBBg
1•hombreinabikin•7m ago•1 comments

Want to Keep Your Job? Buy Yourself a Blazer

https://www.bloomberg.com/opinion/articles/2026-01-21/dressing-like-a-slob-at-work-is-out-blazers...
1•petethomas•10m ago•0 comments

California sees 150k sign-ups for new data broker deletion request tool

https://www.cbsnews.com/sacramento/news/california-drop-tool-data-broker-deletion/
1•raybb•12m ago•0 comments

Agentic Memory: Unified Long-Term and Short-Term Memory Management for Agents

https://www.alphaxiv.org/abs/2601.01885
1•manthangupta109•14m ago•0 comments

Amthropic CEO claims we are 1yr away where AI can do everything SWEs

https://twitter.com/i/status/2013682941201678804
5•thewhitetulip•23m ago•0 comments

Trump admin sought redactions on China war game report warning

https://www.foxnews.com/politics/trump-admin-sought-redactions-key-china-war-game-report-warning-...
2•mudil•30m ago•0 comments

Vibe Coding Is Over, Now Just "Coding"

https://upstreamutopia.com/articles/?id=20260121-060942-vibe-coding-is-over,-now-ju
3•upstreamutopia•30m ago•0 comments

EU plans cybersecurity overhaul to block foreign high-risk suppliers

https://www.bleepingcomputer.com/news/security/eu-plans-cybersecurity-overhaul-to-block-foreign-h...
3•Yularar•33m ago•0 comments

Why neither Asia nor the US has produced a rival to ASML

https://www.ft.com/content/e47375fb-8c9f-4a4f-8526-8d46ededb805
2•perihelions•37m ago•0 comments

Curl removes bug bounties because of AI slop

https://etn.se/index.php/nyheter/72808-curl-removes-bug-bounties.html
13•jnord•37m ago•1 comments

Newbridge Cutlery to cease production of silver-plated tableware

https://www.rte.ie/news/business/2026/0120/1554085-newbridge-cutlery-company-to-close-factory/
1•austinallegro•41m ago•0 comments

Wolfi: Linux OS by Chainguard closed now for OSS

https://github.com/orgs/wolfi-dev/discussions/77550
1•shyim•42m ago•1 comments

Understanding Modern AI Is Understanding Embeddings: A Guide for Non-Programmers

https://sgnt.ai/p/embeddings-explainer/
2•dekervin•44m ago•0 comments

Show HN: Upgrade from Ralph to Eric for a more autonomous AI

https://dbuild.dev/blog/black-hole-from-ralph-to-eric/
1•Dbuild•45m ago•0 comments

Token Issuer Metadata: A Proposal for Config-as-Code SSO

https://docs.meetchar.ai/explanation/token-issuer-metadata
1•miguelspizza•45m ago•0 comments

88x31 badge for gen-AI free, 100% human-made works

https://aspiz.uk/100percenthuman/
1•aspizu•46m ago•2 comments

Hootsuite looking to work with ICE to 'build trust'

https://www.theglobeandmail.com/business/article-hootsuite-canada-vancouver-ice-social-media-cont...
2•petethomas•48m ago•0 comments

Alice and Bob in Wonderland - Identity and authority without servers (2024)

https://herbcaudill.com/words/20240602-local-first-auth
1•apitman•52m ago•0 comments

Implementing Dino from Scratch

https://logits.bearblog.dev/implementing-dino-from-scratch/
2•tgnk2341•54m ago•0 comments

Kleis: Structural Modeling with Symbolic Math and Types

https://kleis.io/
1•eatik•55m ago•0 comments

UK government considers social media ban for children

https://www.ft.com/content/15298c8c-d937-419c-8c9d-191589302704
3•1vuio0pswjnm7•56m ago•1 comments

Creating a Domain Specific Language with Roslyn

https://www.themacaque.com/2026/01/17/dsl-with-roslyn.html
1•azhenley•58m ago•0 comments

Why your power bill is spiking faster than a nearby data center's

https://www.washingtonpost.com/climate-environment/2026/01/15/power-electricity-cost-data-centers/
1•1vuio0pswjnm7•1h ago•0 comments

When to Use GenAI: A Practical Decision Framework

https://thenewstack.io/when-to-use-genai-a-practical-decision-framework/
1•bhaskarkollu•1h ago•0 comments

Governors confront electricity's rising costs as data centers expand

https://www.washingtonpost.com/business/2026/01/16/pjm-data-centers-electricity-bipartisan/
1•1vuio0pswjnm7•1h ago•0 comments

The Link List – Jan 2026 (Newsletter)

https://www.thelinklist.dev/blog/2026-01/
1•cwisecarver•1h ago•0 comments