This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: i386/asm-4 test: use amd64's natural addressing mode on all OSs


On Thu, Aug 15, 2019 at 3:01 PM Alexandre Oliva <oliva@adacore.com> wrote:
>
> On Aug 15, 2019, Uros Bizjak <ubizjak@gmail.com> wrote:
>
> > On Thu, Aug 15, 2019 at 1:39 PM Alexandre Oliva <oliva@adacore.com> wrote:
>
> >> If we just use the best-suited way to
> >> take the address of a function behind the compiler's back on each
> >> target variant, we're less likely to hit unexpected failures.
>
> > Perhaps we should use true absolute address:
>
> But why?  Using absolute addresses is not relevant at all to the test.
> We just need some means to take the address of foo without the
> compiler's realizing we're doing so.

The immediate of lea is limited to +-2GB, so we have in effect
-mcmodel=medium. Using movabs would be OK for all code models.

Uros.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]