All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paolo Minazzi <Paolo.Minazzi@mitrol.it>
To: xenomai@xenomai.org
Subject: Re: [Xenomai] arm imx6 and hardware FPU
Date: Fri, 11 Apr 2014 14:15:08 +0200	[thread overview]
Message-ID: <5347DCCC.3040801@mitrol.it> (raw)
In-Reply-To: <5347D6E0.2030805@xenomai.org>

Il 11/04/2014 13.49, Gilles Chanteperdrix ha scritto:
> On 04/11/2014 01:44 PM, Paolo Minazzi wrote:
>> Hi to all,
>> I'm trying to test my imx6 with xenomai 2.6.3.
>> I use the linaro cross-compiler that uses the hardware floating point.
>>
>> I made a simple floating point test.
>>
>> If I use two non-realtime user-space tasks the test works OK and I have
>> no errors in calculations.
>> This means that compiler and hardware works well.
>>
>> But I I use two realtime user-space tasks I have errors in calculations.
>> Real-time tasks are created with rt_task_create(&demo, "demo", 0, 99,
>> T_FPU);
>>
>>
>> This is my kernel config
>> ============================================
>> ...
>> #
>> # Machine
>> #
>> CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH=y
>> CONFIG_IPIPE_WANT_ACTIVE_MM=y
>> CONFIG_XENO_HW_FPU=y
>> CONFIG_XENO_HW_UNLOCKED_SWITCH=y
>> ...
>> #
>> # At least one emulation must be selected
>> #
>> CONFIG_VFP=y
>> CONFIG_VFPv3=y
>> CONFIG_NEON=y
>> CONFIG_VFP_3_2_BACKPORT=y
>> ...
>> ============================================
>>
>> Is it possible to use ***hardware floating point*** with realtime
>> user-space tasks ?
>
> Yes, it should be. Do you get the same issue when running both the 
> switchtest and switchtest -s 1000 tests? Do you have the same issue 
> with the I-pipe patch for Linux 3.8?
>
>
/ # ./switchtest -s 1000
== Testing FPU check routines...
d0: 1 != 2
d1: 1 != 2
d2: 1 != 2
d3: 1 != 2
d4: 1 != 2
d5: 1 != 2
d6: 1 != 2
d7: 1 != 2
d8: 1 != 2
d9: 1 != 2
d10: 1 != 2
d11: 1 != 2
d12: 1 != 2
d13: 1 != 2
d14: 1 != 2
d15: 1 != 2
== FPU check routines: OK.

/ # ./switchtest
== Testing FPU check routines...
d0: 1 != 2
d1: 1 != 2
d2: 1 != 2
d3: 1 != 2
d4: 1 != 2
d5: 1 != 2
d6: 1 != 2
d7: 1 != 2
d8: 1 != 2
d9: 1 != 2
d10: 1 != 2
d11: 1 != 2
d12: 1 != 2
d13: 1 != 2
d14: 1 != 2
d15: 1 != 2
== FPU check routines: OK.

As you can see the test seems OK.
But If I understand correctly switchtest is not a real-time test.

I see the problem If I use my floating point test.
I try to calculate sin(2x).
Then I claculate 2*sin(x)*cos(x).
They should be similar. But sometime they are very different ===> fpu error


I have kerne 3.0.35.
For me it is not so easy try 3.8.

Paolo



  reply	other threads:[~2014-04-11 12:15 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-11 11:44 [Xenomai] arm imx6 and hardware FPU Paolo Minazzi
2014-04-11 11:49 ` Gilles Chanteperdrix
2014-04-11 12:15   ` Paolo Minazzi [this message]
2014-04-11 12:24     ` Gilles Chanteperdrix
     [not found]       ` <5347E0E1.3020807@mitrol.it>
     [not found]         ` <5347E3DA.6010106@xenomai.org>
     [not found]           ` <5347E8AB.7020908@mitrol.it>
     [not found]             ` <5347EB00.7060203@xenomai.org>
2014-04-17 12:20               ` Paolo Minazzi
2014-04-17 13:33                 ` Gilles Chanteperdrix
2014-04-18  8:47                   ` [Xenomai] arm imx6 and hardware FPU [SOLVED] Paolo Minazzi
     [not found]                     ` <5350E9C7.7010904@optusnet.com.au>
2014-04-18  9:38                       ` Paolo Minazzi

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=5347DCCC.3040801@mitrol.it \
    --to=paolo.minazzi@mitrol.it \
    --cc=xenomai@xenomai.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.