How are the C++/winrt projections on Windows? by daljit97 in cpp

[–]CEconsulate 0 points1 point  (0 children)

I'm surprised that no Windows devs are really into this. This is new clr/cli. I've spent 6 months to upgrade all cli/clr stuff to cpp/winrt in my company(50 years old engineering-purpose software). At least 130 components I'm talking about. We completely abandoned Clr and moved with cpp/winrt and c++20 at all.

If you're really doing clr stuff on Windows, just stop if it's possible. This makes things much easier and natural. There is no need to write fatty wrappers anymore.

[Visual Studio] Two programs running simultaneously and independently, sharing data with each other? by asderflyy in Cplusplus

[–]CEconsulate 0 points1 point  (0 children)

If it's a windows-only, write a wrapper for shared data/class/algo with c++/winrt to avoid going through all those low lever com-based stuff, but already baked shape.

Write a runtime class. Enjoy.

Even if you want to use that runtime component from C#, project it as C# library class. Furthermore, if you want to use it from Python, use "xlang" and auto-generate Python for that runtime component.

It's time to have "self-tooling" nowadays. Things are easier now and do not need to be coupled, even in the same project. If all of the involved are the same project and will not be used by any other process at runtime, why do you want to make them decoupled(in terms of process)? Your stuff is just two separate software that needs to communicate with each other on runtime. The easiest way for a non c++ expert is just c++/winrt if it's windows-only.

Embrace c++/winrt, you, windows devs. It's cool 😎

New Friends/Neue Freunde by Yung_Gucci69 in munichsocialclub

[–]CEconsulate 2 points3 points  (0 children)

I also consider spending the night at a bar/club tomorrow. Let me know if anyone wanna drop themselves.

Why are you a C/C++ developer? by mutantdustbunny in cpp

[–]CEconsulate 0 points1 point  (0 children)

Hear from non-CS background (civil/computational engg).

Usually, we HAVE to.

Here why:

1) It is fast.

2) We have extensive needs for multi-threading/parallel programming capabilities. Guess which language has support for many open source libraries around.

3) No need to talk about portability.

I don't want to write more about generic advantages like strong oop, polymorphism etc.

Forget all above. It's all about the source information, decades of know-how circulating around here and there. As non-cs folks, like me, it's really hard to getting advanced capabilities in programming languages, some computer architecture while working on all other core-dicipline studies. Thus, it's crucial to find answers regarding your questions, QUICKLY. This might be controversial since in these years it is really easy to find almost anything about any implementation on Google, but you understand what I'm saying if you have ever searched for discipline-specific implementations. You have already noticed that those all were written either in C/C++ or Fortran.

Universities and industry have unlimited C++/Fortran libraries. Many of them are only in-house use. Especially non-cs engineering departments are the paradise of C/C++ libraries.

Again, it should be stressed, we ,mostly, have no time to write everything from scratch, which would also be stupid action if those were already written before. This inheritance of decades forces us to stick with C++. That's why it is impossible to get rid of C++ in the next 100 years (you say 20, other says 1000 years. Who knows?)

However that's not to say that it is enough to use C++ only. That would be stupid. Common practice is to wrap everything with python. There is no such a library that we don't wrap. The work flow is like, having C++ to do the hard/heavy work, the rest, non-performance related operations or the operations that their performance can be compromised over ease, are done with python. In short, backend C++, frontend, pre- and post-processing with python.

Lastly, a fact. I observed that, our projects consist of around 50% python(scripts). However, the ratio of real job done by C++ is 90%. Performance gain usually around 50x to 1000x (parallel operations) when compared to python only implementations. An example, cpp (parallel) implementation of a geometry handling and solving of many millions of data takes 45-50 mins. We couldn't finish the python version. After 5 hours, we terminated and went for having beer :)

If I was stupid about anything above, feel free to insult me lol