|
From: | Georg-Johann Lay |
Subject: | Re: [avr-gcc-list] builtins-error.c test fails for avr |
Date: | Tue, 21 Apr 2015 15:24:32 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 |
Am 04/21/2015 um 09:17 AM schrieb Sivanupandi, Pitchumani:
Hi, Test gcc.target/avr/torture/builtins-error.c is failed in gcc-4.9 and trunk for -Os -flto options. This test expects error for compile time constant. Option flto delays the builtin expand (to link time??) and there is no error. Can this test be skipped for above option? If -ffat-lto-objects option used then avr-gcc gives the error. Regards, Pitchumani
Without fat LTO objects, the compiler just puts gimple IR into the objects, there is no asm code. Built-in functions are represented by their decls as provided by targetm.builtin_decl(). This means there is no expansion of tree to rtl. That expansion is as late as possible (in principle it could even be in some rtl pass; the assumption is that if the respective value has not been resolved to integer_cst then the same applies to later passes.
A fix could be to add a trivial main and run the program, maybe also add used attributes to the functions.
Or simply adding -ffat-lto-objects or switching from do-assemble to do-link. Johann
[Prev in Thread] | Current Thread | [Next in Thread] |