Results 1 to 3 of 3

Thread: KOS environment

                  
   
  1. #1
    DCEmu Coder GPF's Avatar
    Join Date
    Apr 2004
    Location
    Texas
    Age
    52
    Posts
    796
    Rep Power
    78

    Default KOS environment

    had a couple of questions about debug vs release environments for KOS.

    right now I am using for my $KOS_CFLAGS

    Code:
    -O2 -DFRAME_POINTERS -ml -m4-single-only -fno-crossjumping -I/usr/local/dc/kos1.3/kos/../kos-ports/include -I/usr/local/dc/kos1.3/kos/include -I/usr/local/dc/kos1.3/kos/kernel/arch/dreamcast/include -I/usr/local/dc/kos1.3/kos/addons/include -D_arch_dreamcast -D_arch_sub_pristine -Wall -g -fno-builtin -fno-strict-aliasing
    and thats what my KOS libs were built with.

    For a release should I recompile KOS with
    -fomit-frame-pointer and remove the -g ? Also Is there any benifit for recompile KOS with more optimizations -O3?

    Also with the new gnu-wrappers, if I want to use other compilation environment(different flags/higher optimization), is there an easy way to do that? or do I just have a second environ..sh script that I run when doing builds vs when rebuilding KOS ?

    Thanks,
    Troy

  2. #2
    DCEmu Coder
    Join Date
    Nov 2004
    Location
    Portland, OR, USA
    Posts
    54
    Rep Power
    0

    Default Re: KOS environment

    [quote author=GPF link=board=Dev;num=1104961879;start=0#0 date=01/05/05 at 15:51:19]For a release should I recompile KOS with
    -fomit-frame-pointer and remove the -g ? Also Is there any benifit for recompile KOS with more optimizations -O3?[/quote]

    Definitely don't go to -O3. It provides little benefit even in the normal x86 type platforms (sometimes it even makes the code slower!) and the optimization on SH-4 is not unbuggy enough either.

    For the other, you can do that if you like but it's more of a personal preference. The omit-frame-pointer frees up a general purpose register but I've not found it to make a huge difference, and that introduces differences into the code that could turn into bug entropy.

    Removing the -g is also not really necessary because you can just run sh-elf-strip when you're done and remove the symbols, and they won't get copied into a .bin anyway.

    Also with the new gnu-wrappers, if I want to use other compilation environment(different flags/higher optimization), is there an easy way to do that? or do I just have a second environ..sh script that I run when doing builds vs when rebuilding KOS ?
    Yeah you need a new script. The wrappers didn't change that, you just don't see it anymore. All they do is run your sh-elf GCC with KOS_CFLAGS and all that.
    Cryptic Allusion Games / Cryptic Allusion, LLC
    http://www.cagames.com/

  3. #3
    DCEmu Coder GPF's Avatar
    Join Date
    Apr 2004
    Location
    Texas
    Age
    52
    Posts
    796
    Rep Power
    78

    Default Re: KOS environment

    thanks

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •