This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re:Re: A problem with LRA


It does not work when -fno-strict-aliasing is specified.
At 2017-04-18 21:02:45, "Segher Boessenkool" <segher@kernel.crashing.org> wrote:
>Hi,
>
>On Mon, Apr 17, 2017 at 09:11:56PM +0800, comp wrote:
>>         float b;
>>         *(int*)&b=a;
>
>This is undefined behaviour.  Try with -fno-strict-aliasing, does it
>then work as you expect?
>
>
>Segher

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]