frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Show HN: Coderive – Iterating through 1 Quintillion Inside a Loop in just 50ms

https://github.com/DanexCodr/Coderive
6•DanexCodr•4d ago
Author: Danison Nuñez Project: Coderive Project Type: Programming Language Highlight: Formula-based Execution

## Coderive - Iterating Through 1 Quintillion in a Loop

*Subtitle: How a phone interpreter achieves what supercomputers cannot*

The Impossible Loop:

```java // In any other language, this would be computational suicide for i in [0 to 1Qi] { // 1,000,000,000,000,000,000 iterations arr[i] = i * i } ```

Traditional Reality:

· Python: MemoryError at array creation · Java/C++: Theoretical 31 years (with 8 exabytes of RAM) · NumPy/TensorFlow: Immediate crash · GPU Computing: 80GB VRAM limit exceeded

Coderive's Reality: 50 milliseconds.

The Magic Behind It:

1. NaturalArray: Virtual arrays that store formulas, not data 2. Runtime Pattern Detection: Transforms loops to mathematical expressions 3. Lazy Evaluation: Computes only what's accessed 4. Formula Storage: LoopFormula, ConditionalFormula, MultiBranchFormula

Technical Deep Dive:

```java // What you write: for i in [0 to 1Qi] { if i % 2 == 0 { arr[i] = i * i } elif i % 3 == 0 { arr[i] = i * i * i } else { arr[i] = i } }

// What Coderive creates internally: arr.addMultiBranchFormula( conditions: [i%2==0, i%3==0], expressions: [ii, iii], elseExpr: i, range: [0, 1Qi] ) ```

The Optimization Pipeline:

``` User Code → Pattern Detection → Formula Creation → Lazy Evaluation ↓ ↓ ↓ ↓ O(n) O(1) O(1) O(1) per access ```

Complete Pattern Coverage:

· Simple Transformations: arr[i] = f(i) → LoopFormula · Binary Decisions: if-else → ConditionalFormula · Multi-way Branches: if-elif-else → MultiBranchFormula · Partial Updates: if-only with implicit else preservation

Real-World Impact:

```java // Process every pixel in 8K video (≈33 million frames) for frame in [0 to 33M] { for pixel in [0 to 7680

4320] { // 33 million frames × 33 million pixels if brightness > 128 { pixels[pixel] = 255 } elif brightness > 64 { pixels[pixel] = 128 } else { pixels[pixel] = 0 } } } // Traditional: Impossible // Coderive: Seconds, not centuries ```

The Secret Sauce:

· No data movement (arrays stay virtual) · No parallel programming (formulas are inherently parallel) · No memory management (O(1) memory complexity) · No specialized hardware (runs on Java 7)

Conclusion: Coderive doesn't just make loops faster—it redefines what's computationally possible on commodity hardware.

Check Coderive now at: [https://github.com/DanexCodr/Coderive](https://github.com/DanexCodr/Coderive)

Comments

onion2k•1h ago
I'm intrigued about how you're loading a 13.66 days long 8K video into memory to be able to process all the pixels in 50ms...
schobi•1h ago
I'm confused by the claims..

You try to compute something that supercomputer can't - by not computing it? Instead the formula is stored in a data structure. But once you need to access all the values you still have something that does not fit the memory and needs to be computed.

I can't judge on the Java side, but suggest to pick a better example on how this can be useful.

Validark•44m ago
Why did you restrict yourself to mobile development only?
MobiusHorizons•30m ago
> Conclusion: Coderive doesn't just make loops faster—it redefines what's computationally possible on commodity hardware.

I mean this as kindly as possible, but please don’t say things like this if you want to be taken seriously. Computer languages cannot possibly change what is possible on a given machine for the simple reason that whatever they are doing had to previously be possible in assembly on the same machine.

I don’t mean to overly discourage you. Lazy execution can be very useful, but it’s also not clearly new or hard to get in other languages (although it would require different syntax than an idiomatic for loop most of the time). It may help to try to pick an example where the lazy execution is actually exercised. Preferably one that would be hard for an optimizing compiler to optimize.

I would also not recommend claiming iteration if you also claim 50ms, since that’s clearly impossible regardless of memory consumption, so you have to optimize away or defer the work in some way (at which point iteration is no longer occurring).

For these examples, I think you would just express the code as a function taking i instead of pre-populating the array. This doesn’t seem hard at least for the provided examples, and has the benefit that it can be opted into when appropriate.

Show HN: Gaming Couch – a local multiplayer party game platform for 8 players

https://gamingcouch.com
199•ChaosOp•4d ago•53 comments

Show HN: GeneGuessr – a daily biology web puzzle

https://geneguessr.brinedew.bio/
34•brinedew•3d ago•7 comments

Show HN: Domain Search MCP – AI-powered domain availability checker

https://github.com/dorukardahan/domain-search-mcp
2•dorukardahan•1h ago•1 comments

Show HN: Lamp Carousel – DIY kinetic sculpture powered by lamp heat (2024)

https://evan.widloski.com/posts/spinners/
82•Evidlo•1d ago•14 comments

Show HN: AI Accel,Tension-based pruning framework(40% sparsity, 1.5-2x speedups)

https://github.com/wwes4/AI_Accel_1.5x
2•wwes369•3h ago•0 comments

Show HN: Minimalist editor that lives in browser, stores everything in the URL

https://github.com/antonmedv/textarea
444•medv•1d ago•163 comments

Show HN: Exploring Mathematics with Python

https://coe.psu.ac.th/ad/explore/
250•Andrew2565•6d ago•27 comments

Show HN: I embedded 10M StreetView images

https://view.geospot.sdan.io/
8•sdan•13h ago•2 comments

Show HN: Vibium – Browser automation for AI and humans, by Selenium's creator

https://github.com/VibiumDev/vibium
426•hugs•1d ago•116 comments

Show HN: A Claude Code plugin that catch destructive Git and filesystem commands

https://github.com/kenryu42/claude-code-safety-net
3•kenryu•7h ago•0 comments

Show HN: Why many AI-generated websites don't show up on Google

https://pagesmith.ai/seo-for-ai-generated-sites
9•manu_trustdom•17h ago•3 comments

Show HN: I treated my brain like a buggy server and wrote a patch (Shi-Mo Model)

https://github.com/317317317apple-a11y/shi-mo-protocol/blob/main/README.md
11•ShiMo_Protocol•17h ago•1 comments

Show HN: CineCLI – Browse and torrent movies directly from your terminal

https://github.com/eyeblech/cinecli
341•samsep10l•3d ago•106 comments

Show HN: I built an OCI container runtime in Python(for fun)

https://github.com/Kaleab-Ayenew/puncker-rt
5•kalishayish•15h ago•0 comments

Show HN: Turn raw HTML into production-ready images for free

https://html2png.dev
147•alvinunreal•2d ago•80 comments

Show HN: Frame an web synth for desktop or mobile with hand gesture support

https://oyehoy.net/
2•markrai•11h ago•0 comments

Show HN: A local-first, reversible PII scrubber for AI workflows

https://medium.com/@tj.ruesch/a-local-first-reversible-pii-scrubber-for-ai-workflows-using-onnx-a...
36•tjruesch•1d ago•11 comments

Show HN: WebPtoPNG – I built a WebP to PNG tool, everything runs in the browser

https://webptopng.cc/
20•akseli_ukkonen•1d ago•19 comments

Show HN: Kill List–A local-first PWA where tasks deletes if not done by midnight

https://killlist-production.up.railway.app
3•msldiarra•11h ago•5 comments

Show HN: Typed-Prompts – Type-Safe Prompt Engineering

https://github.com/f/awesome-chatgpt-prompts/tree/main/packages/prompts.chat
2•fka•12h ago•3 comments

Show HN: Jmail – Google Suite for Epstein files

https://www.jmail.world
1547•lukeigel•5d ago•359 comments

Show HN: FIDO2 PRF with TPM and Fingerprint Auth for Confer on Linux

https://vitorpy.com/blog/2025-12-25-confer-to-linux-tpm-fido2-prf/
2•vpb•12h ago•0 comments

Show HN: OmniWM a macOS tiling window manager Niri inspired

https://github.com/BarutSRB/OmniWM
5•Barut1•12h ago•1 comments

Show HN: ReadHn - Reading list for top HN posts

https://www.readhn.top/
10•taabishm2•1d ago•0 comments

Show HN: Kapso – WhatsApp for developers

https://kapso.ai/
43•aamatte•2d ago•22 comments

Show HN: Microsoft Agent Viewer

https://acs-viewer.pages.dev/
8•ellg•1d ago•0 comments

Show HN: Pivor, Open source self-hosted CRM

https://github.com/Lexaro-Software/pivor
5•acaronlex•14h ago•2 comments

Show HN: I Updated My 2D Ant Game for the Holidays

https://github.com/aanthonymax/ant-and-apples
3•aanthonymax•15h ago•0 comments

Show HN: CLI to share secrets using one-time public keys

https://github.com/scosman/secret_share
3•scosman•16h ago•0 comments

Show HN: HN Wrapped 2025 - an LLM reviews your year on HN

https://hn-wrapped.kadoa.com?year=2025
311•hubraumhugo•5d ago•153 comments