News for hackers. Stuff that matters.

baziotis

Re: on Tuesday April 22, 2025 @06:19PM (#43766840)
On May 7th I'll have a discussion with Federica Frabetti, the author of the amazing book: Software Theory: A Cultural and Philosophical Study. Federica is an Associate Professor in Digital Media at the University of Roehampton, and a former software engineer. The book will be the focus of our discussion. In it, Federica draws upon the work of (underrated) figures like Bernard Stiegler, Jacques Derrida, and Timothy Clark, to enable a new cultural and political understanding of software.

You can send me your questions for Federica using THIS FORM: https://docs.google.com/forms/d/e/1FAIpQLSe3B8mnk7jS6yNLDj1L...

Re:Questions for William J. Rapaport on Thursday March 13, 2025 @03:36PM (#43356558)
That's cool! I've heard similar nice words from other people who had him as a professor, advisor, etc.
Re:Questions for William J. Rapaport on Thursday March 13, 2025 @03:35PM (#43356550)
Thanks for the comment and I'm sorry for the late response. HackerNews is bad in that you get no notifications. I agree and I updated the form, although I suspect no one will see it now :-)
Re:Questions for William J. Rapaport on Thursday March 06, 2025 @01:24PM (#43283368)
On March 27 I'll have a discussion with William J. Rapaport (https://cse.buffalo.edu/~rapaport/). William is a Professor at U at Buffalo, a philosopher and computer scientist specializing in AI. He has written the book Philosophy of Computer Science: An Introduction to the Issues and the Literature (https://www.wiley.com/en-us/Philosophy+of+Computer+Science%3...), one of the authoritative sources on the topic. He has also published multiple papers on the topic. His 2 most recent ones are: (1) Will AI Succeed? The “Yes” Position (https://cse.buffalo.edu/~rapaport/Papers/aidebate.pdf), (2) Large Language Models and the Turing Test: The “Use of Words” vs. “General Educated Opinion” (https://cse.buffalo.edu/~rapaport/Papers/llmtt.pdf).

William has almost no talks or interviews online. I thought this would be a one-time opportunity for anyone interested in these topics to pose questions to William directly! So, if you have a question for William, please send it to me using THIS FORM: https://docs.google.com/forms/d/e/1FAIpQLScu0u_nW3S94CfrEGza...! Also, feel free to forward it to anyone you think would be interested.

If you want to get a notification when this interview gets published, you can either subscribe to my newsletter: https://sbaziotis.com/#news or to my Youtube channel: https://www.youtube.com/@stefanosbaziotis

Re: on Wednesday February 12, 2025 @06:58PM (#43031140)
4 short essays: - On the value of a non-thesis CS master's in a top school in the US - Descartes' conception of infinity - Unified theories as a type of compression - Two interpretations of the rise of authoritarian regimes
Re: on Tuesday December 17, 2024 @08:41PM (#42447356)
If you find this interesting, you may also like my blog: https://sbaziotis.com/#blog
Re:Common Misconceptions about Compilers on Wednesday December 11, 2024 @06:04AM (#42386674)
This is such an underrated comment haha
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @01:49PM (#42380008)
Hey folks, author here. I'm really happy the article has gotten such attention. I hope it's good attention and that you folks learned something! Unfortunately, though, it's _very_ hard to keep track of all the comments in HackerNews. So, if you have a comment you'd like me to reply to and I haven't, please either use the Reddit post: https://www.reddit.com/r/Compilers/comments/1hapetl/common_m...

or head over to my website: https://sbaziotis.com/ for more contact info.

Best, Stefanos

Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @01:45PM (#42379944)
Sure, but the article doesn't define optimal substructure, nor does it give a general statement about it. It just talks about a specific implication that _would be_ true if code size had optimal substructure as I thought (but based on my comment above, it seems I proved myself wrong).
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @05:25AM (#42375507)
Indeed, I'm a 4-th year CS PhD at UIUC. Yes, the environment is great and it's surprising how non-antagonistic it is for a top school. About the social environment, that's exactly how you put it: let's not talk about it haha.
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @04:37AM (#42375273)
Nice to hear that! I hope nothing else is questionable. And thanks for pointing it out! I guess the moral of the story is don't do "proofs" in your head after 3am.
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @04:20AM (#42375191)
Ok, I see a nice discussion going here. I may have disproved myself here and save ourselves some effort. First, just to be sure what we're talking about: If split the function in two and compile the two parts to minimum sizes, combining them gives you the global minimum. So, we're not starting from assembly programs.

Now, you can compile a loop to a single instruction: https://godbolt.org/z/6E38dx8jr

And, if you split the loop and compile parts of it, you will most certainly not get this single instruction. So, I'm sorry! It seems I have proved myself wrong. I'll try to find some time to revisit this. I hope this helps!

Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @03:40AM (#42375001)
TIL that LLVM_OPTIMIZED_TABLEGEN exists, thanks! Unfortunately, it didn't make the build any faster on my machine.
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @03:02AM (#42374829)
Oh, that's cool! I think these are the folks that made the Specializing Adaptive Interpreter which does type specialization at runtime. If these folks have any thoughts on ahead-of-time type inference and/or Codon, please let us know! :)
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @02:49AM (#42374765)
I don't know that much about ThinLTO but ThinLTO just works on summaries instead of the full code right? It still seems the linker is the one who reads these summaries (doc: https://clang.llvm.org/docs/ThinLTO.html).
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @02:42AM (#42374718)
For the first question, check this: https://youtu.be/pVhcyKf3efM?t=447 at 7:27. I don't know any details about Porforr but you may want to look into that.
Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @02:40AM (#42374707)
> Recently someone proposed this on LLVM

Well, to be honest, it's not any extraordinary idea and it's not even mine. Mike Acton used this exact example in his CppCon video (https://youtu.be/rX0ItVEVjHc?t=1558 at 25:58). I just happened to know that LLVM's DenseMap has this problem.

On the other comment, data locality is a property (well... it's not really a binary thing (i.e, an execution has it or it doesn't), but really a spectrum; but ok, it will do) of a program. For example, a simple definition which I like is in the paper "Improving Data Locality with Loop Transformations (https://dl.acm.org/doi/pdf/10.1145/233561.233564):

> Data locality is the property that references to the same memory location or adjacent locations are reused within a short period of time.

Changing the the layout is just a transformation to achieve this property. So, the two things are different in the sense that one is a property while the other is a transformation, but they're not different in the sense that data layout transformations are not relevant to data locality.

Regarding cache locality, that is also a property that we could define let's based on this (https://doi.org/10.1109/12.752657) say as: "The property that data brought into cache should be reused as much as possible before it is replaced". Data locality depends on the hardware on which the program is executed. Since we use caches in our hardware, to have data locality you usually need to need have cache locality so these two coincide.

Finally, yes you're absolutely right (well, last time I checked...). LLVM has a bunch of loop transformations implemented---some relevant to data locality---but they're not turned on by default. One reason for that is that LLVM loops are too unstructured while these transformations usually need nice for-loop nests. They're unstructured on the one hand because they're coming e.g., from C, and OTOH because LLVM doesn't have a loop structure, something Chris Lattner has said he regretted.

Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @01:55AM (#42374466)
Yes, but... First, it is what it is. Second, it's not that C++ people made bad decisions in the 80s but the decisions were great afterwards. Let's take C++ metaprogramming in general, which templates are part of. Let's take if constexpr (or static if) as an example, which C++ took straight from Dlang. It is useful for introspection which is almost indispensable for metaprogramming.

Walter Bright and Andrei Alexandrescu introduced static if in Dlang early and around 2012, they co-authored a static if proposal for C++ (https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2012/n33...). Bjarne Stroustrup, in his infinite wisdom, co-authored a rebuttal that rejected it, only to realize long overdue that it's an incredibly useful feature and introduce it in C++17.

Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @01:47AM (#42374432)
Well, the truth is there's a lot more to JITing than what I wrote in the article, just because JITing didn't fit the vibe of the rest of the article that well.

Anyway, yes theoretically you can. Recently folks creating Codon (https://github.com/exaloop/codon) did it for Python using a cool form of type inference.

That said, I don't think any mainstream JS VMs do it. Most recent work I know in AOT compilation for JS seems to use some profile-guided optimization and not static type inference. For example, look at the architecture at 6:38 and also discussion about types here: https://youtu.be/pVhcyKf3efM?t=469). Something similar seems to be true for the project described here: https://www.youtube.com/watch?v=_T3s6-C38JI

The story seems to be a bit different for hopc: https://www.youtube.com/watch?v=iY1EXHQ6IeQ The video starts by giving good examples of why it is very hard to have good type inference for JS (which agrees with my intuition) but continues to talk about using type inference. However, the benchmark in this talk and in their paper are not super convincing.

All that said, JS is not my expertise so I would be interested to know more about what mainstream VMs do in practice and any latest research.

Re:Common Misconceptions about Compilers on Tuesday December 10, 2024 @01:17AM (#42374275)
Thanks, I fixed it!
Thanks a lot for sharing!
Re:Inverting the Inverted: Revisiting Dismissed Ideas in Research on Wednesday November 15, 2023 @03:34PM (#38282057)
Revisiting past ideas in research can create opportunities for progress, but also lead to controversies. In this article, I use the the Bit-Flip method, a pretty simple, yet effective method for approaching research projects, as a framework for analyzing some interesting shifts in assumptions in research works. In particular, I focus on shifts that brought back dismissed ideas.

Older »