LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 12-26-2013, 07:28 PM   #1
taihd
LQ Newbie
 
Registered: Dec 2013
Posts: 1

Rep: Reputation: Disabled
Question Manual Python build cannot beat Ubuntu build???


I'm running ODROID-XU Lite (a SoC development board based on SamSung Exynos 5410 quad-core ARM Cortex A15) on Ubuntu 13.04. I'm trying to build Python 2.7.4 from source to have a much more optimized binary version of Python for Cortex A15, but it can't beat the shipped version of Ubuntu (also Python 2.7.4) in terms of performance. It's completely baffling to me as I understand generally the distro packages should be built in generic ways which has no gcc optimization flags in favor of any specific ARM CPU architecture while my manual build had all gcc optimization flags towards Cortex A15. Yet the Python version coming with Ubuntu is ahead my Python build in unladen-swallow benchmarks by 15% - 20%.

The OS:
Code:
Linux odroid-server 3.4.74 #1 SMP PREEMPT Tue Dec 17 11:45:23 CST 2013 armv7l armv7l armv7l GNU/Linux
My Python build options:
Code:
OPT="-O3 -mcpu=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard -ffast-math" \
./configure --prefix=$INSTALL_DIR
And the unladen-swallow benchmark (http://code.google.com/p/unladen-swa...iki/Benchmarks), 17.55% slower in nqueens benchmark than the shipped Python:
Code:
odroid@odroid-server:/srv/samba/share/odroid/sources/unladen-bmarks$ python
Python 2.7.4 (default, Apr 19 2013, 19:49:55)
[GCC 4.7.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>

$INSTALL_DIR/bin/python
Python 2.7.4 (default, Dec 27 2013, 07:47:24)
[GCC 4.8.3 20131111 (prerelease)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>

odroid@odroid-server:/srv/samba/share/odroid/sources/unladen-bmarks$ python perf.py -r --benchmarks=nqueens \
>   /usr/bin/python \
>   $INSTALL_DIR/bin/python
Running nqueens...
INFO:root:Running /srv/samba/share/odroid/tools/python-2.7.4/bin/python performance/bm_nqueens.py -n 100
INFO:root:Running /usr/bin/python performance/bm_nqueens.py -n 100

Report on Linux odroid-server 3.4.74 #1 SMP PREEMPT Tue Dec 17 11:45:23 CST 2013 armv7l armv7l
Total CPU cores: 1

### nqueens ###
Min: 0.924576 -> 1.085515: 1.1741x slower
Avg: 0.933247 -> 1.097013: 1.1755x slower
Significant (t=-197.757121)
Stddev: 0.00583 -> 0.00588: 1.0076x larger
Timeline: http://tinyurl.com/lpwcwm4
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
SBOPKG(8) not list/show/build dependencies of SlackBuild scripts to build Slackware p xavi_slacky Slackware 3 06-13-2013 07:53 PM
Can't build dev-python/pip flebber Sabayon 0 11-16-2012 02:55 AM
python-kde4-4.6.0 Build Error usef62 Linux From Scratch 0 07-05-2012 02:36 PM
Build ONLY python interpreter tank junior Linux - Newbie 1 12-02-2010 06:09 PM
LXer: Build 'em Right, Build 'em Strong, Build 'em Linux LXer Syndicated Linux News 0 10-01-2007 09:51 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 03:44 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration