This is for a team at Nvidia that is turning an open-source search engine into a GPU implementation. I personally have no hardware or GPU experience at all. They replied the day after I applied and said they wanted a phone screen, and I found out early on, after looking into the background of the interviewer, that the interviewer was a hardware engineer. I assumed they cared about my search engine background, so I prepared a pile of GPU and parallel SQL material, and none of it was asked. The question was to count the distinct strings in an array, no libraries allowed, and then give a parallel-safe solution. For the sequential version I just used a hash table, very simple and smooth. For the parallel version I made the value atomic and added a shared/exclusive lock: on a hit I just do atomic++, and on a miss I take the exclusive lock and allocate. Honestly my thinking was drifting a bit, and deep down I knew it probably wasn't the optimal solution, because GPUs all use open addressing, which gives the best parallel performance. But it was already written that way, so I had to push through. Looking back, I should have switched to an open-addressing hash map instead of carrying over the array plus linked list approach from the sequential version, but the sequential one was just too smooth to write. I don't know whether the interviewer was satisfied. They then asked a few more things, like how to split 1M keys across multiple threads, which is basically the GPU memory problem where accesses need to be adjacent. CPUs have that too. It was the only thing I had actually prepared for.
NVIDIA Software Engineer Interview Experience — GPU Search Engine Team Phone Screen on Counting Distinct Strings
Technical Screenmedium
Published
Curated and edited by PracHub
Discussion
Loading comments…