public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Peter Tyser <ptyser@xes-inc.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] examples/standalone: Remove relocation compile flags for PowerPC
Date: Fri, 10 Sep 2010 15:07:29 -0500	[thread overview]
Message-ID: <1284149249.26713.2926.camel@petert> (raw)
In-Reply-To: <AANLkTind-oG3GybHseL+wLhkg8Xd6Nbf4V9UaeP5ksPb@mail.gmail.com>

On Fri, 2010-09-10 at 14:53 -0500, Timur Tabi wrote:
> On Fri, Sep 10, 2010 at 2:49 PM, Wolfgang Denk <wd@denx.de> wrote:
> 
> > AFAICT you did not reply to this, and the problem is still unsolved.
> >
> > Do you still have this on your list?
> 
> Sorry, I'm confused.  What exactly do you want me to do?  Since you
> applied Peter's patch, the problem has gone away for me.

Wolfgang applied the "examples/standalone: Remove relocation compile
flags for PowerPC" patch.  That patch should remove the few bytes of
relocation cruft that bumped up the first function address by a few
bytes in standalone images.

However, I think there's still the issue that if there are multiple
functions in a standalone application there's no guarantee the entry
point function will be at the base of the image.  eg if the app were:

int helper_func() {
	code()...
}

int entry_point() {
	// application entry point
}

The entry point wouldn't be at the base of the image, it'd be offset by
the size of helper_func(), and it would jump around depending on
compiler version, flags, etc.

My last question on the issue was:
It looks like the -fno-toplevel-reorder flag is only available in gcc >=
4.2 (http://gcc.gnu.org/gcc-4.2/changes.html released May 2007).  So, do
we add support to U-Boot to conditionally check for the gcc version like
Linux to know when to use -fno-toplevel-reorder?  Or do we use a linker
script that would support more versions of gcc at the cost of more
complexity?

I never heard back about the preferred method.  I'd personally lean
towards checking for compiler version and using the gcc version check +
-fno-toplevel-reorder.

Best,
Peter

  reply	other threads:[~2010-09-10 20:07 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-15  3:25 [U-Boot] [PATCH] examples/standalone: Remove relocation compile flags for PowerPC Peter Tyser
2010-06-15 19:02 ` Timur Tabi
2010-06-15 19:05   ` Timur Tabi
2010-06-15 19:08     ` Peter Tyser
2010-06-15 19:20       ` Timur Tabi
2010-06-15 19:34         ` Peter Tyser
2010-06-15 19:36     ` Peter Tyser
2010-06-15 19:45       ` Timur Tabi
2010-06-15 20:15         ` Peter Tyser
2010-06-15 20:28           ` Wolfgang Denk
2010-06-15 20:39             ` Peter Tyser
2010-06-15 20:51               ` Wolfgang Denk
2010-06-16  3:37                 ` Peter Tyser
2010-06-16 14:02                   ` Timur Tabi
2010-06-16 14:51                     ` Wolfgang Denk
2010-09-10 19:49                       ` Wolfgang Denk
2010-09-10 19:53                         ` Timur Tabi
2010-09-10 20:07                           ` Peter Tyser [this message]
2010-09-10 21:10                             ` Wolfgang Denk
2010-09-12 22:38                             ` [U-Boot] [PATCH] examples/standalone: Use gcc's -fno-toplevel-reorder Peter Tyser
2010-09-13  2:00                               ` Andrew Dyer
2010-09-13  4:48                                 ` Peter Tyser
2010-09-16 11:49                                   ` Detlev Zundel
2010-10-12 20:47                               ` Wolfgang Denk
2010-06-15 20:39             ` [U-Boot] [PATCH] examples/standalone: Remove relocation compile flags for PowerPC Timur Tabi
2010-06-15 20:54               ` Wolfgang Denk
2010-06-15 21:03                 ` Timur Tabi
2010-06-15 22:56                   ` Wolfgang Denk
2010-06-15 19:48 ` Wolfgang Denk
2010-06-29 20:29   ` Wolfgang Denk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1284149249.26713.2926.camel@petert \
    --to=ptyser@xes-inc.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox