From: "Marc Poulhiès" <dkm@kataplop.net>
To: jose.marchesi@oracle.com
Cc: anolasc13@gmail.com, bpf@vger.kernel.org
Subject: Re: Support for gcc
Date: Thu, 29 Dec 2022 19:22:21 +0100 [thread overview]
Message-ID: <87lemqvzmq.fsf@kataplop.net> (raw)
In-Reply-To: 87pmc6xzzp.fsf@oracle.com
>> BTW, when I tried to use bpf-gcc in godbolt.org, I did not add any
>> additional compile options, and it reported an error:
>>
>> /opt/compiler-explorer/bpf/gcc-trunk-20221225/bpf-unknown-none/lib/gcc/bpf-unknown-none/13.0.0/../../../../bpf-unknown-none/bin/ld:
>> -pie not supported
>> collect2: error: ld returned 1 exit status
>> Compiler returned: 1
>
> Hmm, I just tried and it didn't add -pie to the command line options. I
> think that somehow godbolt.org remembers and re-uses the settings used
> by the last user. At least when it comes to select the cross compiler.
> Maybe it is the same with the compilation options...
Hi,
Happened to find this discussion and am taking the liberty to reply,
hope that's ok :)
Compiler-Explorer does not reuse anything from another user. It may
reuse something you've used in a previous session stored in your local
browser, but then this will show in the "Compiler Options...." text
field.
Here's my findings about this pie. By default, we only emit
assembly (so you won't see any ld error). But if you ask for linking to
a binary (Output >> Compile to binary), you will get this error:
https://godbolt.org/z/za3sbr5qn
Looks like our toolchain defaults to PIE. I'll look into that
(https://github.com/compiler-explorer/compiler-explorer/issues/4517).
You can use -fno-pie or uncheck "compile to binary" in the meantime.
Thanks,
Marc
PS: If you think you have a bug in compiler-explorer, click the "share"
menu (top right) and provide us with a link (short or full, both work,
but short will be easier to share in a mail).
next reply other threads:[~2022-12-29 18:39 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-29 18:22 Marc Poulhiès [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-12-20 11:45 Support for gcc SuHsueyu
2022-12-20 17:27 ` sdf
2022-12-21 0:34 ` Andrii Nakryiko
2022-12-21 11:03 ` SuHsueyu
2022-12-21 17:41 ` Alan Maguire
2022-12-21 18:26 ` Jose E. Marchesi
2022-12-21 18:22 ` Jose E. Marchesi
2022-12-21 18:30 ` Jose E. Marchesi
2022-12-25 15:24 ` SuHsueyu
2022-12-26 9:42 ` Jose E. Marchesi
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=87lemqvzmq.fsf@kataplop.net \
--to=dkm@kataplop.net \
--cc=anolasc13@gmail.com \
--cc=bpf@vger.kernel.org \
--cc=jose.marchesi@oracle.com \
/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