1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-02-01 05:01:59 +01:00

Make sure lli compiles all code before invalidating instruction caches.

Patch from Amara Emerson.

llvm-svn: 164296
This commit is contained in:
Tim Northover 2012-09-20 08:46:30 +00:00
parent 2eb5a713a8
commit 9fef9e74d5

View File

@ -656,6 +656,9 @@ int main(int argc, char **argv, char * const *envp) {
Target.stop();
} else {
// Trigger compilation separately so code regions that need to be
// invalidated will be known.
(void)EE->getPointerToFunction(EntryFn);
// Clear instruction cache before code will be executed.
if (JMM)
static_cast<LLIMCJITMemoryManager*>(JMM)->invalidateInstructionCache();