http://selftiming.ru/new/2013/10/23/poluzakaznaya-biblioteka-samosinhronnyh-elementov-dlya-otvetstvennyh-primenenij/