[PATCH] D24426: DebugInfo: Pass non-zero alignment to DIBuilder only if aligment was forced

Victor Leschuk via cfe-commits cfe-commits at lists.llvm.org
Sun Oct 2 18:30:26 PDT 2016


vleschuk marked 3 inline comments as done.
vleschuk added inline comments.


> vleschuk wrote in CGDebugInfo.cpp:608
> Will check if this works in all cases. I think it's worth putting this snippet into helper function within anon namespace.

That is correct for types, for particular decls we still need to use hasAttr<>. Moved both cases into separate functions.

> dblaikie wrote in CGDebugInfo.cpp:609
> Maybe add a comment here about why we're specifying zero alignment (or possibly change the API to not take an alignment at all so we don't have to explain it?)
> 
> (similarly for other cases where the alignment is just hardcoded to zero)

Default arguments now are zeros.

https://reviews.llvm.org/D24426





More information about the cfe-commits mailing list