Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
deredede
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
9 ms
·
61.
▲
by
deredede
2y ago
While strictly speaking true I don't think it is the same argument at all. You are talking about a restriction of the runtime (much like mkdir argument length or maximum filesystem depth), even though it leaks into the standard because
62.
▲
by
deredede
2y ago
I am not talking about limitations of find or mkdir like other commenters are. I can write a Python program that simulates rule 110 with unbounded state width and unbounded iteration depth. I might not be able to execute it on any compute
63.
▲
by
deredede
2y ago
> >"You need 2 stacks for Turing completeness." > I am not completely sure about that assertion... What GP means is that a finite state machine is not Turing-complete, and neither is a finite state machine with a single s
64.
▲
by
deredede
2y ago
I don't understand how this shows Turing completeness. The implementation of the rule 110 automaton seems to be limited by both width (not Turing complete because there is a finite number of states of a given width) and iteration limit
65.
▲
by
deredede
2y ago
> another closure that closes over the first closure, just not to call it, but because the function pointer carries meaning for the purpose of clearing the timeout. Isn't the second closure closing over the timeout identifier, which
66.
▲
by
deredede
2y ago
> I think HN ate some characters because that code doesn't look valid. The OCaml compiler disagrees with you ;) It also won't ever turn a cons operation into a dynamic array append.
67.
▲
by
deredede
2y ago
The "sequence" in the problem statement does not refer to the order of operations but to the data structure storing the results. A parallel `Array.map` still computes a sequence, even though it may not compute in sequence.
68.
▲
by
deredede
2y ago
You can benefit from TCO while building multiple lists. let rec f evens odds = function | [] -> (evens, odds) | x :: xs -> if x mod 2 = 0 then f (x :: evens) odds xs else f evens (x :: odds) xs OCaml optimi
69.
▲
by
deredede
2y ago
The language specification says to use a single scope (see olliej's detailed comment). You could change it to use separate scopes here but it won't solve the more generic issue of imprecise captures, just this specific case.
70.
▲
by
deredede
2y ago
I think `Array.map` is a perfectly reasonable reading of "you're iterating over some structure and collecting your results in a sequence". But sure, in the `fold` scenario where you don't know the number of results in ad
71.
▲
by
deredede
2y ago
I mostly agree with your sentiment but this: > Well, no, this is straight confusion between what’s expressed by the program and what’s compiled. The idiomatic code in Ocaml will end up generating machine code which is as performant than
72.
▲
by
deredede
2y ago
Doesn't have to be. While storing them on your computer does not protect you from an adversary with access to your computer, it still protects you against an advrsaey e that intercepts (or guesses, maybe after a breach) your password.
73.
▲
by
deredede
2y ago
GitHub sent you those 4 strings while you were logged in and they are now stored on your computer. GitHub will not send them to an attacker that is not already logged in.
74.
▲
by
deredede
2y ago
When I was optimizing GPU kernels a few years back, Nvidia's own kernels were getting those last few percent of performance by making use of hardware-specific features (I remember operand caches being one) that are not available throug
75.
▲
by
deredede
2y ago
It is supposed to, yes. I was never able to set it up (admittedly I have not tried in a couple of years since I am not working with GPUs anymore) so I don't know how well it holds up.
76.
▲
by
deredede
2y ago
The difference is not just about APIs; CUDA has a single source file model that is dead easy to use whereas last I checked every competitor still had an outdated manual loading process that adds significant friction.
77.
▲
by
deredede
2y ago
> I don't understand the force of this no when the question is "is this like...". That's a solid yes as far as I can tell since the two papers are about the same general area. I understood the question as asking wheth
78.
▲
by
deredede
2y ago
Original focus was on parallelization, but nowadays polyhedral compilers also optimize for (cache) locality and reuse.
79.
▲
by
deredede
2y ago
No, "Polyhedral Code Generation in the Real World" (the paper you just linked) describes the code generation process of polyhedral compilers. Code generation is the last step of polyhedral compilation: first you model code using p
80.
▲
by
deredede
2y ago
I don't care where papers are published (in fact I mostly agree with you, I think that the idea that research needs to be novel to everyone currently in the field is harmful and leads to gate-keeping, self-censorship and unpublished fo
81.
▲
by
deredede
2y ago
This is not published at PLDI but at the co-located SOAP workshop.
82.
▲
by
deredede
2y ago
I used to feel this way because I lost work to `git stash pop` in the past, but there is now a nice feature where if you `git stash pop` and it doesn't cleanly applies, git keeps the stash and I use it more often now. That said for me
83.
▲
by
deredede
2y ago
I generally prefer PRs that have multiple atomic commits to be split up in separate PRs. If the atomic commits can't be reviewed separately/introduce non-working states, they are probably too small. > One rule I have for any re
84.
▲
by
deredede
2y ago
Yes and no - you can't have bi-variant argument types as shown here and be sound, but that does not mean you can't type those idioms. You just need the type system to be able to express a dependency between the name of the event h
85.
▲
by
deredede
2y ago
In other functional languages I tend to reach for combinators, but in OCaml I either use Menhir or regret not using it.
86.
▲
by
deredede
2y ago
My quotation was not good - I intended to reply to the argument that "nominal type do [exist at runtime] to some level". The newtype pattern in either Haskell or Rust is fully transparent at runtime.
87.
▲
by
deredede
2y ago
> Classes exist at runtime Not necessarily, depending on the language. Functional languages and system languages such as OCaml, Haskell, Rust, but also C (painfully) and C++ can represent wrapper types within a nominal type system at no
88.
▲
by
deredede
2y ago
That makes sense and fits what I had in mind: there is no formalization at the source level. Thanks for the details!
89.
▲
by
deredede
2y ago
Yeah, emoji on top of color is redundant and less legible. I find that people that use emojis for dashboards and the like tend to overuse them, but I agree with GP in that a single (well aligned and on an adequately colored background for c
90.
▲
by
deredede
2y ago
Since you contrast the two approaches you might be interested in learning that CompCert also uses translation validation in some part of the compiler (notably for register allocation), see Jean-Baptiste Tristan's papers with Xavier.
More ›