Dynamic analysis of multithreaded embedded software to expose atomicity violations