Merge "Fix profile guided compilation for secondaries and add more tests"