Of course it is fast - Google&co already knows everything about you
Seriously, though, your login name is stored somewhere in a database and indexed. Due to the index, getting a row corresponding to your name is very fast, it involves just a few IO operations. Speed of an index access it is practically independent of the size of the table. Then your password hash is read (one or two IOs again), your password is salted, hashed and compared to a hash from a database. I'd say that the cryptographic hashing is the most expensive operation there, but given today's CPU speeds, it appears instantaneous.