[LINUX] XBMC for Linux port to ARM architecture CPU and SoC chips? - Printable Version
+- XBMC Community Forum (http://forum.xbmc.org)
+-- Forum: Development (/forumdisplay.php?fid=32)
+--- Forum: Feature Suggestions (/forumdisplay.php?fid=9)
+--- Thread: [LINUX] XBMC for Linux port to ARM architecture CPU and SoC chips? (/showthread.php?tid=35139)
- jefrey99 - 2010-03-26 19:19
thinking of re-designing my approach using your scratchbox method and using my custom kernel and file system built with Freescale's Linux Target Image Builder (LTIB). Right now I have a boot time of 4 seconds which is much faster then ~30-40 seconds with Ubuntu.
I am still getting my environment setup per your instructions (currently hung up on /arm-scripts/install-pkgs.sh ) It can't seem to be able to download all of the packages yet
One thing that I did notice is that the compiler selected in the documentation (cs2007q1) does not support the ARMv7 architecture which is on the Cortex-A8. Therefor it does not support the NEON co-processor nor does it fully support VFPv3 which is on the Cortex-A8. some of the math operations will be executed by software as VFPv2 is not completely IEEE754 compliant in hardware. VFPv3 is fully IEEE754 compliant in hardware (but unfortunately not pipelined) but the compiler needs to be aware of it's existence.
NEON will provide another huge performance boost to XBMC with it's SIMD capabilities but again the compiler needs to be aware of it. GCC 4.3.3 or better needs to be used which means cs2008q3 or later and apparently scratchbox-toolchain-arm-linux-cs2009q3-67 exists which should do the job.
here are the CFLAGS that I usually use for the Cortex-A8, I have seen a 3-4x performance improvement using these over ARMv6 flags
CFLAGS="-O3 -march=armv7-a -mtune=cortex-a8 -mcpu=cortex-a8 -mfloat-abi=softfp -mfpu=neon -ftree-vectorize -fomit-frame-pointer -ffast-math"
I'm still working through the issues and I'm sure that I will need your help soon.
- McGeagh - 2010-03-26 19:51
the install pkg script is a dumb script that just tries to download packages from a hardcoded list of package urls...these links may be broken... simply change them in the pkgs.txt file with the new link and it will download.
Also, the documentation is not really up to date, so a few things may be wrong/incomplete, and hence the outdated compiler version.
there are a few additional cflags you have that i dont, so may give that a go at a later date (currently trying to optimise the gpu, not cpu, as its the bottleneck on the beagleboard)
Thanks for your input!
- jefrey99 - 2010-03-27 00:06
Where did you document the removal of libswscale from the build? If it is not documented please tell me how you did it?
I see the option --enable-swscale in the "build_xbmc.sh" scrip at xbmc_on_arm/xbmc/cores/dvdplayer/Codecs/ffmpeg/
is this something that can be disabled at the ./configure line or do we have to do something less elegant?
- davilla - 2010-03-28 22:49
Similar problem as IsaacZhang but only with shaders.
The debug log for shader compile is empty so no help there.
- McGeagh - 2010-03-30 15:54
im not removing libswscale, im simply not using the arm (or any) optimised version, i.e fallback software version.
It may not be documented anywhere other than as an svn comment... Please check the makefile.in in the dvdplayer folder for the exact change i did.
- djhalmy - 2010-03-30 19:30
I obtain the same error as davilla but the macros GL_vendor/renderer/version/Extension returns NULL and i don't Know why.
If fact if I run a small example whit only basic functions (i.e. only eglGetDisplays(), eglInitialized(), eglCreateWindiwSurface(), eglCreateContext and eglMakeCurrent,) the macros GL_vendor/renderer//version/Extension are OK.
Other strange thing for me is that functions such as eglCreateWindiwSurface(), eglCreateContext() and eglMakeCurrent() ,only are called from WinSystemEGL.cpp::RefreshEGLContext() but when I run xbmc (by first time) this functions are not runned and the context egl is not created and for that GL_vendor/version/renderer/Extension returns NULL.
Could be my problem related to SDL functions? Mcgeagh had obtained some problems with SDL using SDK 3.01.00.02. Does SDL create the initial window surface?
My xbmc.log is:
I woud like to know what is your opinion. Thanks
- davilla - 2010-03-31 03:27
davilla Wrote:Similar problem as IsaacZhang but only with shaders.
Quote:230 if ((m_SDLSurface = SDL_SetVideoMode(m_nWidth, m_nHeight, 0, options)))
m_SDLSurface returned is zero. So something wrong with SDL and OpenGL/ES
- djhalmy - 2010-03-31 16:43
I have got to run xbmc in the bealeboard at the end but i had to remove an option of one function.
In the file WinSystemEGL.cpp in CWinSystemEGL::SetFullScreen (......) I had to change :
i.e. i had to remove the option SDL_OPENGL in order to run xbmc.
Somebody understands, why doesn't xbmc work with SDL_OPENGL option or what are the consequences if I don't use that option??
- McGeagh - 2010-04-01 19:01
its not needed really. Which means you can also remove all the SDL_GL_SetAttrib calls too.
Should work without it (my testapp does atleast).
I just did a blanket convert from GL to ES code, regardless of whether certain lines were still needed lol.
Cant we get rid of SDL entirely? its such a pain!
- davilla - 2010-04-01 19:23
McGeagh Wrote:its not needed really. Which means you can also remove all the SDL_GL_SetAttrib calls too.
How are you setting up m_eglWindow/m_wmWindow ? Right now this comes from SDL_GetWMInfo (info.info.x11.window/info.info.x11.wmwindow) and without getting m_SDLSurface back from SDL_SetVideoMode, these are null.
We would need an X11 event handler that translates X11 events into XBMC events. I've got a similar bug up my ass about SDL under OSX as OSX is event driven and SDL does a poll for events. One thought is to make an simple event handler that translates X11 events and uses the eventclient model to send events via tcp/ip loopback. Cursor handling is another issue.