majnemer added a comment.

In http://reviews.llvm.org/D19654#423382, @andreybokhanko wrote:

> David, thank you for the thorough review! -- it definitely made the patch 
> stronger and me even more paranoid than the rest of Intel. :-)


Thanks for implementing this :)

> 

> 

> In http://reviews.llvm.org/D19654#422445, @majnemer wrote:

> 

> > FYI, we will also want to update `getAddrOfCXXCatchHandler` and 
> > `getThrowInfo` to correctly handle `__unaligned`.

> 

> 

> Do you want me to implement this (I have no idea how EH works on Windows, but 
> can try...) or plan to implement yourself?


I have no plans to implement this but I don't think it is very difficult.  The 
way I'd go about this is to see what happens when the following occur:

  throw (int *__unaligned)nullptr;

MSVC should emit a ThrowInfo object, _TI... which points to a 
CatchableTypeArray, _CTA... which will point to two CatchableTypes, _CT...: one 
for pointer-to-void and the other for pointer-to-int.
Both of the CatchableTypes have a bitfield containing qualifiers, among other 
things.  One of these are where __unaligned should go, see `getThrowInfo` for 
more details.

> Yours,

> Andrey



Repository:
  rL LLVM

http://reviews.llvm.org/D19654



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to