From: jlh <jlh@gmx.ch>
To: Dario Bahena Tapia <dario.mx@gmail.com>, gcc-help@gcc.gnu.org
Subject: Re: Why worse performace in euclidean distance with SSE2?
Date: Mon, 07 Apr 2008 16:05:00 -0000 [thread overview]
Message-ID: <47FA3C65.6020701@gmx.ch> (raw)
In-Reply-To: <3d104d6f0804070617u47213cc8nbc697dab9dc262b5@mail.gmail.com>
Dario Bahena Tapia wrote:
> inline static double dist(int i,int j)
> {
> double xd = C[i][X] - C[j][X];
> double yd = C[i][Y] - C[j][Y];
> return rint(sqrt(xd*xd + yd*yd));
> }
> [...]
> And in order to activate the SSE2 features, I am using the following
> flags for gcc (my computer is a laptop):
>
> CFLAGS = -O -Wall -march=pentium-m -msse2
These options do not make dist() use any SSE for me. Have you
tried compiling with this?
CFLAGS = -O2 -Wall -march=pentium-m -mfpmath=sse
I think -msse2 is redundant if you say -march-pentium-m. I don't
have an SSE2 machine to try this though.
jlh
next prev parent reply other threads:[~2008-04-07 15:23 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-07 14:09 Dario Bahena Tapia
2008-04-07 15:23 ` Dario Saccavino
2008-04-07 16:09 ` Dario Bahena Tapia
2008-04-07 16:41 ` Dario Bahena Tapia
2008-04-07 16:05 ` jlh [this message]
2008-04-07 17:02 ` Dario Bahena Tapia
2008-04-07 23:42 ` Brian Budge
2008-04-08 2:15 ` Dario Bahena Tapia
2008-04-08 8:34 ` Zuxy Meng
2008-04-08 15:57 ` Dario Bahena Tapia
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=47FA3C65.6020701@gmx.ch \
--to=jlh@gmx.ch \
--cc=dario.mx@gmail.com \
--cc=gcc-help@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).