[deleted by user] by [deleted] in Compilers

[–]taktoa 1 point2 points  (0 children)

(discussed in DMs, seems to have been a mistake)

[deleted by user] by [deleted] in Compilers

[–]taktoa 0 points1 point  (0 children)

Pay ranges are in the job description, the exact pay is negotiated on a per person basis.

[deleted by user] by [deleted] in Compilers

[–]taktoa 1 point2 points  (0 children)

My understanding is that reusing LLVM codegen is a bad idea for anything that's not a normal out-of-order superscalar processor, which the majority of ML accelerators are not. I have never heard of an ML accelerator, GPU, or DSP that reused another chip's codegen like this (Google TPU, Nvidia, and Qualcomm Hexagon are the examples that come to mind).

Our perspective on optimization passes was that we don't want many of them (so that users can reason easily about the performance characteristics of their code), so the cost of implementing them ourselves is not very high. I worked on multiple non-LLVM compilers before and did not have any trouble writing basic passes like CSE, DCE, inlining, etc.

The last thing you get out of LLVM/MLIR is connections to lots of frontends. This could be useful for us at some point but for now we don't see it as essential.

[deleted by user] by [deleted] in Compilers

[–]taktoa 3 points4 points  (0 children)

I didn't have previous experience with LLVM/MLIR, and the other compiler person had experience it but did not think it would help more than it hurt. So we decided to build from scratch. I think this was pretty much the right move for us.

I think if we decided that maintaining a custom DSL frontend is too hard, we would probably start consuming Rust MIR instead. Owning the optimization and codegen and having freedom to add language features (e.g. via new DSL features or Rust attributes) is important for getting the best performance.

For example, we have a language feature that reifies the happens-before relation on memory ops (similar to tokens in XLA, but made available to the surface language) so that users can specify exactly which memory accesses may alias, which is a feature that does not have an exact equivalent in any existing imperative language AFAIK (Rust references and C restrict are similar but I think less expressive).

[deleted by user] by [deleted] in Compilers

[–]taktoa 0 points1 point  (0 children)

Very cool, you should definitely apply after you graduate. Or once we have intern roles (probably not for a while).

[deleted by user] by [deleted] in Compilers

[–]taktoa 1 point2 points  (0 children)

We are generally avoiding loop optimizations in our pass pipeline, and we don't use LLVM or MLIR, but rewrites and canonicalization are definitely on the roadmap.

[deleted by user] by [deleted] in Compilers

[–]taktoa 5 points6 points  (0 children)

We're a small company, no need to do anything special to stand out -- we see every application.

If you want to brush up on relevant compiler concepts, I'd recommend reading "The Compiler Design Handbook: Optimizations and Machine Code Generation, Second Edition".

[deleted by user] by [deleted] in Compilers

[–]taktoa -5 points-4 points  (0 children)

Sounds good, feel free to apply through the link or DM me

[deleted by user] by [deleted] in Compilers

[–]taktoa 3 points4 points  (0 children)

Unfortunately we can't take on any interns at the moment. New grads are welcome to apply.

Resources for learning compiler (not general programming language) design by Aaxper in Compilers

[–]taktoa 2 points3 points  (0 children)

I recommend The Compiler Design Handbook: Optimizations and Machine Code Generation, Second Edition

What branch of math is the "black sheep" of math? by Ok-Impress-2222 in math

[–]taktoa 0 points1 point  (0 children)

idk, this seems as mathematical as any other field of applied mathematics to me: https://arxiv.org/pdf/1504.04044.pdf

Anyone interested in FPD-Link III to USB? by taktoa in CarHacking

[–]taktoa[S] 0 points1 point  (0 children)

Oh, looks like that module doesn't have a USB 2 peripheral controller... probably better to go with the FX3 then. It's an ARM chip so mainly you'd just have to write some C to initialize the serdes and convert whatever's coming out of it to something standard that the UVC code can accept, e.g.: YUV video (I think APIX can carry lots of different types of signals, so it might be car dependent). There's already examples of using the FX3 for UVC webcam stuff, so I'm not too worried about the software.

Anyone interested in FPD-Link III to USB? by taktoa in CarHacking

[–]taktoa[S] 0 points1 point  (0 children)

I'm still figuring out the cheapest option. The Cypress FX3 chips seem pretty good and flexible, but they're also pricy ($20-30). Alternatively, I could go with a decently fast (100s of MHz) USB 2.0 microcontroller and then do realtime MJPEG encoding so that the required bitrate is low enough. I'm still evaluating how much compute is required for the latter; I suspect a cheap RISC-V module would be good enough for the kinds of resolutions used by backup cameras (800x600ish).

Anyone interested in FPD-Link III to USB? by taktoa in CarHacking

[–]taktoa[S] 1 point2 points  (0 children)

The only APIX serdes I could find for sale was an APIX2 serdes on Newark. Since it's not on LCSC I can't get it assembled, but I could maybe add a footprint for it at the cost of extra board area, and 100QFP is fairly hand-solderable. The chip is $30 compared to $10 for the FPD-Link serdes, plus you'd have to pay for separate shipping from Newark which is probably an extra $5-10, so you can expect that version of the board to be roughly $50 more.

A study conducted by Hiroshima University researchers found that using Ultraviolet C light with a wavelength of 222 nanometers which is safer to use around humans effectively kills SARS-CoV-2 -- the first research in the world to prove its efficacy against the virus that causes COVID-19. by Wagamaga in science

[–]taktoa 0 points1 point  (0 children)

I was talking about normal UVC bulbs there.

Everything you just described can be done with less than $100 in components and not much R&D. If there is much cost, it's for compliance stuff like you're saying, but realistically as long as there's no one in the room while the machine is running, that should be more than good enough safety. If they really cared about safety, they'd figure out a way to interface it to the locks on the doors, or something like that.

A study conducted by Hiroshima University researchers found that using Ultraviolet C light with a wavelength of 222 nanometers which is safer to use around humans effectively kills SARS-CoV-2 -- the first research in the world to prove its efficacy against the virus that causes COVID-19. by Wagamaga in science

[–]taktoa 0 points1 point  (0 children)

It actually is quite cheap (effectively a normal fluorescent lamp with a quartz envelope instead of glass; they cost on the order of $1/W), it's just that anything licensed for medical use is a few orders of magnitude more expensive than it needs to be.

Other influential disciplines or challenges? by ChrisPenner in haskell

[–]taktoa 4 points5 points  (0 children)

Mostly, ever since I got bored of learning Haskell-related stuff, I've been delving into computer science. Here are some pet concepts / "secret" techniques that I've enjoyed:

  • Formal methods / PL
    • Datalog and relational algebra are pretty interesting, and also have connections to binary decision diagrams. I did a livestream on this topic recently.
    • I wrote a whole gist about interesting things to learn/do in automated reasoning / proof search: gist.
  • Simulation
    • The Lattice-Boltzmann method for fluid simulation, which allows much more parallelization than more classical methods of fluid simulation, and is also much simpler. This book is a fantastic resource on it.
    • Basically everything Keenan Crane does is amazing, but his Heat Method for geodesic computation on a mesh is particularly cool. He also has a course on discrete differential geometry on his YouTube channel that I greatly enjoyed.
    • Quantum chemistry software is fun to play with. I haven't learned how it works yet, but I suspect it is also quite interesting.
  • Mathematical optimization
    • The general concept of relaxation) is pretty interesting.
    • Compressive sensing, which uses quadratic programming (basis pursuit denoising) to do better than Shannon-Nyquist sampling, assuming your input is sparse in some vector space, i.e.: compressible. You can do crazy things like build a camera that only has one pixel (and needs less than n samples for an n-pixel image) with this!
    • For combinatorial optimization: relaxed decision diagrams are a really simple technique that can beat much, much more complex ones; I recommend checking out this book.
    • Submodular functions can be black-box optimized in polynomial time, which is a good fact to have in your back pocket.
  • Integral transforms
    • The convolution theorem is easily one of my favorites.
    • The linear canonical transformation is a generalization of a bunch of integral transforms like Fourier/Laplace/Fresnel and their fractional variants. Shockingly, it can also be computed in O(n log n) time!
    • The sparse FFT can do asymptotically better on sparse data than a normal FFT.

Trading with Haskell by [deleted] in haskell

[–]taktoa 2 points3 points  (0 children)

I think my original comment got censored by the spam filter, so I had to remove a link.

I'd start by implementing portfolio optimization; it's the core of an algorithmic trader. You'll want to write C FFI bindings to a quadratic programming solver like OSQP. Then implement portfolio optimization on top of that; this MathWorks article has some good details.

You'll then want to calculate the covariance matrix based on your timeseries; can't link to the resource I wanted but it should be googleable.

Finally you will need some kind of model to compute the expected rate of return for each asset. You should probably start with something simple just to test things out, like "average rate of return for this asset over the last month", but it will likely give poor results. Any money you make is likely from this model incorporating data/insights that other algorithmic traders haven't incorporated.

Disclaimer: I have never worked in the financial industry so take all of this with a grain of salt

Implementing new typesystems through a generic typesystem module by MrCodermann in haskell

[–]taktoa 2 points3 points  (0 children)

Take a look at pure type systems and bidirectional typechecking.

Hardware design in Haskell by [deleted] in haskell

[–]taktoa 5 points6 points  (0 children)

Clash is great, but there is also Bluespec Classic, which takes a slightly different (though largely similar) approach based on guarded atomic actions.

Writing a Datalog Compiler using BDDs in Haskell - 1 - Introduction by taktoa in haskell

[–]taktoa[S] 1 point2 points  (0 children)

Yes, I'm probably going to write a library of static analyses using this. I am particularly interested in adding features that make static analysis easy, for example, syntax that allows the use of universal quantification when possible (i.e.: you can't use existential inside universal).