[cfe-dev] aligned 'new'

John McCall rjmccall at apple.com
Fri Sep 2 11:26:17 PDT 2011


On Sep 2, 2011, at 9:47 AM, Anton Yartsev wrote:
>> Now, the meta-level point: this is a significant extension to Clang, so it needs proper documentation, a specification, a test suite, etc., as described in
>> 
>> 	http://clang.llvm.org/get_involved.html
>> 
>> You mentioned that this is a pre-existing feature for ppu-lv2-gcc from the Sony Cell SDK, which likely means that the design of the feature is already fairly constrained. That said, we need to understand the design of the feature before we can evaluate the implementation, and I still don't have a good sense of how the feature is supposed to work. More documentation and examples would help a lot.
> added the test.
> 
> That is how the feature is designed in ppu-lv2-gcc:
> giving -fstrict-align option to ppu-lv2-gcc does the following:

This is a terrible choice of name for this command-line option.  If I had to come up with a list of ten things that "strict-align" means, I don't think "make operator new take an alignment argument" would be on it at all.  Since this feature has been implemented in precisely one previous vendor-specific frontend, I think it's worthwhile to establish a better precedent.

I would suggest something like -foperator-new-alignment.

John.



More information about the cfe-dev mailing list