• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Coreaudio-api Digest, Vol 6, Issue 71
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Coreaudio-api Digest, Vol 6, Issue 71


  • Subject: Re: Coreaudio-api Digest, Vol 6, Issue 71
  • From: Ian Ollmann <email@hidden>
  • Date: Fri, 13 Feb 2009 13:33:33 -0800


On Feb 13, 2009, at 12:04 PM, email@hidden wrote:


From: Joel Reymont <email@hidden>

Someone mentioned in the archives that doing fixed-point math directly
will quickly out-weight the hit of converting an array of samples to
float.

The real problem is that while the integer and floating point units work very quickly on their own, bouncing data back and forth between the VFP unit and the integer unit is exceptionally expensive. It takes a fairly thorough understanding of ISA and ABI to know when these transitions occur. If you aren't ready to dive into (reading) assembly to double check your assumptions, a good first level rule of thumb is to use floating point if your data is in floating point. Otherwise leave it in the integer units. It is possible to make code that bounces back and forth work efficiently if the data is sent through memory and you have enough data to cover the latency, but that requires some intellectual investment to get right.


Unfortunately, doing a floating point compare requires that the compare result be sent back to the integer domain to be used, and so qualifies as one of the expensive data movement between units.

Note that float doesn't have enough precision to faithfully represent 8.24 data.

Ian
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Prev by Date: Re: How to select channel on multi-channel output device
  • Next by Date: iphone: saving power when there's no audio to output
  • Previous by thread: Re: high-performance iphone and 8.24: convert to float and back or fixed-point math?
  • Next by thread: iphone: saving power when there's no audio to output
  • Index(es):
    • Date
    • Thread