public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/58849] New: complex number, memory is corrupted
@ 2013-10-22 22:05 otmar.struwe at web dot de
  2013-10-22 22:33 ` [Bug target/58849] " pinskia at gcc dot gnu.org
  2013-12-13 12:07 ` otmar.struwe at web dot de
  0 siblings, 2 replies; 3+ messages in thread
From: otmar.struwe at web dot de @ 2013-10-22 22:05 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58849

            Bug ID: 58849
           Summary: complex number, memory is corrupted
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: otmar.struwe at web dot de

Created attachment 31075
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=31075&action=edit
test source

In the below test program the value of the variable "comp" is corrupted.

Wrong output is:
    doub = -0.544021 
    doub = -0 

Expected output:
        doub = -0.544021 
        doub = -0.544021 


Compiled with:
    gcc -Wall -std=c11 -Wpedantic -o complex.exe complex.c 


Compiler:
    Using built-in specs.
    COLLECT_GCC=d:\pc\msys\1.0\mingw\bin\gcc.exe
    COLLECT_LTO_WRAPPER=d:/pc/msys/1.0/mingw/bin/../libexec/gcc/mingw32/4.8.
1/lto-wrapper.exe
    Target: mingw32
    Configured with: ../gcc-4.8.1/configure --prefix=/mingw
--host=mingw32 --build=mingw32 --without-pic --enable-shared
--enable-static --with-gnu-ld --enable-lto --enable-libssp
--disable-multilib --enable-languages=c,c++,fortran,objc,obj-c++,ada
--disable-sjlj-exceptions --with-dwarf2 --disable-win32-registry
--enable-libstdcxx-debug --enable-version-specific-runtime-libs
--with-gmp=/usr/src/pkg/gmp-5.1.2-1-mingw32-src/bld
--with-mpc=/usr/src/pkg/mpc-1.0.1-1-mingw32-src/bld --with-mpfr=
--with-system-zlib --with-gnu-as --enable-decimal-float=yes
--enable-libgomp --enable-threads --with-libiconv-prefix=/mingw32
--with-libintl-prefix=/mingw --disable-bootstrap     LDFLAGS=-s
CFLAGS=-D_USE_32BIT_TIME_T
    Thread model: win32
    gcc version 4.8.1 (GCC)


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug target/58849] complex number, memory is corrupted
  2013-10-22 22:05 [Bug c/58849] New: complex number, memory is corrupted otmar.struwe at web dot de
@ 2013-10-22 22:33 ` pinskia at gcc dot gnu.org
  2013-12-13 12:07 ` otmar.struwe at web dot de
  1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2013-10-22 22:33 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58849

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Target|                            |mingw32
          Component|c                           |target
            Version|unknown                     |4.8.1

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Works correctly under GNU/Linux.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug target/58849] complex number, memory is corrupted
  2013-10-22 22:05 [Bug c/58849] New: complex number, memory is corrupted otmar.struwe at web dot de
  2013-10-22 22:33 ` [Bug target/58849] " pinskia at gcc dot gnu.org
@ 2013-12-13 12:07 ` otmar.struwe at web dot de
  1 sibling, 0 replies; 3+ messages in thread
From: otmar.struwe at web dot de @ 2013-12-13 12:07 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58849

--- Comment #2 from otmar.struwe at web dot de ---
After updating some parts of the mingw environment (mpfr/gmp/mpc) I am not able
to reproduce the described behavior.

Now I get:

c:\temp\ccWxAggU.o:complex.c:(.text+0xef): undefined reference to `csin'
collect2.exe: error: ld returned 1 exit status

The compiler is the still the same.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-12-13 12:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-22 22:05 [Bug c/58849] New: complex number, memory is corrupted otmar.struwe at web dot de
2013-10-22 22:33 ` [Bug target/58849] " pinskia at gcc dot gnu.org
2013-12-13 12:07 ` otmar.struwe at web dot de

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).