OK i've done as Mathieu suggested and used the '-maxsize' to increase the capacity of the array to 1e+009. I have no idea what this means but the patch works so i'm not too bothered for now. Thanks for all the replies gentlemen.
Le 2011-10-21 à 19:05:00, Daniel Embleton a écrit :
OK i've done as Mathieu suggested and used the '-maxsize' to increase the capacity of the array to 1e+009. I have no idea what this means but the patch works so i'm not too bothered for now. Thanks for all the replies gentlemen.
1e+9 (with or without any zeroes after the +) means 1 multiplied 9 times by 10. that's 1*10*10*10*10*10*10*10*10*10 = 1000000000, which is what traditionally the americans call a «billion», the brits call a «thousand million» and the french call a «milliard», and the scientists call a «giga»... or a 1e+9.
You can't put much bigger numbers in there because of the overflow. In 32-bit mode, maxsize has a maximum value a bit above 2.1e+9, but [soundfiler] does not check directly for this condition... it's an unreported bug.
| Mathieu BOUCHARD ----- téléphone : +1.514.383.3801 ----- Montréal, QC
On Oct 21, 2011, at 3:27 PM, Mathieu Bouchard wrote:
Le 2011-10-21 à 19:05:00, Daniel Embleton a écrit :
OK i've done as Mathieu suggested and used the '-maxsize' to
increase the capacity of the array to 1e+009. I have no idea what
this means but the patch works so i'm not too bothered for now.
Thanks for all the replies gentlemen.1e+9 (with or without any zeroes after the +) means 1 multiplied 9
times by 10. that's 1*10*10*10*10*10*10*10*10*10 = 1000000000, which
is what traditionally the americans call a «billion», the brits call
a «thousand million» and the french call a «milliard», and the
scientists call a «giga»... or a 1e+9.You can't put much bigger numbers in there because of the overflow.
In 32-bit mode, maxsize has a maximum value a bit above 2.1e+9, but
[soundfiler] does not check directly for this condition... it's an
unreported bug.
You could report it...
.hc
Man has survived hitherto because he was too ignorant to know how to
realize his wishes. Now that he can realize them, he must either
change them, or perish. -William Carlos Williams
what I also do is to send the file name to iemlib/soundfile_info, which
gives out the file size (for wav files). then I send that value as an
argument to -maxsize, and I don't have to worry about how big the sound
file is. (except for Mathieu's error, which I hadn't heard about before)
OK i've done as Mathieu suggested and used the '-maxsize' to increase the capacity of the array to 1e+009. I have no idea what this means but the patch works so i'm not too bothered for now. Thanks for all the replies gentlemen.
That sounds like a good idea, think i'll try to implement that one. Thanks.
To: pd-list@iem.at; crumbly.bwfc@hotmail.co.uk Subject: Re: [PD] Array Size limits Date: Mon, 24 Oct 2011 12:57:22 +0200 From: jmmmpais@googlemail.com
what I also do is to send the file name to iemlib/soundfile_info, which
gives out the file size (for wav files). then I send that value as an
argument to -maxsize, and I don't have to worry about how big the sound
file is. (except for Mathieu's error, which I hadn't heard about before)OK i've done as Mathieu suggested and used the '-maxsize' to increase the capacity of the array to 1e+009. I have no idea what this means but the patch works so i'm not too bothered for now. Thanks for all the replies gentlemen.
-- Friedenstr. 58 10249 Berlin (Deutschland) Tel +49 30 42020091 | Mob +49 162 6843570 Studio +49 30 69509190 jmmmpais@googlemail.com | skype: jmmmpjmmmp
Le 2011-10-24 à 12:57:00, João Pais a écrit :
what I also do is to send the file name to iemlib/soundfile_info, which gives out the file size (for wav files). then I send that value as an argument to -maxsize, and I don't have to worry about how big the sound file is. (except for Mathieu's error, which I hadn't heard about before)
AFAIK (by reading source, not by trying) :
-maxsize between 2GB and 4GB will cause pd to take the size as a negative value, which it will replace by 0, and thus won't load the file.
-maxsize between 4GB and 6GB will pretend that the size is 4GB less than what you specified.
-maxsize between 6GB and 8GB will give a negative value again.
-maxsize between 4GB and 6GB will pretend that the size is 8GB less than what you specified.
and so on.
This problem also would happen in 64-bit mode.
Someone with a bigger RAM and bigger soundfile could confirm it.
Just like most other bugs about overflow, the changes happen at binary GB boundaries : multiples of 1024*1024*1024 bytes, and not multiples of 1000*1000*1000.
| Mathieu BOUCHARD ----- téléphone : +1.514.383.3801 ----- Montréal, QC
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 2011-10-24 16:24, Mathieu Bouchard wrote:
-maxsize between 4GB and 6GB will pretend that the size is 4GB less than what you specified.
[...]
-maxsize between 4GB and 6GB will pretend that the size is 8GB less than what you specified.
hein?
fgmasdr IOhannes
Le 2011-10-24 à 17:58:00, IOhannes m zmoelnig a écrit :
On 2011-10-24 16:24, Mathieu Bouchard wrote:
-maxsize between 4GB and 6GB will pretend that the size is 4GB less than what you specified.
[...]
-maxsize between 4GB and 6GB will pretend that the size is 8GB less than what you specified.
hein?
A big sorry... although I got the overall point right, I made FOUR mistakes in the mail :
the latter part. Basically, I just meant wrapping around at 2GB, and crossing zero at 4GB... a signed modulo pow(2,32).
in that case, there is no problem with crossing the 2GB limit.
not at all the same as when casting from a big int type to a smaller int type. When I cast from float to a 32-bit int, any overflow gives -2147483648 instead of wrapping around.
the «usage» message and refuses to do work. I had already verified this a few days ago and forgot it.
In any case, there is still the problem that if the user does -maxsize 1e+10 on a 32-bit platform, there's nothing that tells him what's wrong. The user just gets an uninformative error message that implies (without actually stating) that something in the syntax is wrong.
| Mathieu BOUCHARD ----- téléphone : +1.514.383.3801 ----- Montréal, QC