My initial idea for writing this blog was to summarise various things and experiences from my life and working area, and about myself, not only programming. However because I’m not such a good and organized writer, and due to lack of time, it’s pretty outdated and poorly filled at a time.
- Linux x64 NASM Base64Encoder - In this post I present the small efficient Base64Encoder I've written in NASM assembler for Linux x64. This comes from a project I've done recently. Build instructions: nasm -f elf64 base64encode.asmld base64encode.o -o base64encode The encoder reads the data from standard input stream. For example: echo 'Hello World!' | ./base64encode or one can base encode the whole files using pipe: cat 'some filename' | ./base64encode ; File: base64encode.asm SECTION .data ; Section containing initialised data Base64Table: db "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/" padding: db "=" SECTION .bss ; Section containing uninitialized data BUF_LEN_IN EQU 3 ; Input buffer length - so many chars we… …
C++ – How to Parse Command Line Arguments - In this tip I want to show a quick way (one of many) for parsing command line arguments using C++17. A quick way of parsing command line arguments in modern C++-17 for non-production without using third party header files / libraries. For real world projects, a third party approach is more encouraged. Background Very often, by learning new libraries or creating small playground apps (for example, which fit in a single file or a couple of files), I need to parse command line arguments, but don't want mental/time overhead of importing whole libraries (like boost) or lookup third party header files… …
Continue reading "C++ – How to Parse Command Line Arguments"
C++ Character Encoding Explained - (Edited on 20.09.2020) In this post I'll try to clarify some dark corners of character encoding process in C++, going out from the source file, over compilation to the final output. After many years dealing with C++ I still have an impression that this topic is making difficulties, especially to the new C++ programmers (at least regarding to the same stack-overflow questions popping out over and over again). I will not talk about choosing the string encoding for your project or about string manipulation functions. That's the topic for an other post. What I will talk about is, how compilers… …
Installing Android x86 on VirtualBox - In this post I will show how to install the Android OS on VirtualBox. I'm normally using this during my Android Development to cut up my development time. I find deployment to the VirtualBox machine to be faster than deploying to the Emulated Android Devices, which come with Android SDK. I'm using the emulated android devices normaly in the second phase of my development, to test the application on different devices more realisticly. And of course I also test on the physical device, but I'm normally limited here. Android x86 is an open source project for porting the Android OS… …
Memory Alignment & Padding - What is meant with "memory alignment" ? The CPU (memory controller) access the memory by a single word in time. The next examples are the simplified illustration of the background problem: Say for example that the data fits and is aligned within the single word, like in the following image: In this case the data can be fetched by single read operation. In the next example the data is still 1 Word in size but its offset is not properly aligned with the word boundaries: Now, to fetch the data 2 Words and an extra computation has to be done… …
CMake – Make it Simple – Part I - About CMake Visual Studio Project without CMake Makefile project without CMake Using CMake About CMake This is the first part of the cmake tutorial. It is aimed to the absolute beginners and tries to explain the cmake principle in simple terms. I assume that you already now how to write programs. I also assume that you know at least one compile programming language (and yeah ... I mean C or C++ ). So what is cmake really for? Well, if you learned C or C++ (and I hope you did) than you have pretty sure started with the famous "Hello… …
C++ Lambda’s – simply explained - The C++-11 brought lambda expressions, which are a convient way of defining clojures. Before C++-11 a typical way to pass function-like objects to algorithms was to define a class/struct with operator()(...). For example for sorting vector of pairs of 2 integers by the value of the second element would in C++98 look something like: #include <algorithm> #include <iostream> #include <utility> #include <vector> // compare pair of ints by the value of the second element // in C++98 explicit definition of class/struct or function // needed struct value_less { // ... maybe some other parameters, if needed bool operator()(const std::pair<int,int>& p1,… …
Numerische Untersuchung des Brennverhaltens einer abgehobenen Flamme unter erhöhtem Druck (German)
Studie zur Dosierung und Verdampfung in einer Hydroprocessing – Reaktionsanlage