linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH 0/1] x86: change mov 0, %reg to xor %reg, %reg
@ 2022-08-08 17:24 Alexey Dobriyan
  0 siblings, 0 replies; 2+ messages in thread
From: Alexey Dobriyan @ 2022-08-08 17:24 UTC (permalink / raw)
  To: knscarlet; +Cc: tglx, linux-kernel, mingo, bp, dave.hansen, hpa, x86

Reviewed-by: Alexey Dobriyan <adobriyan@gmail.com>

Patch seems to be OK.

Minus interwebs points for using AT&T syntax.

Changing objtool to detect overlong "mov r32, imm32" automatically
would be cool.

^ permalink raw reply	[flat|nested] 2+ messages in thread
* [PATCH 0/1] x86 change mov 0, %reg to xor %reg, %reg
@ 2022-08-04 15:26 Kanna Scarlet
  0 siblings, 0 replies; 2+ messages in thread
From: Kanna Scarlet @ 2022-08-04 15:26 UTC (permalink / raw)
  To: Thomas Gleixner, Ingo Molnar, Borislav Petkov, Dave Hansen,
	H. Peter Anvin, x86
  Cc: Kanna Scarlet, Ard Biesheuvel, Bill Metzenthen, Brijesh Singh,
	Joerg Roedel, Josh Poimboeuf, Kirill A. Shutemov, Mark Rutland,
	Michael Roth, Peter Zijlstra, Sean Christopherson,
	Steven Rostedt, Ammar Faizi, GNU/Weeb Mailing List,
	Linux Kernel Mailing List

Hello Linux x86 maintainers,

I'm an informatic student 19 y.o. I am still studying Linux kernel open
source in GNU/Weeb community. I want to be a linux kerne dev in the
future. This is my first time sending a patch to Linux Kernel, I am
still learning the community. I may make a mistake in this email, please
correct me if i am wrong

I want to improve x86-64 assembly code with this patch. This patch
changes mov $0, %reg with xor %reg, %reg because xor %reg, %reg is
smaller so it is good to save space

asm:
ba 00 00 00 00  mov   $0x0,%edx
31 d2           xor   %edx,%edx


Regards,

Signed-off-by: Kanna Scarlet <knscarlet@gnuweeb.org>
---

Kanna Scarlet (1):
  x86: Change mov $0, %reg with xor %reg, %reg

 arch/x86/boot/compressed/head_64.S     | 2 +-
 arch/x86/boot/compressed/mem_encrypt.S | 2 +-
 arch/x86/kernel/ftrace_32.S            | 4 ++--
 arch/x86/kernel/head_64.S              | 2 +-
 arch/x86/math-emu/div_Xsig.S           | 2 +-
 arch/x86/math-emu/reg_u_sub.S          | 2 +-
 6 files changed, 7 insertions(+), 7 deletions(-)


base-commit: ff89dd08c0f0a3fd330c9ef9d775e880f82c291e
-- 
Kanna Scarlet


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-08-08 17:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-08 17:24 [PATCH 0/1] x86: change mov 0, %reg to xor %reg, %reg Alexey Dobriyan
  -- strict thread matches above, loose matches on Subject: below --
2022-08-04 15:26 [PATCH 0/1] x86 " Kanna Scarlet

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).