[cfe-dev] [llvm-dev] the as-if rule / perf vs. security

Bruce Hoult via cfe-dev cfe-dev at lists.llvm.org
Thu Mar 17 04:37:24 PDT 2016


Not if the load is aligned. Which you can easily guarantee if you're doing
"load a big thing and mask/extract", which means you're generating the load
address for the big thing by clearing the lower bits of the address that
would have been used for the small thing.


On Wed, Mar 16, 2016 at 9:31 PM, Tim Northover via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> > I'm less sure if the gaps are on the edges.  I'm worried that you might
> > ending up crossing some important address boundary if you look at
> something
> > earlier or later than what the user requested.
>
> Oh yes, you certainly can't do it on the edges in most cases. It can
> very easily cross a page boundary and segfault your process.
>
> Cheers.
>
> Tim.
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20160317/6421f81d/attachment.html>


More information about the cfe-dev mailing list