Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1636518

Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for multiplication to work around Clang incompatibility

From Ingo Molnar <mingo@kernel.org>
Newsgroups linux.kernel
Subject Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for multiplication to work around Clang incompatibility
Date 2017-05-05 20:00 +0200
Message-ID <tDPGi-4Wu-9@gated-at.bofh.it> (permalink)
References <tCsiK-6wM-17@gated-at.bofh.it> <tDGMF-7Ep-5@gated-at.bofh.it> <tDIEN-s5-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


* Peter Zijlstra <peterz@infradead.org> wrote:

> On Fri, May 05, 2017 at 01:11:47AM -0700, tip-bot for Matthias Kaehlcke wrote:
> > Commit-ID:  121843eb02a6e2fa30aefab64bfe183c97230c75
> > Gitweb:     http://git.kernel.org/tip/121843eb02a6e2fa30aefab64bfe183c97230c75
> > Author:     Matthias Kaehlcke <mka@chromium.org>
> > AuthorDate: Mon, 1 May 2017 15:47:41 -0700
> > Committer:  Ingo Molnar <mingo@kernel.org>
> > CommitDate: Fri, 5 May 2017 08:31:05 +0200
> > 
> > x86/mm/kaslr: Use the _ASM_MUL macro for multiplication to work around Clang incompatibility
> > 
> > The constraint "rm" allows the compiler to put mix_const into memory.
> > When the input operand is a memory location then MUL needs an operand
> > size suffix, since Clang can't infer the multiplication width from the
> > operand.
> 
> *sigh*, this is another shining example of how LLVM is a better, faster
> moving compiler?

Well, I don't like it - but we already have similar patterns to cover some asm 
complications so I didn't mind. Apparently Clang is very close to being able to 
build a working Linux kernel, right?

In that sense it would be unfair to expect it to not have various legacies, 
missing features and quirks - just like the kernel has dozens of GCC related 
workarounds.

Thanks,

	Ingo

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2] x86/mm/kaslr: Use _ASM_MUL macro for multiplication Matthias Kaehlcke <mka@chromium.org> - 2017-05-02 00:50 +0200
  Re: [PATCH v2] x86/mm/kaslr: Use _ASM_MUL macro for multiplication Kees Cook <keescook@chromium.org> - 2017-05-02 04:10 +0200
  [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility tip-bot for Matthias Kaehlcke <tipbot@zytor.com> - 2017-05-05 10:30 +0200
    Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Peter Zijlstra <peterz@infradead.org> - 2017-05-05 12:30 +0200
      Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Ingo Molnar <mingo@kernel.org> - 2017-05-05 20:00 +0200
        Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Peter Zijlstra <peterz@infradead.org> - 2017-05-05 20:30 +0200
        Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Matthias Kaehlcke <mka@chromium.org> - 2017-05-05 20:50 +0200
          Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Linus Torvalds <torvalds@linux-foundation.org> - 2017-05-05 21:40 +0200
            Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Michael Davidson <md@google.com> - 2017-05-05 22:40 +0200
              Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Peter Zijlstra <peterz@infradead.org> - 2017-05-06 10:20 +0200
                Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for multiplication to work around Clang incompatibility hpa@zytor.com - 2017-05-08 00:10 +0200
            Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Matthias Kaehlcke <mka@chromium.org> - 2017-05-05 23:00 +0200
              Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Ingo Molnar <mingo@kernel.org> - 2017-05-06 12:00 +0200
          Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for multiplication to work around Clang incompatibility hpa@zytor.com - 2017-05-05 22:00 +0200
            Re: [tip:x86/urgent] x86/mm/kaslr: Use the _ASM_MUL macro for  multiplication to work around Clang incompatibility Matthias Kaehlcke <mka@chromium.org> - 2017-05-05 23:30 +0200

csiph-web