[LLVMdev] llc c backend can produce code that doesn't compile on gcc 4.x
Gordon Henriksen
gordonhenriksen at mac.com
Mon Jan 15 23:48:47 PST 2007
On 2007-01-16, at 02:47, Chris Lattner wrote:
> On Tue, 16 Jan 2007, Gordon Henriksen wrote:
>
>> The simplest solution is to avoid typedefs for array types. With
>> names of array types removed from the symbol table, llc will
>> simply output (for instance) 'l_structtype_s[3]' instead of the
>> equivalent 'l_fixarray_array3'.
>
> Very nice catch and approach.
Thanks!
>> A more ambitious fix would be to merge the "typedef" and
>> "structure contents" loops into a single, substantially more
>> complex dependency-ordered traversal. This would preserve type
>> names from the bytecode file—but to what end?
>
> Good question, I can't think of a reason! I applied your patch but
> generalized it slightly. The CBE now strips off any non-struct
> type names, to avoid issues with vectors (if the CBE starts
> supporting them in the future).
Excellent. I was going to suggest just that generalization, but
didn't feel comfortable enough with the Type hierarchy to be sure it
was safe.
— Gordon
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20070116/cde05e9d/attachment.html>
More information about the llvm-dev
mailing list