discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Gworkspace with non-fragile abi, etc?


From: Lee, Seong-Gu
Subject: Re: Gworkspace with non-fragile abi, etc?
Date: Mon, 26 Aug 2013 16:21:58 +0900
User-agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130803 Thunderbird/17.0.8

On 08/26/2013 04:03 AM, Fred Kiefer wrote:
> 
> I still don't understand what goes on here. Most likely your compiler is
> reordering the lines of code here. The assignment of NSZeroRect should
> only be executed in the exception case and even there it is not needed.
> Could you try to place a breakpoint on NSException? (b [NSException
> raise]) If this breakpoint gets reached before the segmentation fault,
> please provide us with the full stack trace.
> 
> Removing the NSZeroRect initialisation gives still correct code, but I
> would prefer to understand where the problem comes from.
> 
> Fred
> 

 Dear Fred,

 Thank you for your reply.
 I tested by substituting my own svn build (clang, gnustep) with
Philippe Roussel's Ubuntu packages build and llvm.org/apt build.
His build configured with non-fragile and non-debug worked well.
However, trying to build svn version still makes the same error.
 Here is gbd backtrace log ("b [NSException raise]" did not worked") :
--------------------------------------------------------------------
GNU DDD 3.3.12 (i686-pc-linux-gnu), by Dorothea L
Reading symbols from
/home/xxxx/modules/usr-apps/gworkspace/GWorkspace/GWorkspace.app/GWorkspace...done.
(gdb) run
Starting program: GWorkspace
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/i386-linux-gnu/libthread_db.so.1".

Program received signal SIGSEGV, Segmentation fault.
-[NSString(NSStringDrawing) boundingRectWithSize:options:attributes:]
(self=0xb7fbcdd8 <.objc_str485>, _cmd=0xb7de53b8
<.objc_selector_list+104>, size=...,
options=NSStringDrawingUsesLineFragmentOrigin, attrs=0x8a58a60) at
NSStringDrawing.m:683
(gdb) bt
#0  -[NSString(NSStringDrawing)
boundingRectWithSize:options:attributes:] (self=0xb7fbcdd8
<.objc_str485>, _cmd=0xb7de53b8 <.objc_selector_list+104>, size=...,
options=NSStringDrawingUsesLineFragmentOrigin, attrs=0x8a58a60) at
NSStringDrawing.m:683
#1  0xb7b4790e in -[NSString(NSStringDrawing) sizeWithAttributes:]
(self=0xb7fbcdd8 <.objc_str485>, _cmd=0xb7fbcfa8
<.objc_selector_list+440>, attrs=0x8a58a60) at NSStringDrawing.m:671
#2  0xb7f44fc9 in +[FSNBrowserCell initialize] (self=0xb7fbcd40
<_OBJC_CLASS_FSNBrowserCell>, _cmd=0xb6f0afb0 <.objc_selector_list+240>)
at FSNBrowserCell.m:87
#3  0xb7164124 in objc_send_initialize () from
/usr/GNUstep/Local/Library/Libraries/libobjc.so.4.6
#4  0xb7163f96 in objc_send_initialize () from
/usr/GNUstep/Local/Library/Libraries/libobjc.so.4.6
#5  0xb716caf7 in objc_msg_lookup_sender () from
/usr/GNUstep/Local/Library/Libraries/libobjc.so.4.6
#6  0xb716c8fc in slowMsgLookup () from
/usr/GNUstep/Local/Library/Libraries/libobjc.so.4.6
#7  0xb716e7e6 in objc_msgSend () from
/usr/GNUstep/Local/Library/Libraries/libobjc.so.4.6
#8  0x080ebc57 in -[Finder init] (self=0x8a440d0, _cmd=0x81a98e8
<.objc_selector_list+1080>) at Finder/Finder.m:123
#9  0x080eaf4f in +[Finder finder] (self=0x81a9440 <_OBJC_CLASS_Finder>,
_cmd=0x817d308 <.objc_selector_list+184>) at Finder/Finder.m:61
#10 0x08084280 in -[GWorkspace applicationWillFinishLaunching:]
(self=0x8431810, _cmd=0xb7d86ef8 <.objc_selector_list+312>,
aNotification=0x8443608) at GWorkspace.m:467
#11 0xb74277f6 in -[NSObject performSelector:withObject:]
(self=0x8431810, _cmd=0xb772b500 <.objc_selector_list+16>,
aSelector=0xb7d86ef8 <.objc_selector_list+312>, anObject=0x8443608) at
NSObject.m:2028
#12 0xb740f19e in -[NSNotificationCenter _postAndRelease:]
(self=0x82b1fa0, _cmd=0xb772b520 <.objc_selector_list+48>,
notification=0x8443608) at NSNotificationCenter.m:1190
#13 0xb740fa3e in -[NSNotificationCenter
postNotificationName:object:userInfo:] (self=0x82b1fa0, _cmd=0xb772b518
<.objc_selector_list+40>, name=0xb7e0dac8 <.objc_str117>,
object=0x8441e08, info=0x0) at NSNotificationCenter.m:1250
#14 0xb740f8cc in -[NSNotificationCenter postNotificationName:object:]
(self=0x82b1fa0, _cmd=0xb7d87230 <.objc_selector_list+1136>,
name=0xb7e0dac8 <.objc_str117>, object=0x8441e08) at
NSNotificationCenter.m:1230
#15 0xb79692a9 in -[NSApplication finishLaunching] (self=0x8441e08,
_cmd=0xb7d876c0 <.objc_selector_list+2304>) at NSApplication.m:1008
#16 0xb796b987 in -[NSApplication run] (self=0x8441e08, _cmd=0x8177a20
<.objc_selector_list+32>) at NSApplication.m:1538
#17 0x0807a1b6 in main (argc=1, argv=0xbfffec44, env=0xbfffec4c) at
main.m:38
(gdb)
------------------------------------------------------------------

 If this trouble did not occur in your configulation, please ignore this
not to waste your time as only my configulation would have some defects.

 Sincerely yours,
 Lee, Seong-Gu ( at gmail dot com )

















PS) Belows are my stupid test configuation which can be neglected.
However, it is thanksful for anyone to find any faults. I cannot confirm
these occur at any environemnt.

 As build switches are suspected, varied configurations were tested.
"1." is fragile abi and non-debug, "2." is non-fragile abi and non-debug
configuration and "3." is non-fragile abi and debug-default.

To summerize tests below,

                        non-debug               debug-default

                        "1."
fragile-abi     base: 7815 test passed          not tested
                gui: 989 test passed
                gworkspace : build OK
                             execute OK

                        "2."                            "3."
non-fragile     base: 3865 test passed          base: 7838 test passed
                gui: 668 test passed            gui : 989 test passed
                gworkspace : build Fail         gworkspace : build OK
                                                            execute Fail

----------------------------------------------------------------------
1. fragile abi and non-debug (
http://wiki.gnustep.org/index.php/Building_GNUstep_with_Clang )
 (1) gnustep-make
 ./configure CC=clang LD=gcc && make CC=clang LD=gcc && sudo -E make install

 (2) libobjc2
make CC=clang CXX=clang++ LD=gcc && sudo -E make install

 (3) gnustep-base
./configure CC=clang CXX=clang++ LD=gcc && make CC=clang CXX=clang++
LD=gcc && sudo -E make install
 make check
        ...
base/NSArray/basic.m:
Skipped set:       basic.m 46 ... No collection subscripting support in
the compiler.

base/NSArray/blocks.m:
Skipped set:       blocks.m 62 ... No Blocks support in the compiler.
        ...
--- Running tests in base/NSDictionary ---

base/NSDictionary/basic.m:
Skipped set:       basic.m 41 ... No dictionary subscripting support in
the compiler.

base/NSDictionary/blocks.m:
Skipped set:       blocks.m 49 ... No Blocks support in the compiler.
        ...
base/NSMutableIndexSet/blocks.m:
Skipped set:       blocks.m 83 ... No Blocks support in the compiler.
        ...
   7815 Passed tests
     21 Dashed hopes
      5 Skipped sets

All OK!

( When make check OBJCFLAGS="-fblocks -fobjc-non-fragile-abi" was used,
7838 test passed as like non-fragile abi and debug-default. )

 (4) gnustep-gui
 make check
        ...
    989 Passed tests
      4 Dashed hopes

All OK!

 (4) GWorkspace
 build & execute is OK.

2. non-fragile abi and non-debug ( Philippe Roussel's build switch )

 (1) gnustep-make first build
 ./configure --with-layout=gnustep CC=clang CXX=clang++ && make && sudo
-E make install

 (2) libobjc2 build
 cmake .. -DCMAKE_C_COMPILER=clang && make debug=no && sudo -E make install
 make test
        ...
94% tests passed, 2 tests failed out of 34

Total Test time (real) =   3.95 sec

The following tests FAILED:
         23 - PropertyIntrospectionTest2 (OTHER_FAULT)
         24 - PropertyIntrospectionTest2_optimised (OTHER_FAULT)
Errors while running CTest
make: *** [test] Error 8

 (3) gnustep-make with libobjc2
 ./configure --enable-objc-nonfragile-abi --with-layout=gnustep && make
&& sudo -E make install

 (4) gnustep-base
 ./configure --disable-mixedabi --disable-unicodeconstants && make &&
sudo -E make install
 make check
        ...
base/NSXMLParser/parse.m:
Failed file:     parse.m aborted without running all tests!
--- Running tests in base/PropertyLists ---

base/PropertyLists/test01.m:
Failed file:     test01.m aborted without running all tests!
--- Running tests in base/Unicode ---

   3865 Passed tests
     97 Failed files
      4 Dashed hopes

 (5) gnustep-gui, gnustep-back
 ./configure && make && sudo -E make install
 make check
        ...
gui/TextSystem/deallocation.m:
Failed file:     deallocation.m aborted without running all tests!

gui/TextSystem/repeatedAttachmentCellHeight.m:
Failed file:     repeatedAttachmentCellHeight.m aborted without running
all tests!

    668 Passed tests
     19 Failed files

 (6) gworkspace
 ./configure && make messages=yes
        ...
.; rm -f libOperation.so; if [ "libOperation.so.1" !=
"libOperation.so.1.0.0" ]; then rm -f libOperation.so.1; ln -s
libOperation.so.1.0.0 libOperation.so.1; fi; ln -s libOperation.so.1
libOperation.so; ) || rm -f
./Operation.framework/Versions/1/./libOperation.so.1.0.0 ; \
        (cd ./Operation.framework/Versions/1/.; \
          rm -f Operation; \
          ln -s libOperation.so Operation) \
        
for f in Resources/Images/* Resources/English.lproj; do \
          if [ -f $f -o -d $f ]; then \
            cp -fr $f ./Operation.framework/Versions/1/Resources/; \
          else \
            echo "Warning: $f not found - ignoring"; \
          fi; \
        done
(echo "{"; echo '  NOTE = "Automatically generated, do not edit!";'; \
          echo "  NSExecutable = \"Operation\";"; \
          echo "  NSMainNibFile = \"\";"; \
          echo "  NSPrincipalClass = \"Operation\";"; \
          echo "  Classes = "; \
          cat ./derived_src/Operation-class-list; \
          echo "  ;"; \
          echo "}") >Operation.framework/Versions/1/Resources/Info-gnustep.plist
if [ -r "OperationInfo.plist" ]; then \
           plmerge Operation.framework/Versions/1/Resources/Info-gnustep.plist
OperationInfo.plist; \
         fi
Segmentation fault (core dumped)
make[2]: ***
[Operation.framework/Versions/1/Resources/Info-gnustep.plist] Error 139
make[2]: *** Deleting file
`Operation.framework/Versions/1/Resources/Info-gnustep.plist'
make[1]: *** [Operation.all.framework.variables] Error 2
make[1]: Leaving directory
`/home/kira/modules/usr-apps/gworkspace/Operation'
make: *** [internal-all] Error 2
        ...


3. non-fragile, debug-default (
http://etoileos.com/downloads/installtrunk/ )

 (1) gnustep-make first build
 ./configure --enable-debug-by-default --with-layout=gnustep CC=clang
CXX=clang++ && make && sudo -E make install

 (2) libobjc2 build
 cmake .. -DCMAKE_C_COMPILER=clang && make debug=no && sudo -E make install
 make test
        ...
94% tests passed, 2 tests failed out of 34

Total Test time (real) =   3.95 sec

The following tests FAILED:
         23 - PropertyIntrospectionTest2 (OTHER_FAULT)
         24 - PropertyIntrospectionTest2_optimised (OTHER_FAULT)
Errors while running CTest
make: *** [test] Error 8

 (3) gnustep-make with libobjc2
 ./configure --enable-debug-by-default --enable-objc-nonfragile-abi
--with-layout=gnustep && make && sudo -E make install

 (4) gnustep-base
 ./configure --disable-mixedabi --disable-unicodeconstants && make &&
sudo -E make install
 make check
        ...
   7838 Passed tests
     21 Dashed hopes

All OK!

 (5) gnustep-gui, gnustep-back
 ./configure && make && sudo -E make install
 make check
        ...
    989 Passed tests
      4 Dashed hopes

All OK!

 (6) gworkspace
 ./configure && make && sudo -E make install
 GWorkspace
[1]+  Segmentation fault      (core dumped) GWorkspace
----------------------------------------------------------------




reply via email to

[Prev in Thread] Current Thread [Next in Thread]