Characterisation of an associative memory chip for high-energy physics experiments