OS/2, eCS & ArcaOS - Technical > Programming

Test build of GCC 4.7.3 available

<< < (4/6) > >>

Andy Willis:
Thank you...
Built nasm, glibidl, and mzftcfg and used these to build Seamonkey (esr10 build) with 4.7.3 and binutils 2.23... posting from said Seamonkey now.

Dave Yeo:

--- Quote from: Paul Smedley on September 08, 2013, 12:05:45 am ---fate tests fail here with:
Test eval failed. Look at tests/data/fate/eval.err for details.

http://smedley.id.au/tmp/eval.err

--- End quote ---

That'll be the FPU exception bug where the Presentation Manager re-enables FPU exceptions without saving state and restoring state, my V4+free updates install doesn't have it.
Easiest fix is to add
 
--- Code: ---#ifdef __i386
    short fcr;
    __asm__ volatile ("fstcw        %0 \n"
                      "or      $63, %0 \n"
                      "fldcw        %0 \n"
                      : "=m"(fcr));
#endif

--- End code ---
or from Cairo,

--- Code: ---static inline void
DisableFPUException (void)
{
    unsigned short usCW;

    /* Some OS/2 PM API calls modify the FPU Control Word,
     * but forget to restore it.
     *
     * This can result in XCPT_FLOAT_INVALID_OPCODE exceptions,
     * so to be sure, we disable Invalid Opcode FPU exception
     * before using FPU stuffs.
     */
    usCW = _control87 (0, 0);
    usCW = usCW | EM_INVALID | 0x80;
    _control87 (usCW, MCW_EM | 0x80);
}

--- End code ---
after main() in all executables.
Plan9 has a similar bug and there is an alternative main() in compat/plan9/main.c where main() is undefined and replaced but I never could get it to work on OS/2, multiple symbol errors, I guess it would be needed to be added to crt0.obj and perhaps used with another flag much like -Zbin-args.

Paul Smedley:

--- Quote from: Dave Yeo on September 08, 2013, 04:28:58 am ---
--- Quote from: Paul Smedley on September 08, 2013, 12:05:45 am ---fate tests fail here with:
Test eval failed. Look at tests/data/fate/eval.err for details.

http://smedley.id.au/tmp/eval.err

--- End quote ---

That'll be the FPU exception bug where the Presentation Manager re-enables FPU exceptions without saving state and restoring state, my V4+free updates install doesn't have it.
Easiest fix is to add

--- End quote ---

OK will try it tomorrow - too many beers tonight - had an engagement party this afternoon :)

Paul Smedley:

--- Quote from: Paul Smedley on August 31, 2013, 06:27:04 am ---GCC 4.7.x is likely to be the last release of GCC I will build, as with GCC 4.8.x they moved to a C++ implementation for the compiler, so the patches would need to be completely rewritten for GCC 4.8.  Based on the levels of interest in the OS and developer tools....... I will continue to investigate bugs in this and other GCC releases I've done, as well as bump the version for any further GCC minor releases (ie GCC 4.7.4)

--- End quote ---

Seems I was wrong about GCC 4.8.x

I downloaded the sources this evening and applied the 4.7.3 patches fairly cleanly. Now will see if it builds....

mickhead:
That's good news, indeed  :)

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version