The trouble with tools like that is that they're pretty language specific, so it's my impression that it would require a fair bit of work to generalize to languages other than C++.
748 karma · joined November 2, 2014
The trouble with tools like that is that they're pretty language specific, so it's my impression that it would require a fair bit of work to generalize to languages other than C++.
Remote pointers end up being pretty nice for locality, since you can explicitly see what process a remote pointer is pointing to.
None of the backends that my remote pointer implementations depend on really offer fault tolerance, though. So you're right: if you're in a situation where you have nodes entering or leaving your cluster before your program ends, this model needs extending before it works for you. That's true for MPI-style programs, generally, though.
[1] https://256fd102-a-62cb3a1a-s-sites.googlegroups.com/site/mk...
But what C++ is doing (and static languages with metaprogramming in general) is specializing and statically inlining everything at compile time so the assembly just takes the fastest path every time; no runtime cost.
I'm unsure which static languages do and do not support partial specialization. My understanding is that the current iteration of Rust doesn't have partial specialization, but maybe it has other features that could do what this post is doing?
I'd be interested in hearing people's perspectives on the metaprogramming power of different statically typed languages - people have expressed interest in me building libraries like this in Rust and a few other languages.
And, sure, it's not Debian or CentOS, so you don't have as much attention focused on the packages. Their record of keeping malware out is pretty solid, though, as far as we know.
I think a lot of security has to do with simplicity: if you don't understand how your software is configured, you're likely to open up a security hole on your system.
Arch's "don't start doing stuff until the user tells you" posture does a good job of making sure the user is aware of what's running on her system. Contrast this to Debian, which will often start running random services as soon as you install a package (e.g. Apache).
I installed FreeBSD on a ThinkPad T400 back in 2016... I was royally unimpressed with all the shit I had to go through to get drivers working on what is probably the most supported laptop of all time for the open-source community.
I would shudder to think about setting up an encrypted BSD dual-boot with Mac OS on my MBP, like I do with Arch.
And I mean this not to degrade BSD; I did love the design. Just, like, I don't want to spend all my time installing drivers from source and writing custom scripts to control my backlight and CPU fan.
It has a similar "from scratch" policy, but all the official packages are pre-compiled. There's also the Arch User Repository, where you can find proprietary and unofficial packages, many of which will compile from source.
It also has by far the best documentation of any distro.
My personal favorite is WiTeX, which makes Wikipedia look like a LaTeX document [1].
Why is Fortran still a thing? technical debt
Everyone I know in astrophysics or engineering who can uses something else--Python, C++, and Julia, are big winners.
The problem is that there are these huge monolithic codebases written in Fortran that are difficult to get out of using. People end up using Fortran because they need a hydrodynamics code, or a navier stokes solver, or a chemical kinetics code, but they can't justify building one from scratch--that's not how you get a Ph.D., and Ph.D. students and post docs are the people doing the brunt of this work.
There's also the added disincentive that even if you do re-implement a solver in a modern, maintainable way, then your results might disagree with previous published work--not necessarily because your results are wrong, but because the published work probably has bugs that no one has been able to discover or reason about because the code is so complex.
So `T& operator[](index_t)`, where `index_t` could just be a tuple.
a[{1, 2}] = 12;
This has virtually the same syntax, will be compiled in the same way by any modern compiler, and lets you create special index types that have invariants (suppose you want i0 < i1).Whether or not that's desirable depends on what kind of programs you're writing. For programs like databases that traditionally store things using the filesystem, that's probably a very useful abstraction, and some people at VMware have actually implemented an "RDMA over the filesystem" abstraction, which is super cool: https://256fd102-a-62cb3a1a-s-sites.googlegroups.com/site/mk....
If you're looking for an abstraction with which to directly implement programs that use data structures, however, I still think pointers are much more valuable than files because files are not strongly typed, and it's easy to read junk due to type errors and lack of structure.
There are some fundamental syntax limitations due to the way that operator-> works (and that operator. does not exist).
The best thing I have is a `pointerto()` macro that gets you a remote pointer to a member of a remotely stored object. This uses C++'s `offsetof` macro and a whole bunch of template voodoo to make the types work.
struct coord_t {
float x;
float y;
};
remote_ptr<coord_t> p = getRemoteCoord();
remote_ptr<float> p_x = pointerto(x, p);
float x = rget(p_x);
rput(p_x, x+1);
You can make operator-> work as well, for both methods and members, but unfortunately right now it has to involve pulling the whole object, storing it inside a proxy object, accessing the member of the local object, and then storing it back in remote memory in the proxy object's destructor. It's a cool piece of code (I'm open-sourcing this library as soon as I have a free weekend to clean it up and document it).I hope that metaclasses or reflection in a future version of C++ will allow the syntax you wrote above, but right now this is the only way I've come up with.
Also, stream communication is explicitly two-sided; if you want to pull in a value on an istream, there needs to be a corresponding process on the other side inserting something into an ostream. I've found pointers to be a much better abstraction for data structures, which often require irregular access that two-sided communication can't satisfy easily.
Streams also have the problem that, while the underlying interface (a socket, file, etc.) is untyped, the interface is typed. This leads to the unfortunate situation where you can attempt to pull an std::string in on an istream and get junk because you're using the wrong type.
This does depend a lot on the kinds of programs you're writing and what your assumptions are--in the HPC world, we don't generally care about fault tolerance, and we actually have hardware that gives us fast RDMA read/write. In a distributed systems setting where processes are communicating with messages and need to be fault tolerant and reach consensus using algorithms like Paxos or something, I could see abstractions like streams being really useful.
As for Google, companies in general value employees who are flexible in the projects they're willing to work on. Without efforts to counteract bias, employees who decline projects due to ethical objections risk being seen as difficult.
It's remarkable to me that the "feelings of 1.3 billion people" are so fragile that they're unable to enjoy their coffee cake if the company that made it doesn't kowtow to Beijing.
You don't have to look far to see how bad things have gotten recently in China, from abductions of booksellers in Hong Kong to an activist being carted away literally during a phone interview with Voice of America.
When Western companies act like this is totally normal and even develop censorship technologies for regimes in countries with poor records for human rights, it lends false legitimacy to these unjust systems and even emboldens them to commit more serious violations of human rights.
Students in my program usually end up paying 40-60% of the base salary toward rent.
In my department, students make about $40K/year as a base salary, which is not a lot, but enough to get by with. Add a summer internship to this, and your income is not too shabby--I made about $70K this year.
Now, of course, I realize this is half or less of what students would be making in industry. But it's enough that quality of life is pretty decent.
But, yeah, they run as root, so they can still do damage.
My point was that the danger zone is when you trust the package, rather than when you run the PKGBUILD itself with `makepkg`. Of course `makepkg -i` runs both `makepkg` and `pacman` as root.
But, yeah, they run as root, so they could still do something nasty at install time. Not when you `makepkg` the PKGBUILD, though.
Anything proprietary can't simply be copied over and mirrored for copyright reasons.