#1740 closed defect (fixed)

Change PowerPC multi-libs for e200 and e500 cores

Reported by: Sebastian Huber Owned by: Ralf Corsepius
Priority: normal Milestone: 4.11
Component: tool/gcc Version: 4.11
Severity: normal Keywords:
Cc: joel.sherrill@…, thomas.doerfler@…, chrisj@…, dufault@… Blocked By:
Blocking:

Description (last modified by Gedare Bloom)

Some e200, the e500, and the e500v2 cores have a SPE and embedded floating point unit. They use the general purpose registers for floating point operations. Three multi-lib variants are useful here:

  1. Software floating point
  2. 32-bit hardware floating point (e200 and e500)
  3. 64-bit hardware floating point (e500v2)

We should not support SPE multi-lib variants, because this may effect the interrupt context save and restore overhead. There is also an open GCC bug related to the SPE: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47751

The patch is based on 'contrib/crossrpms/patches/gcc-core-4.5.2-rtems4.11-20101216.diff'.

One question to a part of it in t-rtems:

@@ -47,6 +47,10 @@ MULTILIB_MATCHES += mcpu?7400=mcpu?7450

# Map 750 to .
MULTILIB_MATCHES += mcpu?750=


+# Map e500, 8548 to 8540
+MULTILIB_MATCHES += mcpu?8540=mcpu?e500
+MULTILIB_MATCHES += mcpu?8540=mcpu?8548
+

# Soft-float only, default implies msoft-float
# NOTE: Must match with MULTILIB_MATCHES_FLOAT and MULTILIB_MATCHES
MULTILIB_SOFTFLOAT_ONLY = \

Why do we need this? For example a -mcpu=e500 yields a 'cc1: error: bad value (e500) for -mcpu= switch'.

Also in rtems.h:

+%{mcpu=8540: %{!Dppc*: %{!Dmpc*: -Dppc8540} } }"

This will not trigger in case of -mcpu=8548.

Attachments (6)

powerpc-multi-lib.patch (2.3 KB) - added by Sebastian Huber on Feb 16, 2011 at 8:26:55 AM.
Patch against GCC 4.5.2.
powerpc-multi-lib_v1.patch (2.0 KB) - added by Sebastian Huber on Feb 16, 2011 at 1:57:48 PM.
Patch against GCC 4.5.2.
powerpc-multi-lib_v2.patch (3.1 KB) - added by Sebastian Huber on Feb 22, 2011 at 2:48:18 PM.
Patch against GCC 4.5.2.
powerpc-multi-lib_v3.patch (3.1 KB) - added by Sebastian Huber on Feb 28, 2011 at 7:09:19 AM.
Patch against GCC 4.5.2.
powerpc.patch (3.2 KB) - added by Sebastian Huber on Mar 22, 2011 at 3:07:40 PM.
Patch against GCC 4.6.0-RC-20110321.
powerpc_spe.patch (1.1 KB) - added by dufault on Jun 18, 2011 at 1:28:51 PM.
Patch against GCC 4.6.0

Download all attachments as: .zip

Change History (21)

Changed on Feb 16, 2011 at 8:26:55 AM by Sebastian Huber

Attachment: powerpc-multi-lib.patch added

Patch against GCC 4.5.2.

comment:1 Changed on Feb 16, 2011 at 10:50:02 AM by dufault

Cc: dufault added

Changed on Feb 16, 2011 at 1:57:48 PM by Sebastian Huber

Attachment: powerpc-multi-lib_v1.patch added

Patch against GCC 4.5.2.

comment:2 Changed on Feb 16, 2011 at 1:57:48 PM by Sebastian Huber

attachments.isobsolete: 01

comment:3 Changed on Feb 21, 2011 at 4:22:14 PM by Ralf Corsepius

Resolution: fixed
Status: newclosed

comment:4 Changed on Feb 22, 2011 at 9:11:55 AM by Sebastian Huber

Resolution: fixed
Status: closedreopened

Changed on Feb 22, 2011 at 2:48:18 PM by Sebastian Huber

Attachment: powerpc-multi-lib_v2.patch added

Patch against GCC 4.5.2.

comment:5 Changed on Feb 22, 2011 at 2:48:18 PM by Sebastian Huber

attachments.isobsolete: 01

comment:6 Changed on Feb 25, 2011 at 12:25:49 PM by Joel Sherrill

Cc: Joel Sherrill added

Changed on Feb 28, 2011 at 7:09:19 AM by Sebastian Huber

Attachment: powerpc-multi-lib_v3.patch added

Patch against GCC 4.5.2.

comment:7 Changed on Feb 28, 2011 at 7:09:19 AM by Sebastian Huber

attachments.isobsolete: 01

comment:8 Changed on Mar 1, 2011 at 8:10:55 PM by Chris Johns

Cc: Chris Johns added

Changed on Mar 22, 2011 at 3:07:40 PM by Sebastian Huber

Attachment: powerpc.patch added

Patch against GCC 4.6.0-RC-20110321.

comment:9 Changed on Mar 22, 2011 at 3:07:40 PM by Sebastian Huber

attachments.isobsolete: 01

comment:10 Changed on May 7, 2011 at 4:11:21 AM by thomas.doerfler

Cc: thomas.doerfler added

comment:11 Changed on May 19, 2011 at 5:11:22 AM by Sebastian Huber

blocked: 1799

comment:12 Changed on May 19, 2011 at 5:17:52 AM by Sebastian Huber

blocked: 1800

Changed on Jun 18, 2011 at 1:28:51 PM by dufault

Attachment: powerpc_spe.patch added

Patch against GCC 4.6.0

comment:13 Changed on Jul 15, 2011 at 9:53:59 AM by Ralf Corsepius

Resolution: fixed
Status: reopenedclosed

Replying to comment:32:

Replying to comment:31:

Created attachment 1205 [details]
Patch against GCC 4.6.0

I think all the patches in 1141 are applied except this. Can someone verify
and obsolete the earlier one?

Ralf, would you mind adding the patch posted by Peter Dufault to the current
GCC patch set.

Patch applied - Builds are in progress and will land inside of the repos once the builds have finished (Due to ongoing issues with the build farm machines, this may take a couple of days).

Finally, next time, please include a changelog entry into patch submissions.

comment:14 Changed on Nov 22, 2014 at 12:19:50 PM by Gedare Bloom

Description: modified (diff)
Milestone: 4.11
Version: unspecified4.11

comment:15 Changed on Oct 10, 2017 at 5:58:26 AM by Sebastian Huber

Component: GCCtool/gcc
Note: See TracTickets for help on using tickets.