mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "jidong xiao" <jidong.xiao@gmail.com>
To: linux-kernel@vger.kernel.org
Subject: What's the difference between clear_page and clear_page_c?
Date: Tue, 18 Nov 2008 19:35:20 +0800	[thread overview]
Message-ID: <4104961b0811180335j2f0506bmcef515e070b08f14@mail.gmail.com> (raw)

Hi, All,

I saw there are clear_page and clear_page_c defined in
arch/x86/lib/clear_page_64.S, but what's the difference between these
two function? In addition, look at below lines copied from
linux-2.6.27-rc2, particularly line 16, is it a typo? I feel it should
be ENDPROC(clear_page_c) other than ENDPROC(clear_page), isn't it??

      4 /*
      5  * Zero a page.
      6  * rdi  page
      7  */
      8         ALIGN
      9 clear_page_c:
     10         CFI_STARTPROC
     11         movl $4096/8,%ecx
     12         xorl %eax,%eax
     13         rep stosq
     14         ret
     15         CFI_ENDPROC
     16 ENDPROC(clear_page)
     17
     18 ENTRY(clear_page)
     19         CFI_STARTPROC
     20         xorl   %eax,%eax
     21         movl   $4096/64,%ecx
     22         .p2align 4
     23 .Lloop:
     24         decl    %ecx
     25 #define PUT(x) movq %rax,x*8(%rdi)
     26         movq %rax,(%rdi)
     27         PUT(1)
     28         PUT(2)
     29         PUT(3)
     30         PUT(4)
     31         PUT(5)
     32         PUT(6)
     33         PUT(7)
     34         leaq    64(%rdi),%rdi
     35         jnz     .Lloop
     36         nop
     37         ret
     38         CFI_ENDPROC
     39 .Lclear_page_end:
     40 ENDPROC(clear_page)

Regards
Jason

                 reply	other threads:[~2008-11-18 11:35 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=4104961b0811180335j2f0506bmcef515e070b08f14@mail.gmail.com \
    --to=jidong.xiao@gmail.com \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®