HNHacker News
TopNewBestAskShowJobs

Avi-D-coder

474 karma · joined July 29, 2017

https://github.com/Avi-D-coder
submissionscomments
Avi-D-coder··on Ink programming language
https://craftinginterpreters.com/

If your in the mood to learn Haskell:

http://dev.stephendiehl.com/fun/ https://jktkops.github.io/Write-You-a-Haskell-2/

Avi-D-coder··on Substack's UI and 1Password temporarily cost me $2k
Similar experience on Firefox mobile
Avi-D-coder··on Monads and GATs in Nightly Rust
I'm working on fixing that ;)

Unfortunately we don't yet have covariant associated types, so my GC is a pain to use.

In all seriousness, I'm not sure if Rust will ever be a great fit for abstract high level programing. The syntax is just too verbose, and lifetimes are a leaky abstraction. It might make a good compiler target though. At the very least next generation FP needs to have a great Rust interop story.

Avi-D-coder··on Apple MBPr 13 M1 cinebench R23 score
Absolutely, that's one of the reasons I may buy a first generation Apple product.
Avi-D-coder··on Apple MBPr 13 M1 cinebench R23 score
I'm not comparing on the basis of TDP. I'm comparing performance/dollar.

I fully expect Apple's higher end, higher TDP chips to achieve better performance. But they will cost more money.

Like it or not the M1 is competing in a price bracket with the 4900HS.

Avi-D-coder··on Apple MBPr 13 M1 cinebench R23 score
A similarly priced Zephyrus G14 Ryzen 9 4900hs scores 1246/11006 (1).

I still may buy a M1 system, but I was hoping Apple would start competing in price/performance.

[1] https://www.cpu-monkey.com/en/cpu-amd_ryzen_9_4900hs-1285

Avi-D-coder··on Apple Silicon MacBook Air versus 13-inch MacBook Pro – which to buy
This article quotes the base model pro SSD as 512GB. This is incorrect. Both models start at 256GB.
Avi-D-coder··on Apple Silicon M1 chip in MacBook Air outperforms high-end 16-inch MacBook Pro
That is what I mean by active cooling.
Avi-D-coder··on Apple Silicon M1 chip in MacBook Air outperforms high-end 16-inch MacBook Pro
Air vs Pro, is the benchmark to look for.

I'll be interested to know how much active cooling and binning real do for Rustc or LLVM compilation times.

Avi-D-coder··on Students have to jump through absurd hoops to use exam monitoring software
At what point can we stop pretending most universities prepare you for the job market?

If your a professor that cares about Google give a rapid oral exam. If your a college professor giving multiple choice or other memorization based formats, what value are you providing over free online courses? Frankly, if your institution "has" to use this sort of software, it's not worth attending.

Avi-D-coder··on Fast Vue SSR with Rust and QuickJS
Zig is attempts to be a C replacement candidate, like Rust. What would make Rust or Zig a valid replacement in your opinion?
Avi-D-coder··on Fast Vue SSR with Rust and QuickJS
Zig, Nim, Crystal, Go and Swift all use C libraries extensively. Nim and Zig even make lower boiler plate C inter-op a key selling point.

Mozilla, Microsoft, Amazon, Apple and other's investments in Rust, clearly demonstrate the value of writing new systems software in Rust, alongside and inside existing C/C++ code bases. Rust is clearly monetarily useful, despite not being a systems programing panacea.

Avi-D-coder··on Fast Vue SSR with Rust and QuickJS
There will always be unsafe and often be C dependencies.

There is no community goal or plan to do away with unsafe. Until we have an easy to use fully dependent and linearly typed language, there will be some degree of unsafety. Even if Idris 3 and ATS 4 come out with magical proof inference, we will assert many more complicated proofs.

Avi-D-coder··on Rust: Dropping heavy things in another thread can make your code 10000x faster
Interestingly for the Rust GC I'm working both Drop and finalizers will be supported.

Do you happen to offer beat the programmer with a stick as a service?

Avi-D-coder··on Ask HN: What is your favorite way to read online content?
Yes it does, I mostly use pocket for tts, but the ui is worse. If you use android's local you can only skip forward and backwards 15 seconds, and it frequently loses your place if you pause it. @Voice allows you to tap on the text to seek.
Avi-D-coder··on Ask HN: What is your favorite way to read online content?
Pocket and @Voice apps tts. @Voice allows you to jump through text by double tapping and supports more sites and formats (PDF, etc.), but pocket manages your article list so much better so I use pocky 90% of the time.

Pockets uses a readermode view, so it's non tts UI is nicer, so if you don't care about tts just use pocket.

Firefox reader mode is also nice, Firefox preview is great.

Avi-D-coder··on Rust Analyzer: Next few years
I believe GATs are at least somewhat supported in chalk https://github.com/rust-lang/chalk/issues/116
Avi-D-coder··on Rust Analyzer: Next few years
What other major things are needed?
Avi-D-coder··on Demo of an OpenAI language model applied to code generation [video]
GPT2 is known to be unable to track and bind variables, scaling purely associative models beyond the trivial examples is going to be difficult or more likely impossible.

This will end up being a better tabnine. Models like GPT2 are still just approximating intelligence, they are not rationally cognizing.

Avi-D-coder··on Rust Analyzer: Next few years
Why is GAT struck out?
Avi-D-coder··on Examples of Incorrect Abstractions in Other Languages
We don't just write generics over types of strings ([Char], Text, etc..) we write over Semigroups and Monoids. Concatenation with <> is standard practice.
Avi-D-coder··on Electron 9.0
Intuitively it it feels like that should make swing faster, but experientially swing feels heavy and slow.

Is swing poorly optimized, is it due to being in Java?

I'm not a UI dev and have not thought about it much.

Avi-D-coder··on Electron 9.0
How is Swing closer to native than DOM?
Avi-D-coder··on Ask HN: Is there still a place for native desktop apps?
I wish I was not writing this, but no.

Outside of niche use cases you get two much with electron. Computers are so dam fast most users just don't care and those of us that do care use Linux anyway. If your app also runs nearly identically in a browser not just electron, on boring users is so much easier. I won't install an app just to try it, but I will use a website and reluctantly upgrade to electron.

A sand-boxed stripped down electron replacement as a system library, ala Deno for UI will replace electron in the next few years. Web-Native frameworks targeting WASM, WebGPU for responsive components and Dom for everything else will replace JavaScript, but the web will win.

Avi-D-coder··on A highly efficient, real-time text-to-speech system deployed on CPUs
Any chance of a open source implementation of this?

I could really use a better tts for Linux.

Avi-D-coder··on Up to 4GB of Memory in WebAssembly
Immutable data structures tend to use a lot of pointers see how Haskell executes, even in other paradigms halving pointer s can have a significant impact on alignment (tags, enums, etc).

V8 sandboxes WASM by placing them in a dedicated OS process, this buys 64 bit pointers, but comes at a cost. We can chose for a 64 bit processor to buy us in process memory isolation, by masking pointers or we can have 64 bit pointers.

Avi-D-coder··on Up to 4GB of Memory in WebAssembly
Why prefer 64bit pointers over multiple memory address spaces (https://github.com/WebAssembly/multi-memory)? Your CPU has to do a lot of work to keep pretending it's memory is flat, If we give up that pretense you can optimize cache utilization and multiplex multiple WASM threads onto a single OS thread without allowing specter.
Avi-D-coder··on Deno 1.0
This is fantastic. I would love to see vscode, coc, kde, gnome and other applications that use node extensions, to adopt Deno.
Avi-D-coder··on GitHub Codespaces
This is great. We all knew it was coming, but I wish they hadn't axed xray.

Has vscode performance improved in recent history? Are there any plans to replace hot code paths with Rust or wasm? Has modal editing improved? I'm not against using vscode, but even with codespaces it's a hard sell.

Avi-D-coder··on How Recursion Got into Programming (2014)
If it makes you feel any better, I'd bet you all 3 UFOs still use call stacks. Even aliens are stuck on 8086 esque CPUs ;)
← PreviousPage 2 of 4Next →