dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: bugzilla-daemon@freedesktop.org
To: dri-devel@lists.freedesktop.org
Subject: [Bug 48693] -O2 optimization breaks 32 bit wine 3D on 64 bit system
Date: Mon, 16 Apr 2012 09:50:15 +0000	[thread overview]
Message-ID: <bug-48693-502-AdUkddr9Bo@http.bugs.freedesktop.org/> (raw)
In-Reply-To: <bug-48693-502@http.bugs.freedesktop.org/>

https://bugs.freedesktop.org/show_bug.cgi?id=48693

--- Comment #4 from Christoph Haag <haagch.christoph@googlemail.com> 2012-04-16 02:50:15 PDT ---
(In reply to comment #3)
> Does it work with -O2 -fno-strict-aliasing? The Mesa tree is known not to be
> strict aliasing clean. If that's not it, maybe you can isolate the specific
> optimization enabled by -O2 but not -O1 which triggers the crash.
> 
> I suspect this bug may be invalid anyway though: you shouldn't set CFLAGS
> directly but use OPT_FLAGS and friends.

Well, I set it to -O2 for testing. Archlinux does set the CFLAGS so if this is
wrong, Archlinux is doing it wrong?

Archlinux's default CFLAGS are by the way:
CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector
--param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2"
(I personally use -march=native)

So I tried setting my CFLAGS to CFLAGS="$CFLAGS -fno-strict-aliasing".

Compiling lib32 mesa looks like this now:

gcc -m32 -c -I. -I../../../src/gallium/include -I../../../src/gallium/auxiliary
-I../../../src/gallium/drivers  -march=native -fomit-frame-pointer -O2 -pipe
-fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2
-fno-strict-aliasing -Wall -std=c99 -Werror=implicit-function-declaration
-Werror=missing-prototypes -fno-strict-aliasing -fno-builtin-memcmp -m32
-march=native -fomit-frame-pointer -O2 -pipe -fstack-protector
--param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fno-strict-aliasing  -fPIC -m32
-DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM -D_GNU_SOURCE
-DPTHREADS -DTEXTURE_FLOAT_ENABLED -DHAVE_POSIX_MEMALIGN -DIN_DRI_DRIVER
-DUSE_XCB -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_TLS
-DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER -DHAVE_ALIAS
-DHAVE_MINCORE -DHAVE_LIBUDEV -DHAVE_XEXTPROTO_71 -D__STDC_CONSTANT_MACROS
-DHAVE_LLVM=0x0300 -fvisibility=hidden -I/usr/include   -D_GNU_SOURCE
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
util/u_rect.c -o util/u_rect.o



-fno-strict-aliasing does not fix the wine crashes.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

  parent reply	other threads:[~2012-04-16  9:50 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-14 17:28 [Bug 48693] New: -O2 optimization breaks 32 bit wine 3D on 64 bit system bugzilla-daemon
2012-04-14 18:38 ` [Bug 48693] " bugzilla-daemon
2012-04-14 19:33 ` bugzilla-daemon
2012-04-16  1:40 ` bugzilla-daemon
2012-04-16  9:50 ` bugzilla-daemon [this message]
2012-09-12 15:06 ` bugzilla-daemon
2012-09-15 23:21 ` bugzilla-daemon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-48693-502-AdUkddr9Bo@http.bugs.freedesktop.org/ \
    --to=bugzilla-daemon@freedesktop.org \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox