rjmccall added inline comments.
================
Comment at: clang/lib/CodeGen/CGBuilder.h:126
// FIXME: these "default-aligned" APIs should be removed,
// but I don't feel like fixing all the builtin code right now.
llvm::StoreInst *CreateDefaultAlignedStore(llvm::Value *Val,
----------------
Oh, please remove this comment, too, since you've now achieved it. :)
================
Comment at: clang/lib/CodeGen/CGBuiltin.cpp:2195
LoadInst *Load =
- Builder.CreateDefaultAlignedLoad(IntToPtr, /*isVolatile=*/true);
+ Builder.CreateAlignedLoad(IntTy, IntToPtr, CharUnits::fromQuantity(4));
+ Load->setVolatile(true);
----------------
pcc wrote:
> rjmccall wrote:
> > Why 4?
> __readfsdword is a Windows intrinsic which returns an unsigned long, which
> always has size/alignment 4 on Windows.
>
> But now that I think about it I suppose we can get here on other platforms
> with MS extensions enabled, so I've changed this to query the alignment.
Thanks.
https://reviews.llvm.org/D27157
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits