Message ID | 1558693533-13465-1-git-send-email-Dave.Martin@arm.com (mailing list archive) |
---|---|
Headers | show |
Series | arm64: ARMv8.5-A: Branch Target Identification support | expand |
On 5/24/19 5:25 AM, Dave Martin wrote: > Various things need nailing down before this can be upstreamable: > > * Not tested with hugepages yet. (If anyone has any suggestions about > how best to do that, please shout!) The qemu code_gen_buffer is generally between 32MB and 2GB, contiguous. It usually gets AnonHugePage'd. I assume there's no difference in where the hugepages come from on your side? It won't be too difficult to modify qemu to make it's own code generation BTI-safe, and is on the schedule to do eventually anyway. r~
On Wed, Jun 05, 2019 at 04:12:03PM -0500, Richard Henderson wrote: > On 5/24/19 5:25 AM, Dave Martin wrote: > > Various things need nailing down before this can be upstreamable: > > > > * Not tested with hugepages yet. (If anyone has any suggestions about > > how best to do that, please shout!) > > The qemu code_gen_buffer is generally between 32MB and 2GB, contiguous. It > usually gets AnonHugePage'd. I assume there's no difference in where the > hugepages come from on your side? There are some internal differences between hugetlbfs and anonymous huge pages, but I'm not very familiar with the details. > It won't be too difficult to modify qemu to make it's own code generation > BTI-safe, and is on the schedule to do eventually anyway. For userspace, it really shouldn't make a difference where the pages come from. With hugetlbfs, probably mprotect() only works at huge page granularity; for anonymous huge pages, mprotect() should work at page granularity, with the kernel shattering huge pages as required. I guess I can come up with a handcrafted test or two. Cheers ---Dave