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: Manygit – a lazygit-style TUI for a whole folder of Git repos

https://rabeeh-ta.github.io/manygit/
1•rabeeh0ta•4s ago•0 comments

The Predictor in the Room

https://substack.com/@valewen/p-188912694
1•hiramwen•1m ago•0 comments

Show HN: How to Mentally Calculate the Day of the Week for Any Date

https://tinkerandsee.com/weekday/
2•yang140•2m ago•0 comments

Hugging Face exploring sale valuing it at $13B, Business Insider says

https://finance.yahoo.com/technology/ai/articles/hugging-face-exploring-sale-valuing-200012818.html
1•AbstractH24•2m ago•1 comments

Will the DOJ's investigation into A16Z spook other VCs?

https://techcrunch.com/2026/08/22/will-the-dojs-investigation-into-a16z-spook-other-vcs/
2•rbanffy•3m ago•0 comments

Postgres 19: How Our Advice Has Changed Since We Wrote It

https://www.crunchydata.com/blog/postgres-19-how-our-advice-has-changed-since-we-wrote-it
1•craigkerstiens•3m ago•0 comments

Show HN: Gemini models are getting better – we can prove it

https://github.com/awesoftsolutions/google_gemini_flash_comparison
1•favurdev•3m ago•0 comments

Letsplay

https://jeopardylabs.com/play/expectations-jeopardy-
1•gydeonhall•5m ago•0 comments

Here's Where Our Memories Go as We Age

https://nautil.us/heres-where-our-memories-go-as-we-age-1284123
2•Brajeshwar•5m ago•0 comments

How an LLM Serves a Request

https://mapathak-commits.github.io/inference-wall/articles/primer/
1•sudomax•5m ago•0 comments

A Human for Your AI

https://yourhuman.ai/
1•sanj•5m ago•0 comments

Hugging Face looking to sell for at least $13B

https://www.businessinsider.com/hugging-face-could-be-acquired-13-billion-2026-8
2•gk1•6m ago•0 comments

Show HN: Tblue – 614 passive security scanners for any website, runs locally

https://github.com/taylannuhogluofficial-png/Tblue
2•taylannuhoglu•6m ago•0 comments

AliExpress Silent WebAudio Fingerprinting Uses Bluetooth Hardware

https://beyondmachines.net/event_details/aliexpress-silent-webaudio-fingerprinting-uses-bluetooth...
1•MBCook•7m ago•0 comments

Show HN: TestOptim AI – AI QA testing that finds and files issues automatically

https://www.testoptim.com
1•shahidhelalkhan•7m ago•0 comments

Release Nvim 0.12.5

https://github.com/neovim/neovim/releases/tag/v0.12.5
2•DemiGuru•8m ago•0 comments

Show HN: HN Notify – Subscribe to HN replies, users, keywords, and domains

https://hnnotify.org/
1•jermaustin1•9m ago•0 comments

Walgit – a Git server that is one binary in front of an object store

https://github.com/tobi/walgit
2•matallo•10m ago•0 comments

Hot Chips 2026: Applying High Bandwidth Flash (HBF)

https://chipsandcheese.com/p/hot-chips-2026-applying-high-bandwidth
2•ksec•10m ago•0 comments

Show HN: AgentIn, a professional network for coding agents

https://agentin.work/
1•TimCTRL•11m ago•0 comments

Show HN: Unifly is a UniFi CLI for humans and agents

https://github.com/hyperb1iss/unifly
1•hyperb1iss•11m ago•0 comments

Chrome extension that groups tabs by site automatically

https://github.com/akiraysh/chrome-tab-grouper
1•akiraysh09•12m ago•0 comments

Codefloe Is a Professionally Hosted Public Git Forge

https://codefloe.com/
2•jeremyjh•13m ago•0 comments

How to **** ** a Data Center [video]

https://www.youtube.com/watch?v=bVYmNJGjFnI
2•rglover•13m ago•0 comments

Running AI agents non-interactively in CI and scripts

https://octomind.run/blog/octomind-non-interactive-ci-automation
1•donk8r•14m ago•0 comments

AI Is Ruining Scholarship

https://www.chronicle.com/article/ai-is-ruining-scholarship
2•speckx•14m ago•0 comments

Peppermint oil reduces blood pressure by 8.48 mmHg in small study

https://journals.plos.org/plosone/article?id=10.1371/journal.pone.0344538
1•brandonb•14m ago•0 comments

Show HN: Galaxium, an experimental WebGPU space explorer

https://galaxium.app
1•guillaumec•15m ago•1 comments

Character Input

https://www.practicepython.org/exercise/2014/01/29/01-character-input.html
1•mahourkasraei•15m ago•0 comments

Skipping with OhmJS

https://programmingsimplicity.substack.com/p/skipping-with-ohmjs
1•surprisetalk•19m ago•0 comments