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

ClawRoulette

https://clawroulette.net/
1•bluesnowmonkey•27s ago•1 comments

Chinese RISC-V Chipmaker SpacemiT Launches K3 AI CPU

https://www.barchart.com/story/news/37312394/chinese-risc-v-chipmaker-spacemit-launches-k3-ai-cpu...
1•_____k•1m ago•0 comments

NASA delays Artemis moonshot with astronauts due to extreme cold in Florida

https://apnews.com/article/nasa-artemis-moon-astronauts-countdown-db49cef0eafce61f89a2984a5215c089
1•ck2•4m ago•1 comments

Qwen3-ASR Technical Report

https://arxiv.org/abs/2601.21337
1•_____k•4m ago•0 comments

Iran rounds up thousands in mass arrest campaign after crushing unrest

https://www.reuters.com/world/middle-east/iran-rounds-up-thousands-mass-arrest-campaign-after-cru...
2•mhb•5m ago•0 comments

Bloom's 2 Sigma Problem

https://en.wikipedia.org/wiki/Bloom%27s_2_sigma_problem
1•dedalus•6m ago•0 comments

Show HN: I treated my chronic rhomboid pain like a software bug (and fixed it)

https://deskrelief.gumroad.com/l/7-day-pain-relief
1•usrfours•7m ago•0 comments

The AI problem no one is talking about

https://morrick.me/archives/10241
1•latexr•8m ago•0 comments

I trapped an AI model inside an art installation (2025) [video]

https://www.youtube.com/watch?v=7fNYj0EXxMs
2•handfuloflight•11m ago•0 comments

Google AI Tool Let Users Make Rip-Off Nintendo Worlds

https://www.gamespot.com/articles/google-ai-tool-let-users-make-rip-off-nintendo-worlds/1100-6537...
1•_____k•12m ago•1 comments

Show HN: Fleabox – a minimal back end for self-hosted apps

https://github.com/jaksa76/fleabox
1•jaksa•16m ago•0 comments

You Should Make Web Games

https://jslegenddev.substack.com/p/you-should-make-web-games
3•JSLegendDev•17m ago•0 comments

Why the concrete in data centers is a hidden source of carbon emissions

https://www.latimes.com/business/story/2026-01-29/why-concrete-in-data-centers-is-hidden-source-o...
2•1vuio0pswjnm7•19m ago•0 comments

Waymo under scrutiny after hitting child near Santa Monica elementary school

https://www.latimes.com/business/story/2026-01-29/waymo-under-scrutiny-after-hitting-child-near-s...
2•1vuio0pswjnm7•20m ago•1 comments

AGI is here. Look busy

https://whilstinarrakis.wordpress.com/2026/01/29/agi-is-here-look-busy/
1•dylancollins•20m ago•0 comments

Google Engineer Found Guilty of Sending AI Secrets to China

https://www.justice.gov/opa/pr/former-google-engineer-found-guilty-economic-espionage-and-theft-c...
4•jedixit•23m ago•0 comments

Feasible keeping an internet connected device "unconpromised". (LTFT)

https://www.wsj.com/tech/google-aims-knockout-blow-at-chinese-company-linked-to-massive-cyber-wea...
1•SlavojsChef•26m ago•1 comments

Ask HN: How do you catch cron jobs that "succeed" but produce wrong results?

1•BlackPearl02•27m ago•1 comments

Israel accepts Gaza death toll is broadly accurate, saying 70k have died

https://www.theguardian.com/world/2026/jan/30/israel-military-gaza-death-toll-broadly-accurate
3•n1b0m•27m ago•0 comments

The case of the missing DNS packets (2020)

https://cloud.google.com/blog/topics/inside-google-cloud/google-cloud-support-engineer-solves-a-t...
2•fanf2•27m ago•0 comments

Show HN: Using World Models for Consistent AI Filmmaking

https://getartcraft.com/news/world-models-for-film
1•echelon•28m ago•0 comments

In the Lab – Soldering Prototypes with Enamel Magnet Wire

https://tomverbeure.github.io/2020/02/22/In-The-Lab-Magnet-Wire-Soldering.html
3•hasheddan•29m ago•0 comments

Courtney Love Does the Math (2000)

https://www.salon.com/2000/06/14/love_7/
1•sebg•30m ago•0 comments

Ammobia says it has reinvented a century-old technology

https://techcrunch.com/2026/01/13/ammobia-says-it-has-reinvented-a-century-old-technology/
1•PaulHoule•32m ago•0 comments

Show HN: JustNotifs – Push notifications for teams, flat $29/mo instead of SMS

https://justnotifs.com/
1•acaronlex•33m ago•0 comments

Thoughts on AI/LLM usage from a 25 year industry vet

2•hutchplusplus•35m ago•0 comments

Apple Human Interface Guidelines (1987)

https://archive.org/details/applehumaninterf00appl
1•wizardforhire•37m ago•0 comments

Belkin's Wemo smart devices will go offline on Saturday

https://www.theverge.com/tech/870890/belkin-wemo-cloud-services-shut-down
2•bookofjoe•38m ago•1 comments

Pages from Ceefax: Today's news at yesterday's pace

https://pagesfromceefax.azurewebsites.net/
1•xk3•38m ago•1 comments

Claude Code's GitHub page auto closes issues after 60 days

https://github.com/anthropics/claude-code/issues/16497
1•dcreater•39m ago•1 comments