Skip to content

Instantly share code, notes, and snippets.

View griwes's full-sized avatar

Michał Dominiak griwes

View GitHub Profile
Sfinks
sł. i muz. Adam Leszkiewicz
Obudź się, mówi ona a
Pójdźmy nad przepaścią FG a
Bo coś wisi w powietrzu a(bar) G(bar) (C)
I nie można zasnąć... CG
Ale popatrz, on mówi

We don't really have docs at this point in time, just getting the lib out of the door was quite the chunk of work; but all the things we expose follow the ISO C++ standard, and its standard library, and cppreference is a good source of documentation for that. In CUDA 10.2, we provide the contents of <cstddef>, <cstdint>, <type_traits>, and <atomic>, except in cuda::std:: instead of std::, and in <cuda/std/cstddef> and so on instead of <cstddef>. Additionally, there's cuda::atomic<T, Scope>, which provides scoped atomics; the available scopes are cuda::thread_scope_{block,device,system}. cuda::std::atomic uses cuda::thread_scope_system, and atomics only free you of data races within the specified scope.

All the things provided work both on the host and on the device, and are layout compatible, which means that you can also use them in managed memory heterogeneously between the host and the device.

@griwes
griwes / gist:7fd0942175b50fea386babaa87800f76
Created March 30, 2019 20:02
MCU movie list, in Order of Enjoyment, a'la LRR Countdown to Infinity
1. Iron Man (2008)
@griwes
griwes / gist:9566641
Created March 15, 2014 12:43
Strzela mnie w krzyżu
sł./muz.: Jakub Kwaśniewski
kapo I
Wojna przyszła jak zawsze niespodziewanie e
W całej armii wywołując poruszenie a
Nawet sam kapelan nie wie co się stanie H7
Czy idziemy po triumf - czy na stracenie e H7
Zebraliśmy się w kapliczce przy koszarach
Karawana wraków
Słońce na niebie wisi na złocony wbite hak
Pod słońcem wszystko byle jak
Rozgrzany dach, pod dachem w mojej głosie myśli huk
Motoru brzęk i drogi stuk
Przed siebie gnać z tą karawaną wraków
Łysinę pod wytartą czapkę skryć
Nie wolno spać, choć dobrze już po zmroku
template<typename Type, typename Tag = class default_tag>
struct list_mixin
{
Type * prev = nullptr;
Type * next = nullptr;
};
template<typename CRTP, typename... Tags>
struct list_mixins : list_mixin<CRTP, Tags>...
{
"Jak się nie stoczyć"
sł. i muz. Paweł Wójcik
I znowu siedzimy Tomaszu przy stole e D
Nie sięgaj po portfel bo dziś moja kolej G D
Lubimy ten gwar, muzyczka nam gra e D
Wódeczka do dna G D
Siedzimy przy stole, coś mówisz o żonie
@griwes
griwes / cmake_hacks.md
Created June 29, 2016 12:25
stupid cmake hacks
On 03/10/2011 12:25 AM, Andreas Pakulat wrote:
> On 09.03.11 21:36:25, Ankur Handa wrote:
>> I'm using find_library to find a library in a given directory but it has
>> many different versions of this library listed as libcxcore.so,
>> libcxcore.so.2.1 and libcxcore.so.2.1.0  I wrote a very simple cmake file
>>
>> cmake_minimum_required(VERSION 2.8)
>>
@griwes
griwes / osdev.md
Last active December 23, 2015 11:06
#osdev.txt

klange: This is a horror story about what happens when you need a hammer and all you have is the skulls of the damned.

drake1: as long as the lock is read and modified by atomic operations

Kazinsal: because if you drag on a discussion about how to store secondary files for a fucking bootloader for more than ten minutes, you should be forced to use yaml as a filesystem as punishment

"Wyznanie kalifa, czyli o mocy baśni"
sł. i muz. Jacek Kaczmarski
Słowem drobnego wyjaśnienia - znak '+' przed akordem oznacza, że z akordu poprzedniego na oznaczony akord
(a więc w miejscu, gdzie znajduje się '+') znajduje się specjalne przejście między akordami, zależne rzecz
jasna od samych akordów (a też i od miejsca w tekście). Oznaczenia te bazują na wykonaniu, które znajduje
się na albumie "Dwie skały"; tam też (tj. w nagraniu) polecam poszukiwać dodatkowych informacji na temat
tychże przejść.