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

Technocracy 2.0

https://brooklynrail.org/2026/02/field-notes/technocracy-2-0/
1•antonomon•43s ago•0 comments

Something Wild Going on with Emails?

1•trevyn•49s ago•0 comments

Home Assistant Comm Badge

https://github.com/graffitiwriter/Home-Assistant-Comm-Badge
1•taubek•1m ago•0 comments

SanDisk crushes wallets with up to 2.8X SSD price hikes

https://www.tomshardware.com/pc-components/ssds/sandisk-crushes-wallets-with-up-to-2-8x-ssd-price...
1•vmykyt•4m ago•0 comments

Start all of your commands with a comma

https://rhodesmill.org/brandon/2009/commands-with-comma/
2•theblazehen•7m ago•0 comments

Sh-DSL – Write/Use Shell with Janet

https://janet-lang.org/spork/api/sh-dsl.html
1•veqq•7m ago•0 comments

Exploring Different Keyboard Sensing Technologies – LTT Labs

https://www.lttlabs.com/articles/2026/01/27/exploring-different-keyboard-sensing-technologies#buc...
1•rbanffy•7m ago•0 comments

Windsurf Tab v2

https://windsurf.com/blog/windsurf-tab-2
1•swyx•8m ago•0 comments

Securely run Claude Code agents in Docker

https://edspencer.net/2026/2/4/run-claude-code-agents-docker-herdctl
1•edspencer•8m ago•0 comments

Hand-Crafting Domain-Specific Compression with an LLM

https://engineering.nanit.com/hand-crafting-domain-specific-compression-with-an-llm-3c42f5c2b070
1•PaulHoule•9m ago•0 comments

The perks of being a mole rat

https://worksinprogress.co/issue/the-perks-of-being-a-mole-rat/
1•ortegaygasset•9m ago•0 comments

Show HN: A TikTok-style research paper reader

https://pokepaper.com/
1•hajimi_hacker•9m ago•0 comments

PaperBanana – Automating Academic Illustration

https://paperbanana.org/
1•bilsbie•11m ago•0 comments

Readr, Safari-Like Reading Mode for Chrome

https://github.com/login
1•ymolodtsov•11m ago•2 comments

GitHub integrates Claude and Codex AI coding agents directly into GitHub

https://github.blog/changelog/2026-02-04-claude-and-codex-are-now-available-in-public-preview-on-...
1•thoughtpeddler•11m ago•0 comments

ClickHouse Agent Skills

https://github.com/ClickHouse/agent-skills
1•clickpiper-pete•13m ago•0 comments

Anthropic's new AI tool: Next black stock market day for the software industry

https://www.heise.de/en/news/Anthropic-s-new-AI-tool-Next-black-stock-market-day-for-the-software...
1•doener•15m ago•1 comments

Ask HN: How can you enforce rules for Claude etc.

1•blackknightdev•15m ago•1 comments

Tell HN: Electrolux HR chief hired to layoff workforce bought 12 room apartment

2•dssadasadsdsa12•17m ago•2 comments

Mean People Fail (2014)

https://paulgraham.com/mean.html
13•insuranceguru•19m ago•12 comments

NYC subway gates tested by the MTA use AI tech to track fare evaders

https://gothamist.com/news/modern-nyc-subway-gates-tested-by-the-mta-use-ai-tech-to-track-fare-ev...
2•geox•19m ago•0 comments

Show HN: Autonomous AI radio station about engineering, history and philosophy

https://www.hermestransmissions.com/
1•ivanachillee•24m ago•0 comments

GitHub ponders kill switch for pull requests to stop AI slop

https://www.theregister.com/2026/02/03/github_kill_switch_pull_requests_ai/
1•abdelhousni•24m ago•2 comments

DaveLovable

https://github.com/davidmonterocrespo24/DaveLovable
1•dmcrespo•25m ago•0 comments

Why our society needs free and open power grid data [video]

https://fosdem.org/2026/schedule/event/WQBBR9-map-your-grid/
1•protontypes•25m ago•0 comments

Show HN: RAGStack – Scale-to-zero serverless RAG on your own AWS

https://portfolio.hatstack.fun/read/post/RAGStack-Lambda
1•hatmanstack•26m ago•0 comments

The Idea River

https://nik.art/the-idea-river/
1•herbertl•27m ago•0 comments

Beyond the Appearances: The joys of an Ideal world

https://aurelien2022.substack.com/p/beyond-the-appearances
1•OgsyedIE•28m ago•0 comments

LLM Data Exfiltration via URL Previews (With OpenClaw Example and Test)

https://www.promptarmor.com/resources/llm-data-exfiltration-via-url-previews-(with-openclaw-examp...
2•takira•29m ago•0 comments

MLflow's Missing Validators: An Authorization Bypass Across API Surfaces

https://tachyon.so/blog/mlfow-bypass
1•logicx24•30m ago•0 comments