frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Ask HN: Help with doing statistics over machine code

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

Post Mortem: axios NPM supply chain compromise

https://github.com/axios/axios/issues/10636
1•Kyro38•3m ago•0 comments

MCP, we barely knew thee

https://suthakamal.substack.com/p/mcp-we-barely-knew-thee
1•suthakamal•7m ago•1 comments

Show HN: Trytet – Deterministic WASM substrate for stateful AI agents

https://trytet.com
1•bneb-dev•8m ago•0 comments

Claude published XD 18 desktop pets companions

https://github.com/StartripAI/buddyClaw
1•AlfredHua1•12m ago•0 comments

NIH restrictions on foreign research partnerships impacted 1 in 4 scientists

https://www.statnews.com/2026/03/27/nih-funding-national-researcher-survey-foreign-subaward-ban-i...
1•maxall4•13m ago•0 comments

OMSCS Research – Research Authored by OMSCS Students

https://omscs.gatech.edu/omscs-research
1•kerim-ca•16m ago•0 comments

AI benchmarks are broken. Here's what we need instead

https://www.technologyreview.com/2026/03/31/1134833/ai-benchmarks-are-broken-heres-what-we-need-i...
2•reddome•18m ago•0 comments

Debate without hate – taout a portmanteau for "Talk It Out"

https://www.taout.tv/
1•fcpguru•20m ago•0 comments

AI Harness on Google Trends

https://trends.google.com/trends/explore?date=today%205-y&q=Ai%20harness&hl=en-GB
1•__natty__•21m ago•0 comments

Stellantis wants to build Chinese Leapmotor EVs at its idled Canadian plant

https://electrek.co/2026/04/02/stellantis-leapmotor-chinese-evs-brampton-canada-plant/
1•breve•26m ago•0 comments

US Army chief of staff fired by Hegseth

https://www.reuters.com/world/us/hegseth-has-asked-us-army-chief-staff-step-down-cbs-news-reports...
11•hedayet•27m ago•6 comments

Rap Dash

https://rapdash.com/
1•hackerbeat•29m ago•0 comments

Every Law a Commit – US Law in GitHub

https://v1d0b0t.github.io/blog/posts/2026-03-29-every-law-a-commit.html
3•nickvido•29m ago•0 comments

Lisa Core – semantic compression for AI conversations (80:1 ratio, 100% local)

https://chromewebstore.google.com/detail/lisa-core-ai-memory-libra/dmgnookddagimdcggdlbjmaobmoofhbj
3•AmarDahmani•29m ago•1 comments

Making samply profiles more useful

https://www.feldera.com/blog/making-samply-profiles-even-more-useful
4•gz09•30m ago•0 comments

Show HN: SkiFlee (an HTML5 game)

https://easel.games/@raysplaceinspace/skiflee
3•BSTRhino•33m ago•0 comments

Show HN: MicroSafe-RL – Sub-microsecond safety layer for Edge AI 1.18µs latency

https://github.com/Kretski/MicroSafe-RL
1•DREDREG•35m ago•0 comments

It's getting hard to justify app stores

https://codemade.net/blog/appstores-are-in-trouble/
5•lorisdev•36m ago•0 comments

Tor Alva: The Tallest 3D-Printed Building in the World

https://cacm.acm.org/blogcacm/tor-alva-the-tallest-3d-printed-building-in-the-world/
2•sohkamyung•37m ago•1 comments

Working group asks, what's the benefit of a brain?

https://www.santafe.edu/news-center/news/working-group-asks-whats-the-benefit-of-a-brain
1•hhs•37m ago•0 comments

AI for Software Engineering

https://mattamonroe.substack.com/p/ai-for-software-engineering
1•LaserathDax•37m ago•0 comments

The Dopamine Detox Myth Does It Work?

https://boredom-solver-rho.vercel.app/blog-dopamine-detox.html
2•myClover•38m ago•0 comments

Air India flight from US to New Delhi turns back after clogged toilets (2025)

https://www.cnn.com/2025/03/11/us/air-india-flight-chicago-rags-bags-clog-hnk
3•TMWNN•39m ago•1 comments

Node.js Security Bug Bounty Program Paused Due to Loss of Funding

https://nodejs.org/en/blog/announcements/discontinuing-security-bug-bounties
2•tjwds•39m ago•0 comments

On Taste

https://coghlan.me/on-taste/
1•mooreds•39m ago•0 comments

Harvard QCD Professor vibe codes quality research paper

https://www.anthropic.com/research/vibe-physics
1•jgamman•41m ago•1 comments

A Few Good Magazines From the 70s and 80s

https://www.bi6.us/CO/MG.HTML
3•OhMeadhbh•45m ago•0 comments

Kryptos – A Cryptography Library for Gleam Targets Both Erlang and JavaScript

https://github.com/jtdowney/kryptos
1•TheWiggles•47m ago•0 comments

Show HN: Made a little Artemis II tracker

https://artemis-ii-tracker.com/
5•codingmoh•47m ago•0 comments

AI-derived heart fat measures improve accuracy of cardio disease risk prediction

https://newsnetwork.mayoclinic.org/discussion/including-ai-derived-heart-fat-measurement-improves...
1•hhs•48m ago•0 comments