FuhQuake Forum Index FuhQuake
https://fuhquake.net
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

linux damge bug

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    FuhQuake Forum Index -> Bug Reports
View previous topic :: View next topic  
Author Message
orb



Joined: 20 Dec 2003
Posts: 9
Location: russia

PostPosted: Sat Dec 20, 2003 6:56 am    Post subject: linux damge bug Reply with quote

hello there!
First, sorry for my poor english.
I found some bug. that appears if you get damage which splash sreccn by red(i guess falling or i you got shot by monster/player)
I compiled linux glx fuhquake from 30 source, using dinamicaly linking.
Well, the point of bug is:

when i got shot or fall in lava or floor from high region, i got screen
crazy, it rolls like hell like i crazy move my mouse...
well in 28 compild by myself all is ok... in 30 precompiled (fuhquake-linux-v0.30.zip) all is ok too...
but 30 compiled by my self got this bug...
yeah i know i can't explain well Smile
but i can find and fix it, maybe someone get the same behavior ?
sorry again for english...

Added by orb: This bug appears in x11 and i guess svga(not compiled) client too.

Added by orb: Yes this bug affects svga client too(just tested.

To reach this bug, start new single game, wolk into room with 4 doors, walk into right door(e4m*) and jum into water, then fall on the floor... and you'll see what is happened with you view, it will go crazy for a second(i guess it's blood flash normaly when you hirts/monster shot)


Last edited by orb on Sat Dec 20, 2003 11:46 am; edited 2 times in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website
orb



Joined: 20 Dec 2003
Posts: 9
Location: russia

PostPosted: Sat Dec 20, 2003 9:35 am    Post subject: Reply with quote

ok i got the point of bug
it's gcc options
when compilingin debug mode, all runs ok
well it's RELEASE_CFLAGS, i need to find what exactly is wrong ...

ps. im feeling very sleepy Smile
Back to top
View user's profile Send private message Send e-mail Visit poster's website
orb



Joined: 20 Dec 2003
Posts: 9
Location: russia

PostPosted: Sat Dec 20, 2003 11:15 am    Post subject: Reply with quote

well, here is what i found:
when compiled with option:
"-O6" , this bug is appear. Sad strange ...
im using gcc 3.2.3, and has no trouble before with it ...
i tried "-O2" -- same effect. But with "-O" - all works good. Not tried "-O3" yet, it's now compiling...OK "-O3" same effect like "-O2" "-O6" ( i think -O6 == -O3 in new gcc)

It's very strange, cuz fuhquake 0.28 compiled either with:
---
RELEASE_CFLAGS=$(BASE_CFLAGS) -m486 -O6 -ffast-math -funroll-loops -fomit-frame-pointer \
-fexpensive-optimizations -malign-loops=2 -malign-jumps=2 -malign-functions=2
---
or
---
RELEASE_CFLAGS=$(BASE_CFLAGS) -march=i686 -O6 -ffast-math -funroll-loops -fomit-frame-pointer \
-fexpensive-optimizations -falign-loops=2 -falign-jumps=2 -falign-functions=2
---
WOrks good.

Ok, results.
Safe RELEASE_CFLAGS to compile fuhquake 0.30 on i686 with gcc 3.2.3 is:
RELEASE_CFLAGS=$(BASE_CFLAGS) -march=i686 -O -ffast-math -funroll-loops -fomit-frame-pointer \
-fexpensive-optimizations -falign-loops=2 -falign-jumps=2 -falign-functions=2

with this flags binary dinamicaly linked with:
libpng.so.3 => /usr/lib/libpng.so.3 (0x40019000)
libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x40051000)
libm.so.6 => /lib/libm.so.6 (0x4006f000)
libdl.so.2 => /lib/libdl.so.2 (0x40092000)
libGL.so.1 => /usr/lib/libGL.so.1 (0x40095000)
libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x400fe000)
libXext.so.6 => /usr/X11R6/lib/libXext.so.6 (0x401c5000)
libc.so.6 => /lib/libc.so.6 (0x401d4000)
libz.so.1 => /usr/lib/libz.so.1 (0x40306000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
libGLcore.so.1 => /usr/lib/libGLcore.so.1 (0x40314000)
size about 688444 bytes

I hope my effors help you, fuh, to find what makes this bug, i was thinking that it's gcc bug, but 0.28 compiled same way runs good with -O6.

And i'll be glad to help you in testing linux fuhquake in future.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
orb



Joined: 20 Dec 2003
Posts: 9
Location: russia

PostPosted: Sat Dec 20, 2003 11:22 am    Post subject: Reply with quote

I decided to post whole diff -u from Makefile.linux.orig to Makefile.linux i used to compile fuhquake on linux-2.4.23 with gcc 3.2.3, glibc 2.3.2, xfree86 4.3 and nvidia drivers 1.0-4496-1.
I hope it will help guys who wanna compile fuhquake.

--- source/Makefile.linux.orig 2003-10-03 23:11:00.000000000 +0400
+++ source/Makefile.linux 2003-12-20 04:08:58.000000000 +0300
@@ -20,17 +20,20 @@
STATICLIB_DIR= $(SOURCE_DIR)/../lib

#BASE CFLAGS
-XMMS_CFLAGS=-DWITH_XMMS `glib-config --cflags`
+#XMMS_CFLAGS=-DWITH_XMMS `glib-config --cflags`
BASE_CFLAGS= -I$(HEADER_DIR) -funsigned-char -D__linux__ -Did386 $(XMMS_CFLAGS)
-RELEASE_CFLAGS=$(BASE_CFLAGS) -m486 -O6 -ffast-math -funroll-loops -fomit-frame-pointer \
- -fexpensive-optimizations -malign-loops=2 -malign-jumps=2 -malign-functions=2
+#RELEASE_CFLAGS=$(BASE_CFLAGS) -m486 -O6 -ffast-math -funroll-loops -fomit-frame-pointer \
+# -fexpensive-optimizations -malign-loops=2 -malign-jumps=2 -malign-functions=2
+RELEASE_CFLAGS=$(BASE_CFLAGS) -march=i686 -O -ffast-math -funroll-loops -fomit-frame-pointer \
+ -fexpensive-optimizations -falign-loops=2 -falign-jumps=2 -falign-functions=2
DEBUG_CFLAGS=$(BASE_CFLAGS) -g

#BASE LDFLAGS
-LDFLAGS=-lm -ldl `glib-config --libs`
+#LDFLAGS=-lm -ldl `glib-config --libs`
+LDFLAGS=-lm -ldl

#STATIC LIBS
-STATIC_LIBS = $(STATICLIB_DIR)/libxmms.a
+#STATIC_LIBS = $(STATICLIB_DIR)/libxmms.a

#FOR SVGALIB AND X11 BUILDS
DO_CC=$(CC) $(CFLAGS) -o $@ -c $<
@@ -57,7 +60,8 @@

debug: svga_debug x11_debug glx_debug

-release: svga_release x11_release glx_release
+#release: svga_release x11_release glx_release
+release: glx_release

svga_release:
@-mkdir -p $(BUILD_RELEASE_DIR)/build
@@ -587,6 +591,7 @@
#############################################################################

GLQWCL_STATIC_LIBS = $(STATICLIB_DIR)/libXxf86vm.a $(STATICLIB_DIR)/libXxf86dga.a $(STATICLIB_DIR)/libpng.a $(STATICLIB_DIR)/libjpeg.a
+GLQWCL_LIBS = -lXxf86vm -lXxf86dga -lpng -ljpeg

GLQWCL_OBJS = \
$(BUILDDIR)/build-gl/host.o \
@@ -691,7 +696,7 @@
GLQWCL_X11_OBJS = $(BUILDDIR)/build-gl/vid_glx.o $(BUILDDIR)/build-gl/vid_common_gl.o

$(BUILDDIR)/fuhquake-gl.glx : $(GLQWCL_OBJS) $(GLQWCL_X11_OBJS) $(GLQWCL_AS_OBJS) $(STATIC_LIBS)
- $(CC) $(CFLAGS) -o $@ $(GLQWCL_OBJS) $(GLQWCL_X11_OBJS) $(GLQWCL_AS_OBJS) $(GLQWCL_STATIC_LIBS) $(STATIC_LIBS) \
+ $(CC) $(CFLAGS) -o $@ $(GLQWCL_OBJS) $(GLQWCL_X11_OBJS) $(GLQWCL_AS_OBJS) $(GLQWCL_LIBS) $(STATIC_LIBS) \
$(LDFLAGS) $(GL_X11_LDFLAGS)

$(BUILDDIR)/build-gl/host.o : $(SOURCE_DIR)/host.c
Back to top
View user's profile Send private message Send e-mail Visit poster's website
orb



Joined: 20 Dec 2003
Posts: 9
Location: russia

PostPosted: Sat Dec 20, 2003 11:27 am    Post subject: Reply with quote

kinda ps.

compilation with no warnings/errors...thanx to fuh!

Added by orb:
Compilation time of only glx client is:
real 2m27.118s
user 1m54.270s
sys 0m7.380s

Smile
Back to top
View user's profile Send private message Send e-mail Visit poster's website
ParadokS



Joined: 22 Oct 2002
Posts: 95
Location: Copenhagen, Denmark.

PostPosted: Sat Dec 20, 2003 12:40 pm    Post subject: Reply with quote

hehe talking with yourself ? Question Shocked
_________________
Yeah Whatever !
Back to top
View user's profile Send private message Send e-mail Visit poster's website
orb



Joined: 20 Dec 2003
Posts: 9
Location: russia

PostPosted: Sat Dec 20, 2003 12:44 pm    Post subject: Reply with quote

nope Smile
HEYO!
Back to top
View user's profile Send private message Send e-mail Visit poster's website
fuh
Almighty King


Joined: 07 Sep 2002
Posts: 2086

PostPosted: Sat Dec 20, 2003 4:04 pm    Post subject: Reply with quote

I use gcc 2.95 so this is not my problem. When I switch to 3 I will check for problems.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    FuhQuake Forum Index -> Bug Reports All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group

hosted by ausgamers