John Regehr
2009-Dec-14 20:23 UTC
[LLVMdev] detailed comparison of generated code size for LLVM and other compilers
>> There are probably other differing defaults besides frame pointers. Stack >> protectors, perhaps. > > Yes, that's another good example,Ok-- I assume I should just add '-fno-stack-protector' to the llvm-gcc and clang command lines? I had totally missed that something like this was turned on by default. I'll re-run everything with this change, with frame pointers omitted, and dropping testcases that contain uses of uninititalized locals and post here again when that's done. Thanks for the feedback, John
Chris Lattner
2009-Dec-14 20:37 UTC
[LLVMdev] detailed comparison of generated code size for LLVM and other compilers
On Dec 14, 2009, at 12:23 PM, John Regehr wrote:>>> There are probably other differing defaults besides frame >>> pointers. Stack >>> protectors, perhaps. >> >> Yes, that's another good example, > > Ok-- I assume I should just add '-fno-stack-protector' to the llvm- > gcc and > clang command lines? I had totally missed that something like this > was > turned on by default. > > I'll re-run everything with this change, with frame pointers > omitted, and > dropping testcases that contain uses of uninititalized locals and post > here again when that's done.Sounds great, thanks John! -Chris
Dale Johannesen
2009-Dec-14 21:27 UTC
[LLVMdev] detailed comparison of generated code size for LLVM and other compilers
On Dec 14, 2009, at 12:23 PMPST, John Regehr wrote:>>> There are probably other differing defaults besides frame >>> pointers. Stack >>> protectors, perhaps. >> >> Yes, that's another good example, > > Ok-- I assume I should just add '-fno-stack-protector' to the llvm- > gcc and > clang command lines? I had totally missed that something like this > was > turned on by default.Yes.> I'll re-run everything with this change, with frame pointers > omitted, and > dropping testcases that contain uses of uninititalized locals and post > here again when that's done.You'll probably need to some digging to make sure the defaults are exactly comparable. Are SSE and/or MMX used? This affects floating point codegen quite a bit. Are the target CPUs the same? I think some useful information is going to come out of this, but there's some cruft to clear out first.
John Regehr
2009-Dec-14 21:49 UTC
[LLVMdev] detailed comparison of generated code size for LLVM and other compilers
> You'll probably need to some digging to make sure the defaults are exactly > comparable. Are SSE and/or MMX used? This affects floating point codegen > quite a bit. Are the target CPUs the same?Good point. Would "generic i686" be a reasonable choice? Does that even mean anything these days? Anyway-- I'd appreciate some guidance on what you folks would find most interesting and useful. Then I can do some homework and figure out how to get the rest of the compilers to assume an equivalent ISA. Thanks, John
Anton Korobeynikov
2009-Dec-14 21:54 UTC
[LLVMdev] detailed comparison of generated code size for LLVM and other compilers
> You'll probably need to some digging to make sure the defaults are > exactly comparable. Are SSE and/or MMX used? This affects floating > point codegen quite a bit. Are the target CPUs the same?I saw in some tests the difference of the size was caused by different defaults for FP codegen - x87 math or sse2. -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
Seemingly Similar Threads
- [LLVMdev] detailed comparison of generated code size for LLVM and other compilers
- [LLVMdev] detailed comparison of generated code size for LLVM and other compilers
- [LLVMdev] detailed comparison of generated code size for LLVM and other compilers
- [LLVMdev] detailed comparison of generated code size for LLVM and other compilers
- [LLVMdev] detailed comparison of generated code size for LLVM and other compilers