From: David Gibson <david-xT8FGy+AXnRB3Ne2BGzF6laj5H9X9Tb+@public.gmane.org>
To: Kyle Evans <kevans-h+KGxgPPiopAfugRpC6u6w@public.gmane.org>
Cc: Jon Loeliger <jdl-CYoMK+44s/E@public.gmane.org>,
devicetree-compiler-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] Improve compatibility with other platforms
Date: Thu, 4 Jan 2018 14:16:13 +1100 [thread overview]
Message-ID: <20180104031613.GY24581@umbus.fritz.box> (raw)
In-Reply-To: <CACNAnaGEV=YDFsLbGBN+O68dJnDXeRwd0YaXWb2u3x1rSdkF8Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
[-- Attachment #1: Type: text/plain, Size: 3288 bytes --]
On Wed, Jan 03, 2018 at 07:47:55PM -0600, Kyle Evans wrote:
> On Wed, Jan 3, 2018 at 6:54 PM, David Gibson
> <david-xT8FGy+AXnRB3Ne2BGzF6laj5H9X9Tb+@public.gmane.org> wrote:
> > On Wed, Jan 03, 2018 at 08:03:27AM -0600, Kyle Evans wrote:
> >> On Tue, Jan 2, 2018 at 9:55 PM, David Gibson
> >> <david-xT8FGy+AXnRB3Ne2BGzF6laj5H9X9Tb+@public.gmane.org> wrote:
> >> > [... snip ...]
> >> > Great. MacOS support is interesting in particular, because unlike
> >> > FreeBSD, I can set up a Travis build to test it there, which means I'm
> >> > much more likely to catch regressions. In fact, looks like I have a
> >> > stale branch here that added an OSX build to the travis.yml - I think
> >> > some of the errors you've found and didn't have time to debug them
> >> > (debugging when your only host is indirect through Travis is pretty
> >> > painful).
> >>
> >> It'd be interesting to see those results as of recent. Their userland
> >> should be similar enough in the ways you care about for the results to
> >> likely be relevant to us, I would think.
> >
> > I rebased and tried it again:
> > https://travis-ci.org/dgibson/dtc/jobs/324587391
> >
> > Looks like we're getting problems with the interesting way I (ab)use
> > the assembler to produce a test blob. I've hit a number of problems
> > with that over time, so I'd really like to replace it with something
> > else. Unfortunately, I haven't yet thought of a replacement that
> > wouldn't be a pain in the arse.
>
> That's interesting- I wonder what version of LLVM this maps to? Or are
> they so far gone that it doesn't matter? We've got an effort over here
> going to replace our system linker with LLD; the version of LLD that
> we're optionally using on -HEAD right now has no problem with this:
>
> $ ld.lld --version
> LLD 5.0.1 (FreeBSD 320880) (compatible with GNU linkers)
I think the problem is at the asm level, rather than the linker level.
Specifically I think it's failing to realize that expressions of the
form (sym2 - sym1) where sym2 and sym1 are both local labels are
actually assemble time constant and don't need relocation, even if the
symbols themselves do.
If they actually did need relocation, I don't think they're in a form
I'd expect any linker to be able to cope with (or even the ELF format
itself).
I suppose it's possible there's something in the OSX ABI which means
these things really can't be assemble time evaluated, in which case
we'd be pretty stuck.
According to the Travis logs it's using:
$ gcc --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 8.1.0 (clang-802.0.42)
Target: x86_64-apple-darwin16.7.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
I'm assuming it will be using the same LLVM version for assembling as
compiling. Given how out of date the Linux images often are on
Travis, it wouldn't suprise me of the OSX ones are as well.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2018-01-04 3:16 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-01 4:15 [PATCH] Improve compatibility with other platforms kevans-HZy0K5TPuP5AfugRpC6u6w
[not found] ` <20180101041518.23806-1-kevans-HZy0K5TPuP5AfugRpC6u6w@public.gmane.org>
2018-01-03 0:13 ` David Gibson
[not found] ` <20180103001300.GF24581-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2018-01-03 2:37 ` Kyle Evans
[not found] ` <CACNAnaEpF9sK6dNbPG4_f_tyrp3yq1nyG+SS40VUgBCkLqYJdw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-01-03 2:58 ` David Gibson
[not found] ` <20180103025856.GL24581-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2018-01-03 3:29 ` Kyle Evans
[not found] ` <CACNAnaFntyUbpiVVwFfiL_0EtX894Uidsdca3_jdBcNOVM4f0g-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-01-03 3:55 ` David Gibson
[not found] ` <20180103035510.GO24581-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2018-01-03 14:03 ` Kyle Evans
[not found] ` <CACNAnaGwpwRO27d2trLBqZjtiZYP1HBP=ck6GJ2N8VrTNehnFw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-01-04 0:54 ` David Gibson
[not found] ` <20180104005407.GS24581-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2018-01-04 1:47 ` Kyle Evans
[not found] ` <CACNAnaGEV=YDFsLbGBN+O68dJnDXeRwd0YaXWb2u3x1rSdkF8Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-01-04 3:16 ` David Gibson [this message]
2018-01-03 16:51 ` Rob Herring
[not found] ` <CAL_JsqK+ySbuCC27sSQ+VJg78n0m_QOTHQ90ur5pwahyBoU0Dw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-01-04 0:55 ` David Gibson
[not found] ` <20180104005500.GT24581-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2018-01-04 0:58 ` David Gibson
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=20180104031613.GY24581@umbus.fritz.box \
--to=david-xt8fgy+axnrb3ne2bgzf6laj5h9x9tb+@public.gmane.org \
--cc=devicetree-compiler-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=jdl-CYoMK+44s/E@public.gmane.org \
--cc=kevans-h+KGxgPPiopAfugRpC6u6w@public.gmane.org \
/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;
as well as URLs for NNTP newsgroup(s).