1. A method for detecting a data race, comprising: detecting a first access to an object; determining whether the first access is associated with a suspicious pattern; and refining a pattern detection granularity from the object to a memory location within the object if it is determined that the first access is associated with the suspicious pattern.