[llvm-commits] [PATCH] MCJIT unit test bugs

Kaylor, Andrew andrew.kaylor at intel.com
Wed Oct 31 10:16:44 PDT 2012


Why is the explicit invalidating of the code cache necessary?  Is that something that the memory manager could do automatically at some point?  I know there are some attempts to do this in the allocation process, but I guess it's not happening at the right time?

For the purpose of setting page protection, we're going to be adding some sort of function to "finalize" the loading process.  Perhaps the code cache invalidation could happen there.

-Andy

-----Original Message-----
From: llvm-commits-bounces at cs.uiuc.edu [mailto:llvm-commits-bounces at cs.uiuc.edu] On Behalf Of Amara Emerson
Sent: Wednesday, October 31, 2012 8:12 AM
To: llvm-commits at cs.uiuc.edu
Subject: [llvm-commits] [PATCH] MCJIT unit test bugs

Hi,

We've discovered 2 problems in the MCJIT unit tests which have already been fixed in lli.

The first is the cache invalidation bug, which can easily be fixed by adding calls to invalidateInstructionCache() before executing each test function.
The second is the buggy memory alignment handling by allocateDataSection() in the SectionMemoryManager. The fix from r166920 has been ported to the unit test.

Review and commit appreciated.

Amara




More information about the llvm-commits mailing list