  We prove that the combinatorial Weisfeiler-Leman algorithm of dimension
$(3k+4)$ is a complete isomorphism test for the class of all graphs of rank
width at most $k$. Rank width is a graph invariant that, similarly to tree
width, measures the width of a certain style of hierarchical decomposition of
graphs; it is equivalent to clique width.
  It was known that isomorphism of graphs of rank width $k$ is decidable in
polynomial time (Grohe and Schweitzer, FOCS 2015), but the best previously
known algorithm has a running time $n^{f(k)}$ for a non-elementary function
$f$. Our result yields an isomorphism test for graphs of rank width $k$ running
in time $n^{O(k)}$. Another consequence of our result is the first polynomial
time canonisation algorithm for graphs of bounded rank width.
  Our second main result is that fixed-point logic with counting captures
polynomial time on all graph classes of bounded rank width.
