[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Alexander Sack
i agree, that in the long run we might need something better; we can
carry that forward upstream when pushing our patch there though. For now
in ubuntu the patch jamie proposed seems fine.

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Jamie Bennett
Attaching .debdiff

** Attachment added: debdiff fix
   http://launchpadlibrarian.net/40482727/fio_1.33.1-1ubuntu1.debdiff

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Dave Martin
OK, fair enough; I hadn't looked at the ifdefs preceding the patch.

Note that ARMv6 is missing: it may be a good idea to add some extra
checks:

#ifdef defined(__ARM_ARCH_4__) || defined(__ARM_ARCH_4T__) || 
defined(__ARM_ARCH_5__) defined(__ARM_ARCH_5T__) || defined(__ARM_ARCH_5TE__) 
|| defined(__ARM_ARCH_5TEJ__) || defined(__ARM_ARCH_6__) || 
defined(__ARM_ARCH_6J__) || defined(__ARM_ARCH_6ZK__) || 
defined(__ARM_ARCH_6T2__)
/* old definitions */
#elif defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_7A__)
   /* new, GCC intrinsics based definitions and native nop instruction */
#endif

Alternatively, the attached mini configure script might be OK instead.
If it looks useful, let me know and I'll add it to the wiki

** Attachment added: mini configure script which might be usable as an 
alternative
   http://launchpadlibrarian.net/40482911/cc_configure

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Dave Martin

** Attachment added: repost with out the random trailing comment
   http://launchpadlibrarian.net/40482956/cc_configure

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Launchpad Bug Tracker
This bug was fixed in the package fio - 1.33.1-1ubuntu1

---
fio (1.33.1-1ubuntu1) lucid; urgency=low

  * arch/arch-arm.h: Fix fail to build issue on ARMv7 and make it SMP
safe (LP: #532722).
 -- Jamie Bennett ja...@linuxuk.org   Thu, 04 Mar 2010 20:38:38 +

** Changed in: fio (Ubuntu)
   Status: New = Fix Released

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Alexander Sack
Dave, i think adding that script to wiki would be helpful. Together with
an example macro that shows how to use it for folks not familiar with m4
etc.

If you could add that jamie would probably be happy to update his patch
to do it that way.

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Jamie Bennett
Added more architecture defines as suggested by Dave Martin.

Fixed fail to build on ia64.

** Attachment added: fio_1.33.1-1ubuntu1.debdiff
   http://launchpadlibrarian.net/40486269/fio_1.33.1-1ubuntu1.debdiff

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Jamie Bennett
Probably going to change this fix for the configure script Dave Martin
suggested, seems the more sensible approach.

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Dave Martin
My configure program Is just a shell script btw: comments at the start
of the script explain how to use it.

Hopefully this is a reasonable approach when a package hasn't moved to a
heavyweight autotools-based flow yet, but I'm open to suggestions...

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Loïc Minier
Some small suggestions on the shell script:
- mktemp /tmp/$me-XX = mktemp -t $me-
- instead of echo -n + final echo, why not just accumulate defines in a string 
which you output?  e.g. DEFINES=, DEFINES=$DEFINES -DFOO and echo CFLAGS 
+= $DEFINES
- you could eval this from make instead of generating an intermediate make, but 
that's a bit harder to read I guess (avoids the chicken and egg between the 
include being missing before it's generated though)
- I personally do the tests directly in make, but you could also consider 
autoconf itself I guess

Thanks!

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


RE: [Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-08 Thread Dave Martin
 Some small suggestions on the shell script:
 - mktemp /tmp/$me-XX = mktemp -t $me-

Hmmm, I learn something every day :)  However, man mktemp says -t is
deprecated.

But mktemp -p /tmp $me- would work equally well.

 - instead of echo -n + final echo, why not just accumulate 
 defines in a string which you output?  e.g. DEFINES=, 
 DEFINES=$DEFINES -DFOO and echo CFLAGS += $DEFINES

Sure, that's a bit nicer.

 - you could eval this from make instead of generating an 
 intermediate make, but that's a bit harder to read I guess 
 (avoids the chicken and egg between the include being missing 
 before it's generated though)

Sure, although the tests will get re-run every time you type make that
way, which might annoy some people.

I am looking into generating some more useful predefines for the information
suppiled by __ARM_ARCH_* --- this is more cumbersome though and really needs
to be a separate script, but it has potential to simplify all the #if
defined(this) || defined(that) || defined(the other) || ... and reduce the
maintenance effort.

 - I personally do the tests directly in make, but you could 
 also consider autoconf itself I guess

Sure.  I'm still too scared of autoconf to set it up from scratch though
:O

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-05 Thread Jamie Bennett
In the process of fixing this for ARMv7 I have added the correct calls
to ensure SMP safety.

** Patch added: fio-1.22.1.patch
   http://launchpadlibrarian.net/40260566/fio-1.22.1.patch

** Tags added: armv7 patch

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-05 Thread Jamie Bennett
Tested on iMX51 ubuntu-netbook form 05/03/10

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-05 Thread Jamie Bennett
Of course that should of read Tested on the iMX51 ubuntu-netbook image
from 05/03/10

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-05 Thread Dave Martin
I have a concern about the proposed patch: if the code is ever built for
an arch  7-a (in the future) the wrong code will silently be built.

Is it not feasible to use configure tests to determine whether
asm(nop) and __sync_* are supported?  This is more future-proof...

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 532722] Re: [armel] fio fails to build with ARMv7 optimizations

2010-03-05 Thread Jamie Bennett
As long as __ARCH_ARM_7A__ isn't defined the build will fail as the
defines will not be declared.

New arch's will have to be added to the file in the future which is how
the packages does it now. We can investigate a better fix if desired.

Note that this package doesn't use configure so we are left with some
kind of Makefile or debian/rules solution.

-- 
[armel] fio fails to build with ARMv7 optimizations
https://bugs.launchpad.net/bugs/532722
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs