frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Ask HN: Help with doing statistics over machine code

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

Do you wait for the AI while it works if you are a lawyer?

1•sean_hogle•3m ago•0 comments

The Table

https://github.com/timothyjrainwater-lab/The-Table
1•TimRain•7m ago•0 comments

Show HN: Preview CoreML video models on any video feed

https://cameragraph.app/
1•fasecharmer•9m ago•0 comments

Trump pauses China tech bans ahead of Xi summit

https://www.reuters.com/business/media-telecom/us-china-trade-detente-fuels-mothballing-key-china...
3•spenvo•10m ago•0 comments

Show HN: Wip – Monitor AI agent commits and local Git state from the CLI

https://github.com/drmnaik/wip
2•mahesh588•17m ago•0 comments

Show HN: 8M algorithms in 56 KB – Rust/WASM library for JavaScript

https://github.com/AdamPerlinski/micro-ml
1•adam_perlinski•17m ago•0 comments

Show HN: MicroGPT in 243 Lines – Demystifying the LLM Black Box

2•madugula•17m ago•0 comments

Richard Carrington's first portrait has been found

https://www.cnn.com/2026/02/12/science/solar-storm-richard-carrington-photo
1•YeGoblynQueenne•22m ago•0 comments

One Year of Work for Ten Seconds of Film [video]

https://www.youtube.com/watch?v=iq5JaG53dho
1•susam•24m ago•0 comments

Joseph Gordon-Levitt Gets Section 230 Completely Backwards

https://www.techdirt.com/2026/02/12/joseph-gordon-levitt-goes-to-washington-dc-gets-section-230-c...
2•HotGarbage•24m ago•0 comments

The Automated Soundboard for Streamers

https://killervibe.app
1•Jikouken•25m ago•0 comments

Mechanisms and control of spin interactions in molecular-scale spintronics(2025)

https://www.cell.com/newton/fulltext/S2950-6360(25)00162-8
1•rolph•26m ago•0 comments

Astronomers observe a star that quietly transformed into a black hole

https://www.reuters.com/science/astronomers-observe-star-that-quietly-transformed-into-black-hole...
2•1659447091•31m ago•0 comments

Robust ways to extract bank statements from PDF to CSV beyond raw LLMs?

https://exactstatement.com/
1•alexfefun1•32m ago•1 comments

Ask HN: What makes an AI agent framework production-ready vs. a toy?

1•winclaw-dev•33m ago•0 comments

Everybody Is a CEO Now (and What Am I Doing Here?)

https://www.behind-the-enemy-lines.com/2026/02/everybody-is-ceo-now-and-what-exactly.html
2•ziyao_w•38m ago•0 comments

TiDB Cloud Zero – full-featured database with one line of curl

https://zero.tidbcloud.com/
1•liydu•40m ago•0 comments

The Clash of Civilizationalisms

https://www.theideasletter.org/essay/the-clash-of-civilizationalisms/
2•thunderbong•40m ago•0 comments

Show HN: Open-source MCP server that lets AI assistants shop via Google's UCP

https://github.com/nguthrie/ucp-mcp-server
1•nguthrie•42m ago•0 comments

Show HN: WebExplorer – a tool for preview file in browser

https://www.webexplorer.app
2•feblr•45m ago•1 comments

Electronic Structure: Electron Spin: Videos and Practice Problems

https://www.pearson.com/channels/gob/learn/jules/ch-2-atoms-and-the-periodic-table/electronic-str...
1•rolph•47m ago•0 comments

What Makes Oxygen Special?

https://www.quanxr.org/elctronspins
1•rolph•49m ago•0 comments

Not all computer code protected as speech, US court finds in ghost gun case

https://www.reuters.com/legal/government/not-all-computer-code-protected-speech-us-appeals-court-...
6•1659447091•50m ago•0 comments

Building a Modular Python Application with apywire and starlette

https://alganet.github.io/blog/2026-02-12-22-Building-a-Modular-Application-with-apywire-and-star...
1•gaigalas•51m ago•0 comments

A Python terminal deep-space receiver

https://github.com/luisub/6EQUJ5
1•max_pearl•53m ago•0 comments

YouTube Launches on Apple Vision Pro

https://www.macrumors.com/2026/02/12/youtube-app-apple-vision-pro/
2•mgh2•54m ago•1 comments

Why Couples Fight in the Kitchen (A Furniture Problem, Not a Marriage Problem)

https://oedmethod.substack.com/p/why-couples-fight-in-the-kitchen
4•truenfel•54m ago•0 comments

Why have far-forward nominal Treasury rates increased so much in past few years?

https://www.federalreserve.gov/econres/notes/feds-notes/why-have-far-forward-nominal-treasury-rat...
2•toomuchtodo•58m ago•2 comments

Claude Code bug forces users to restart chat, wasting tokens

https://old.reddit.com/r/claude/comments/1o1csrq/api_error_400_due_to_tool_use_concurrency_issues/
4•behnamoh•58m ago•2 comments

NASA loading liquid hydrogen aboard Artemis 2 rocket in unannounced test

https://spaceflightnow.com/2026/02/12/nasa-loading-liquid-hydrogen-aboard-artemis-2-rocket-in-una...
1•bookmtn•1h ago•0 comments