public inbox for crossgcc@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] arch/microblaze: add new architecture
@ 2012-09-20  4:04 David Holsgrove
  2012-09-22 22:38 ` Yann E. MORIN
  0 siblings, 1 reply; 6+ messages in thread
From: David Holsgrove @ 2012-09-20  4:04 UTC (permalink / raw)
  To: yann.morin.1998; +Cc: crossgcc

# HG changeset patch
# User David Holsgrove <david.holsgrove@xilinx.com>
# Date 1348113698 -36000
# Node ID 9c93e18b3d68b19303f37bf604c0ad907451872a
# Parent  06b663f297adb76149f089136a78e7d5999c63bd
arch/microblaze: add new architecture

Add Microblaze architecture support.

This depends on EXPERIMENTAL, as upstream projects do not yet
include full support to build a modern microblaze compiler.
This is in the process of being updated, but is not currently
publicly accessible.

Signed-off-by: "David Holsgrove" <david.holsgrove@xilinx.com>

diff -r 06b663f297ad -r 9c93e18b3d68 config/arch/microblaze.in
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/config/arch/microblaze.in	Thu Sep 20 14:01:38 2012 +1000
@@ -0,0 +1,22 @@
+# MicroBlaze specific config options
+
+## depends on EXPERIMENTAL
+##
+## select ARCH_SUPPORT_ARCH
+## select ARCH_FLOAT_SW
+## select ARCH_SUPPORTS_BOTH_ENDIAN
+## select ARCH_DEFAULT_BE
+## select ARCH_SUPPORTS_BOTH_MMU
+## select ARCH_DEFAULT_HAS_MMU
+##
+## help The MicroBlaze architecture, as defined by:
+## help 	http://www.xilinx.com/
+## help 
+## help Upstream projects do not currently provide
+## help full support for the microblaze architecture
+## help and as such, this is marked as EXPERIMENTAL
+## help for CT-NG.
+## help 
+## help Support is being added for a modern gcc,
+## help binutils and gdb along with nptl threading
+## help in eglibc for microblaze.
diff -r 06b663f297ad -r 9c93e18b3d68 scripts/build/arch/microblaze.sh
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/scripts/build/arch/microblaze.sh	Thu Sep 20 14:01:38 2012 +1000
@@ -0,0 +1,21 @@
+# Compute microblaze specific values
+
+CT_DoArchTupleValues () {
+    # The architecture part of the tuple:
+    CT_TARGET_ARCH="${CT_ARCH}${target_endian_el}"
+
+    # gcc ./configure flags
+    CT_ARCH_WITH_ARCH=
+    CT_ARCH_WITH_ABI=
+    CT_ARCH_WITH_CPU=
+    CT_ARCH_WITH_TUNE=
+    CT_ARCH_WITH_FPU=
+    CT_ARCH_WITH_FLOAT=
+
+    # CFLAGS
+    case "${CT_ARCH_FLOAT_HW},${CT_ARCH_FLOAT_SW}" in
+        y,) CT_ARCH_FLOAT_CFLAG="-mhard-float" ;;
+        ,y) CT_ARCH_FLOAT_CFLAG="-msoft-float" ;;
+    esac
+
+}

--
For unsubscribe information see http://sourceware.org/lists.html#faq

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] arch/microblaze: add new architecture
  2012-09-20  4:04 [PATCH] arch/microblaze: add new architecture David Holsgrove
@ 2012-09-22 22:38 ` Yann E. MORIN
  2012-10-03  9:34   ` Stephan Linz
  0 siblings, 1 reply; 6+ messages in thread
From: Yann E. MORIN @ 2012-09-22 22:38 UTC (permalink / raw)
  To: crossgcc; +Cc: David Holsgrove

David, All,

On Thursday 20 September 2012 06:04:30 David Holsgrove wrote:
> # HG changeset patch
> # User David Holsgrove <david.holsgrove@xilinx.com>
> # Date 1348113698 -36000
> # Node ID 9c93e18b3d68b19303f37bf604c0ad907451872a
> # Parent  06b663f297adb76149f089136a78e7d5999c63bd
> arch/microblaze: add new architecture

Applied as #7e41a188bd7c. Thank you!

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

--
For unsubscribe information see http://sourceware.org/lists.html#faq

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] arch/microblaze: add new architecture
  2012-09-22 22:38 ` Yann E. MORIN
@ 2012-10-03  9:34   ` Stephan Linz
  2012-10-03 21:48     ` Yann E. MORIN
  0 siblings, 1 reply; 6+ messages in thread
From: Stephan Linz @ 2012-10-03  9:34 UTC (permalink / raw)
  To: crossgcc; +Cc: David Holsgrove, Nagaraju

[-- Attachment #1: Type: text/plain, Size: 2134 bytes --]

Am Sonntag, den 23.09.2012, 00:38 +0200 schrieb Yann E. MORIN: 
> David, All,
> 
> On Thursday 20 September 2012 06:04:30 David Holsgrove wrote:
> > # HG changeset patch
> > # User David Holsgrove <david.holsgrove@xilinx.com>
> > # Date 1348113698 -36000
> > # Node ID 9c93e18b3d68b19303f37bf604c0ad907451872a
> > # Parent  06b663f297adb76149f089136a78e7d5999c63bd
> > arch/microblaze: add new architecture
> 
> Applied as #7e41a188bd7c. Thank you!
> 
> Regards,
> Yann E. MORIN.
> 

Hello David,
Hello Nagaraju,

are there more patches in queue to submit?

I've played a little bit with the new architecture to rebuild the Xilinx
Microblaze toolchains as provided on Git:

  http://git.xilinx.com/?p=microblaze-gnu.git;a=tree;f=binaries 

Unfortunately I run into some issues:

1) Mainstream gcc-4.6.2 doesn't supoorts -mbig-endian/-mlittle-endian
options. The old Petalogix port (gcc-4.1.2) have had added a patch set
for this. I've solved it temporary with a QnD hack in microblaze.sh in
scripts/build/arch: set CT_ARCH_ENDIAN_CFLAG and CT_ARCH_ENDIAN_LDFLAG
empty (grrr, hack hack hack). Here is the gcc error message:

#prompt> touch tt.c
#prompt> microblaze-unknown-linux-gnu-gcc -mbig-endian tt.c
cc1: error: unrecognized command line option '-mbig-endian'

#prompt> microblaze-unknown-linux-gnu-gcc -EB tt.c
microblaze-unknown-linux-gnu-gcc: error: unrecognized option '-EB'

See attachment microblaze-unknown-linux-gnu-gcc--target-help-dump.txt
too.

2) With ./ct-ng libc_start_files I run into eGlibc problems. It tells
me: configure: error: The microblaze is not supported. Does eGlibc
mainline support Microblaze at all?


So it seems some stuff is missing, or not? Can anybody help me or give
me a hint where I can found gcc/eglibc patches (ongoing development
repositories) for Microblaze?


-- 
Best Regards,
Stephan Linz
______________________________________________________________________________
MB-Ref: http://www.li-pro.de/xilinx_mb:mbref:start
OpenDCC: http://www.li-pro.net/opendcc.phtml
PC/M: http://www.li-pro.net/pcm.phtml
Sourceforge: http://sourceforge.net/users/slz
Gitorious: https://gitorious.org/~slz

[-- Attachment #2: microblaze-unknown-linux-gnu-gcc--target-help-dump.txt --]
[-- Type: text/plain, Size: 4616 bytes --]

microblaze-unknown-linux-gnu-gcc (crosstool-NG hg+unknown-20121003.003322) 4.6.2
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

The following options are target specific:
  -G<number>                  Put global and static data smaller than <number>
                              bytes into a special section (on some targets)
  -mandroid                   Generate code for the Android platform.
  -mbionic                    Use Bionic C library
  -mcpu=PROCESSOR             	Use features of and schedule code for given CPU
  -mglibc                     Use GNU C library
  -mhard-float                Use hardware floating point instructions
  -mmemcpy                    Don't optimize block moves, use memcpy
  -mno-clearbss               Clear the BSS to zero and place zero initialized
                              in BSS
  -msmall-divides             Use table lookup optimization for small signed
                              integer divisions
  -msoft-float                Use software emulation for floating point
                              (default)
  -muclibc                    Use uClibc C library
  -mxl-barrel-shift           Use the hardware barrel shifter instead of
                              emulation
  -mxl-float-convert          Use hardware floating point conversion
                              instructions
  -mxl-float-sqrt             Use hardware floating point square root
                              instruction
  -mxl-gp-opt                 Use GP relative sdata/sbss sections
  -mxl-mode-bootstrap         Description for mxl-mode-bootstrap
  -mxl-mode-executable        Description for mxl-mode-executable
  -mxl-mode-novectors         Description for mxl-mode-novectors
  -mxl-mode-xmdstub           Description for mxl-mode-xmdstub
  -mxl-multiply-high          Use multiply high instructions for high part of
                              32x32 multiply
  -mxl-pattern-compare        Use pattern compare instructions
  -mxl-soft-div               Use the software emulation for divides (default)
  -mxl-soft-mul               Use the soft multiply emulation (default)
  -mxl-stack-check            Check for stack overflow at runtime

Assembler options
=================

Use "-Wa,OPTION" to pass "OPTION" to the assembler.


Linker options
==============

Use "-Wl,OPTION" to pass "OPTION" to the linker.

elf32mb_linux: 
  --audit=AUDITLIB            Specify a library to use for auditing
  -Bgroup                     Selects group name lookup rules for DSO
  --build-id[=STYLE]          Generate build ID note
  -P AUDITLIB, --depaudit=AUDITLIB
                              Specify a library to use for auditing dependencies
  --disable-new-dtags         Disable new dynamic tags
  --enable-new-dtags          Enable new dynamic tags
  --eh-frame-hdr              Create .eh_frame_hdr section
  --exclude-libs=LIBS         Make all symbols in LIBS hidden
  --hash-style=STYLE          Set hash style to sysv, gnu or both
  -z combreloc                Merge dynamic relocs into one section and sort
  -z common-page-size=SIZE    Set common page size to SIZE
  -z defs                     Report unresolved symbols in object files.
  -z execstack                Mark executable as requiring executable stack
  -z initfirst                Mark DSO to be initialized first at runtime
  -z interpose                Mark object to interpose all DSOs but executable
  -z lazy                     Mark object lazy runtime binding (default)
  -z loadfltr                 Mark object requiring immediate process
  -z max-page-size=SIZE       Set maximum page size to SIZE
  -z muldefs                  Allow multiple definitions
  -z nocombreloc              Don't merge dynamic relocs into one section
  -z nocopyreloc              Don't create copy relocs
  -z nodefaultlib             Mark object not to use default search paths
  -z nodelete                 Mark DSO non-deletable at runtime
  -z nodlopen                 Mark DSO not available to dlopen
  -z nodump                   Mark DSO not available to dldump
  -z noexecstack              Mark executable as not requiring executable stack
  -z norelro                  Don't create RELRO program header
  -z now                      Mark object non-lazy runtime binding
  -z origin                   Mark object requiring immediate $ORIGIN
                                processing at runtime
  -z relro                    Create RELRO program header


[-- Attachment #3: Type: text/plain, Size: 71 bytes --]

--
For unsubscribe information see http://sourceware.org/lists.html#faq

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] arch/microblaze: add new architecture
  2012-10-03  9:34   ` Stephan Linz
@ 2012-10-03 21:48     ` Yann E. MORIN
  2012-10-04  2:01       ` David Holsgrove
  0 siblings, 1 reply; 6+ messages in thread
From: Yann E. MORIN @ 2012-10-03 21:48 UTC (permalink / raw)
  To: crossgcc, linz; +Cc: David Holsgrove, Nagaraju

Stephan, David, Nagaraju, All,

On Wednesday 03 October 2012 11:34:02 Stephan Linz wrote:
> Am Sonntag, den 23.09.2012, 00:38 +0200 schrieb Yann E. MORIN: 
> > On Thursday 20 September 2012 06:04:30 David Holsgrove wrote:
> > > # HG changeset patch
> > > # User David Holsgrove <david.holsgrove@xilinx.com>
> > > # Date 1348113698 -36000
> > > # Node ID 9c93e18b3d68b19303f37bf604c0ad907451872a
> > > # Parent  06b663f297adb76149f089136a78e7d5999c63bd
> > > arch/microblaze: add new architecture
> > 
> > Applied as #7e41a188bd7c. Thank you!

> are there more patches in queue to submit?

As was stated in the commit log, microblaze support is in the process of
being pushed upstream for the different components impacted:

    ---8<---
    This depends on EXPERIMENTAL, as upstream projects do not yet
    include full support to build a modern microblaze compiler.
    This is in the process of being updated, but is not currently
    publicly accessible.
    ---8<---

Thus, it is expected that the build fails.

David said he'd provide sample defconfigs as soon as he knows the
versions of each components that have microblaze support.

In the meantime, you may want to sneak the Xilinx' binutils, gcc, eglibc
and linux, (from the tree you pointed above) in place of the upstream ones:

    ct-ng menuconfig               <- prepare the versions matching the
                                      ones in the Xilinx tree
    ct-ng +libc_check_config       <- this will extract everything
    cd .build/src                  <- remove the binutils, gcc, eglibc and
                                      linux dirs, and substitute with the
                                      Xilinx ones
    cd ../..
    ct-ng build                    <- restart the build, now with the Xilinx'
                                      sources

No promise on buildability. YMMV, as they use to say...

Of course, David and Nagaraju. if I talked with my ass, feel free to
correct me.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

--
For unsubscribe information see http://sourceware.org/lists.html#faq

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] arch/microblaze: add new architecture
  2012-10-03 21:48     ` Yann E. MORIN
@ 2012-10-04  2:01       ` David Holsgrove
  2012-10-04 22:04         ` Stephan Linz
  0 siblings, 1 reply; 6+ messages in thread
From: David Holsgrove @ 2012-10-04  2:01 UTC (permalink / raw)
  To: Yann E. MORIN, linz; +Cc: crossgcc, nmekala

Hi Stephan, Yann, All

On 4 October 2012 07:48, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> Stephan, David, Nagaraju, All,
>
> On Wednesday 03 October 2012 11:34:02 Stephan Linz wrote:
>> Am Sonntag, den 23.09.2012, 00:38 +0200 schrieb Yann E. MORIN:
>> > On Thursday 20 September 2012 06:04:30 David Holsgrove wrote:
>> > > # HG changeset patch
>> > > # User David Holsgrove <david.holsgrove@xilinx.com>
>> > > # Date 1348113698 -36000
>> > > # Node ID 9c93e18b3d68b19303f37bf604c0ad907451872a
>> > > # Parent  06b663f297adb76149f089136a78e7d5999c63bd
>> > > arch/microblaze: add new architecture
>> >
>> > Applied as #7e41a188bd7c. Thank you!
>
>> are there more patches in queue to submit?
>
> As was stated in the commit log, microblaze support is in the process of
> being pushed upstream for the different components impacted:
>
>     ---8<---
>     This depends on EXPERIMENTAL, as upstream projects do not yet
>     include full support to build a modern microblaze compiler.
>     This is in the process of being updated, but is not currently
>     publicly accessible.
>     ---8<---
>
> Thus, it is expected that the build fails.
>
> David said he'd provide sample defconfigs as soon as he knows the
> versions of each components that have microblaze support.
>

Yann's correct Stephan, there are no other microblaze specific patches
for crosstool-NG queued
for submission, aside from the sample defconfigs which I cant submit
yet without knowing the
version numbers.

I'll speak with Nagaraju with regards the source we're hosting on the
git.xilinx.com page, I believe it
may need updating. There are build scripts and sample configs there
which should build against
the source tarballs we're providing as a stop gap until microblaze
support is added / updated in
mainline.

> In the meantime, you may want to sneak the Xilinx' binutils, gcc, eglibc
> and linux, (from the tree you pointed above) in place of the upstream ones:
>
>     ct-ng menuconfig               <- prepare the versions matching the
>                                       ones in the Xilinx tree
>     ct-ng +libc_check_config       <- this will extract everything
>     cd .build/src                  <- remove the binutils, gcc, eglibc and
>                                       linux dirs, and substitute with the
>                                       Xilinx ones
>     cd ../..
>     ct-ng build                    <- restart the build, now with the Xilinx'
>                                       sources
>
> No promise on buildability. YMMV, as they use to say...
>

I have a feature patch which I'll send to the list now which addresses
this custom source build scenario Yann.
Its modelled on the existing linux custom functionality, so I'm hoping
it can be included to make development /
building of manually revision controlled source easier.

> Of course, David and Nagaraju. if I talked with my ass, feel free to
> correct me.
>

Not at all Yann, thanks for the reply :-)

David

> Regards,
> Yann E. MORIN.
>
> --
> .-----------------.--------------------.------------------.--------------------.
> |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> | +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> '------------------------------^-------^------------------^--------------------'
>
> --
> For unsubscribe information see http://sourceware.org/lists.html#faq
>

--
For unsubscribe information see http://sourceware.org/lists.html#faq

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] arch/microblaze: add new architecture
  2012-10-04  2:01       ` David Holsgrove
@ 2012-10-04 22:04         ` Stephan Linz
  0 siblings, 0 replies; 6+ messages in thread
From: Stephan Linz @ 2012-10-04 22:04 UTC (permalink / raw)
  To: David Holsgrove; +Cc: Yann E. MORIN, crossgcc, nmekala

Hi David, Yann, All

thank you for the fast response. Now I've seen there is a snapshot of
all the source code with latest Microblaze support:

http://git.xilinx.com/?p=microblaze-gnu.git;a=tree;f=src

Together with David's patch "config+scripts: Custom gcc, binutils, libc,
gdb version" I can start to evaluate a cutomized rebuild.


Thanks and br,
Stephan Linz

Am Donnerstag, den 04.10.2012, 12:01 +1000 schrieb David Holsgrove: 
> Hi Stephan, Yann, All
> 
> On 4 October 2012 07:48, Yann E. MORIN <yann.morin.1998@free.fr> wrote:
> > Stephan, David, Nagaraju, All,
> >
> > On Wednesday 03 October 2012 11:34:02 Stephan Linz wrote:
> >> Am Sonntag, den 23.09.2012, 00:38 +0200 schrieb Yann E. MORIN:
> >> > On Thursday 20 September 2012 06:04:30 David Holsgrove wrote:
> >> > > # HG changeset patch
> >> > > # User David Holsgrove <david.holsgrove@xilinx.com>
> >> > > # Date 1348113698 -36000
> >> > > # Node ID 9c93e18b3d68b19303f37bf604c0ad907451872a
> >> > > # Parent  06b663f297adb76149f089136a78e7d5999c63bd
> >> > > arch/microblaze: add new architecture
> >> >
> >> > Applied as #7e41a188bd7c. Thank you!
> >
> >> are there more patches in queue to submit?
> >
> > As was stated in the commit log, microblaze support is in the process of
> > being pushed upstream for the different components impacted:
> >
> >     ---8<---
> >     This depends on EXPERIMENTAL, as upstream projects do not yet
> >     include full support to build a modern microblaze compiler.
> >     This is in the process of being updated, but is not currently
> >     publicly accessible.
> >     ---8<---
> >
> > Thus, it is expected that the build fails.
> >
> > David said he'd provide sample defconfigs as soon as he knows the
> > versions of each components that have microblaze support.
> >
> 
> Yann's correct Stephan, there are no other microblaze specific patches
> for crosstool-NG queued
> for submission, aside from the sample defconfigs which I cant submit
> yet without knowing the
> version numbers.
> 
> I'll speak with Nagaraju with regards the source we're hosting on the
> git.xilinx.com page, I believe it
> may need updating. There are build scripts and sample configs there
> which should build against
> the source tarballs we're providing as a stop gap until microblaze
> support is added / updated in
> mainline.
> 
> > In the meantime, you may want to sneak the Xilinx' binutils, gcc, eglibc
> > and linux, (from the tree you pointed above) in place of the upstream ones:
> >
> >     ct-ng menuconfig               <- prepare the versions matching the
> >                                       ones in the Xilinx tree
> >     ct-ng +libc_check_config       <- this will extract everything
> >     cd .build/src                  <- remove the binutils, gcc, eglibc and
> >                                       linux dirs, and substitute with the
> >                                       Xilinx ones
> >     cd ../..
> >     ct-ng build                    <- restart the build, now with the Xilinx'
> >                                       sources
> >
> > No promise on buildability. YMMV, as they use to say...
> >
> 
> I have a feature patch which I'll send to the list now which addresses
> this custom source build scenario Yann.
> Its modelled on the existing linux custom functionality, so I'm hoping
> it can be included to make development /
> building of manually revision controlled source easier.
> 
> > Of course, David and Nagaraju. if I talked with my ass, feel free to
> > correct me.
> >
> 
> Not at all Yann, thanks for the reply :-)
> 
> David
> 
> > Regards,
> > Yann E. MORIN.
> >
> > --
> > .-----------------.--------------------.------------------.--------------------.
> > |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> > | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> > | +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> > | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> > '------------------------------^-------^------------------^--------------------'
> >
> > --
> > For unsubscribe information see http://sourceware.org/lists.html#faq
> >




--
For unsubscribe information see http://sourceware.org/lists.html#faq

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-10-04 22:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-09-20  4:04 [PATCH] arch/microblaze: add new architecture David Holsgrove
2012-09-22 22:38 ` Yann E. MORIN
2012-10-03  9:34   ` Stephan Linz
2012-10-03 21:48     ` Yann E. MORIN
2012-10-04  2:01       ` David Holsgrove
2012-10-04 22:04         ` Stephan Linz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).