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

Results from the 2025 Go Developer Survey

https://go.dev/blog/survey2025
1•prattmic•23s ago•0 comments

A zero-overhead bridge between C++23 std:mdspan and CUTLASS cute layouts

https://github.com/weyl-ai/mdspan-cute
1•benreesman•4m ago•1 comments

SUPERMAN Written by James Gunn [pdf]

https://www.superman.com/script/supermanscript.pdf
1•hbcondo714•4m ago•0 comments

Sine – The ultimate theme manager for Firefox-based browsers

https://github.com/CosmoCreeper/Sine
1•modinfo•5m ago•0 comments

Show HN: Roo Code Slack: end to end agentic workflow in Slack

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

Ask HN: CVAT users, how do you QA labels?

1•Abderrahman54•11m ago•1 comments

2025 AI Wrapped: What I've Shipped with 100% AI-generated code

https://www.jsrowe.com/ai-wrapped-evolution-of-using-ai-every-day/
3•jsr6720•12m ago•0 comments

Best Practices for Claude Code

https://code.claude.com/docs/en/best-practices
1•mfiguiere•13m ago•0 comments

Show HN: Markdown TOC generator for JavaScript builds.Works recursively for repo

1•datalackey•13m ago•0 comments

Delta single handle ball faucets (1963)

https://archive.org/details/DeltaSingleHandleBallFaucets
1•userbinator•14m ago•0 comments

Meta Pays $3B for Manus: Its Fastest Path to AI Agent Dominance

https://gilpignol.substack.com/p/meta-pays-3-billion-for-manus-its
1•light_triad•14m ago•0 comments

Show HN: Wisp: Stateful Claude Code Management

https://github.com/canaanmckenzie/Wisp
2•prince_nez•16m ago•0 comments

ClearFlow Keyboard

https://clearflowkeyboard.github.io/
2•_thisdot•19m ago•0 comments

SlimEdge: Lightweight Distributed DNN Deployment on Constrained Hardware

https://arxiv.org/abs/2512.22136
1•PaulHoule•23m ago•0 comments

High speed graphics rendering research with tinygrad/tinyJIT

https://github.com/quantbagel/gtinygrad
3•quantbagel•24m ago•0 comments

Show HN: Laptop Stickers – cheap individual short run stickers

https://laptopstickers.store/
1•decryption•24m ago•0 comments

Libcurl Memory Use Some Years Later

https://daniel.haxx.se/blog/2026/01/21/libcurl-memory-use-some-years-later/
3•firesteelrain•26m ago•0 comments

Waymo founder John Krafcik: Tesla's Full Self-Driving has 'bad case of myopia'

https://electrek.co/2026/01/20/waymo-founder-john-krafcik-teslas-full-self-driving-myopia/
1•senti_sentient•30m ago•0 comments

Infinite Jest

https://infinijest.com
3•hn_throway•30m ago•1 comments

Show HN: I built an AI that calls you and practices spoken English with you

https://englishcall.online/
2•rahma_tm•33m ago•0 comments

Why Big Tech Performance Reviews Aren't Meritocratic

https://medium.com/data-science-collective/big-tech-performance-review-01fff2c5924d
3•dikobraz•42m ago•1 comments

Time Until Someone Points Out This Is Not a Real Study

https://journal-preliminary-results.fly.dev/38472951
1•ipnon•45m ago•0 comments

Agree or Disagree

https://a-or-d.lovable.app
2•Conceiver•45m ago•0 comments

Dev Logs Without the Noise (2024)

https://peterlyons.com/problog/2024/08/dev-logs-without-the-noise/
1•mooreds•45m ago•0 comments

Ruby_LLM-agents: A Rails agent framework for RubyLLM

https://github.com/adham90/ruby_llm-agents
1•thunderbong•48m ago•0 comments

The secret fast track for animal drugs (2025)

https://worksinprogress.co/issue/the-secret-fast-track-for-animal-drugs/
1•mooreds•48m ago•0 comments

Rise in Sophisticated Dark Patterns Designed to Trick and Trap Consumers (2022)

https://www.ftc.gov/news-events/news/press-releases/2022/09/ftc-report-shows-rise-sophisticated-d...
4•wslh•51m ago•0 comments

Change Blindness in UX (2018)

https://www.nngroup.com/articles/change-blindness-definition/
1•wslh•54m ago•0 comments

Rust's Standard Library on the GPU

https://www.vectorware.com/blog/rust-std-on-gpu/
1•sbt567•55m ago•0 comments

Community Pulse 2025 End of Year Wrap-Up [audio]

https://www.communitypulse.io/102-2025-wrap-up
1•mooreds•55m ago•0 comments