public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: dorian.araneda@intel.com
To: gcc-gnats@gcc.gnu.org
Subject: optimization/3329: optimization large memory copies uses kernel memcpy function without user's knowledge.
Date: Thu, 21 Jun 2001 08:16:00 -0000	[thread overview]
Message-ID: <20010621150810.31468.qmail@sourceware.cygnus.com> (raw)

>Number:         3329
>Category:       optimization
>Synopsis:       optimization large memory copies uses kernel memcpy function without user's knowledge.
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Jun 21 08:16:01 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Dorian S. Araneda
>Release:        unknown-1.0,  version that comes with SuSE 7.1
>Organization:
>Environment:
SuSE 7.1, Pentium II, kernel module compiled with: cc -Wall -O   
>Description:
if I do an assignment of one large structure to another, "myLargeStruct1 = myLargeStruct2", compiler optimization will
choose to use kernel memcpy() instead of generating its own assembly language.  this causes problems for compiled code that must remain
kernel generic and never intend to use kernel calls. Object code will contain mismatched memcpy symbols between
kernels implementing symbol version signatures.  I do not know at what structure size the optimizer looks for to decide whether to use memcpy or
not.  All I know is that the user is unaware that this linkage is occurring and the only way to discover what the compiler did is recognizing the
error and examining the ".s" files.
>How-To-Repeat:
create some large structues. i dont know what size to use.
and do an assignment   "largestruct_1 = largestruct_2"
>Fix:
I correct the problem by using my own function that implements the functionality of memcpy.

>Release-Note:
>Audit-Trail:
>Unformatted:


             reply	other threads:[~2001-06-21  8:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-06-21  8:16 dorian.araneda [this message]
2001-06-21 12:56 Alexandre Oliva
2001-06-21 12:56 Araneda, Dorian
2002-04-02  2:09 rth

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=20010621150810.31468.qmail@sourceware.cygnus.com \
    --to=dorian.araneda@intel.com \
    --cc=gcc-gnats@gcc.gnu.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).