help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Finding out the optimizations used by Octave


From: Jaroslav Hajek
Subject: Re: Finding out the optimizations used by Octave
Date: Sat, 23 Jan 2010 06:03:07 +0100

On Sat, Jan 23, 2010 at 4:51 AM, George <address@hidden> wrote:
> Is there an Octave command to find which CPU optimizations are in use?

I'm not sure if that's what you mean, but the CPU instruction set used
is usually fixed at the time of compilation. Typically it's the FPU
instructions by default on 32-bit machines, and SSE instructions on
64-bit machines. It also heavily depends on the compiler and flags
used. Some compilers, like Intel C++, can use a runtime dispatch to
different code paths optimized for different platforms (yes and it's
Intel-centric). To find out the compiler and flags used, you can do
(in Octave):

octave:1> octave_config_info ("CXX")
ans = g++
octave:2> octave_config_info ("CXXFLAGS")
ans = -O3 -march=native

this shows that my Octave was compiled with GNU g++, using -O3
-march=native. -O3 means to use the heaviest standard optimizations,
and -march=native allows g++ to fully utilize the instruction set of
the processor. In my case, it's SSSE3 plus anything specific that g++
may want to use. The resulting binary is not portable.


-- 
RNDr. Jaroslav Hajek, PhD
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz


reply via email to

[Prev in Thread] Current Thread [Next in Thread]