Quantcast
Channel: Software and devellopement – Deadalnix's den
Browsing all 15 articles
Browse latest View live

Interfacing D with C++ : start new thread

Interfacing D with C++ is sometime tricky. In this scenario, I will show how to start a thread from C++ that execute C++ code, but in a valid D environment, so that C++ code can interact with D code...

View Article



The PHP is an HTML element, not a PHP one.

On many Internet websites, you’ll come across article explaining you HTML and PHP. But none of them teach you that the PHP tag should be considered as an HTML element, not as a PHP one. Worse, many...

View Article

The hashtable closure pattern

I noticed that I was using a pattern of my own more and more. It is actually very usefull, for several reasons. It may have been used by other before me, but never saw a name for it. This pattern is...

View Article

A review of D2 – constness and immutablility

The D programming language is a very promising language. I propose here to do a quick review of some problems it is facing (or at least problems I’m facing when using it) and propose some solutions....

View Article

Image may be NSFW.
Clik here to view.

Impact of 64bits vs 32bits when using non precise GC.

As ARM release its intention to go 64bits, we can be pretty much sure that almost every device will be 64bits soon, except the one on which it is unrealistic to run a garbage collector. A garbage...

View Article


How duplication insidiously invade our code

Duplication is probably the #1 enemy of clean code. Its presence make the code harder to maintain, harder to evolve, more bug prone, harder to test and probably eat babies every morning. If almost any...

View Article

Get an exception from a segfault on linux (x86 and x86_64), using some black...

Linux (as other UNIXes) allow you to register handlers for signals. Here we are interested in SIGSEGV. This signal is sent to your program when you try to use a memory location you shouldn’t....

View Article

Visitor pattern revisited in D

OOP is known (or should be known) as a behavioral abstraction. It nicely solves a vast variety of problems, but enforces on the programmer an abstraction that doesn’t fit every problem. The fact is,...

View Article


A story about optimization, LLVM, and the SentinelInputRange

Developers want code that runs fast and users do too. However, it is easy to fall into the trap of early optimization; this story shows that even in non-trivial cases, modern compilers can do wonders....

View Article


Type-safe tagged unions in the D programming language

A tagged union Sometime you have some data that can be of type A or B. Very common use cases include decoding various file format or network protocols, communicate with memory mapped devices, some...

View Article

Why Can’t Senior Programmers.. Program?

This post is obviously a reference to the notorious Why Can’t Programmers.. Program?. I was earlier today reading an article about unreasonable assignment for junior programmer interview. In that...

View Article

On code review

Code review has become a standard programming practice, for open source projects, but also for many companies that practice it in house. While this practice has proven to be very valuable, many...

View Article

Image may be NSFW.
Clik here to view.

SegWit is not great

Let’s talk about SegWit. While I never was a fan of SegWit, the Hong Kong agreement seemed like a reasonable enough compromise to me to go along with it. Now that Bitcoin Core decided to betray the...

View Article


Using Merklix tree to shard block validation

When scaling a system, there always comes a time when all of the processing cannot be done on one machine. This problem is solved by spreading the workload across several machines. This presents some...

View Article

Image may be NSFW.
Clik here to view.

Variable size integer encoding

It is a known fact of nature that most integers are small. When transferring data over the network, or to/from disk, or pretty much anywhere the IO is slow, keeping data compact is a plus. Obviously,...

View Article

Browsing all 15 articles
Browse latest View live




Latest Images