[squeak-dev] news from the Xtream front

Eliot Miranda eliot.miranda at gmail.com
Tue Dec 8 20:20:25 UTC 2009


On Tue, Dec 8, 2009 at 12:05 PM, Eliot Miranda <eliot.miranda at gmail.com>wrote:

> On Tue, Dec 8, 2009 at 9:35 AM, Eliot Miranda <eliot.miranda at gmail.com>wrote:
>
>>
>>
>> 2009/12/8 Levente Uzonyi <leves at elte.hu>
>>
>>> On Tue, 8 Dec 2009, Nicolas Cellier wrote:
>>>
>>>
>>>> Oh yes, like this ?
>>>>
>>>> | file |
>>>> [file := MultiByteFileStream newFileNamed: 'mbfs_skip.tst'.
>>>> file ascii; wantsLineEndConversion: false; converter: UTF8TextConverter
>>>> new.
>>>> file nextPutAll: 'Ceci doit changé'.
>>>> file skip: -1. "Oops - grammatically incorrect"
>>>> file nextPutAll: 'er'.
>>>> file close.
>>>>
>>>> file := StandardFileStream oldFileNamed: 'mbfs_skip.tst'.
>>>> file ascii.
>>>> file contentsOfEntireFile.]
>>>>        ensure: [file close.
>>>>                FileDirectory default deleteFileNamed: 'mbfs_skip.tst'].
>>>> -> 'Ceci doit chang?er' "Oops squeakly incorrect"
>>>>
>>>>
>>>> Ah Ah, MultiByteFileStream let us see a stream of encoded characters,
>>>> but position over a stream of bytes...
>>>> The only programmer choice is to put marks (by inquiring aMBFS
>>>> position) and restore position using these marks...
>>>>
>>>>
>>> Well, this part is broken, but the current fileIn/fileOut code relies on
>>> this bug/"feature", otherwise it would be easy to fix it in the utf8 case.
>>> Actually I was thinking about CompiledMethod >> #getPreambleFrom:at: or
>>> even worse PositionableStream >> #backChunk.
>>>
>>
>> On a tangental note one can save significant time by having
>> StandardSourceFilesArray cache read-only copies instead of creating new ones
>> all the time.  Find a change set attached that we use at Teleplace.  You
>> might find more places to use this than I have.
>>
>
>   Henrik Johansen to me
>  show details 11:42 AM (20 minutes ago)
>   >>On a tangental note one can save significant time by having
> StandardSourceFilesArray cache read-only copies instead of creating new ones
> all the time.  Find a change set attached that we >>use  at Teleplace.  You
> might find more places to use this than I have.
>
> I'm not subscribed to SqueakDev, but here's one worthwhile addition:
>
>
>
>
> Benchies:
> [CompiledMethod allInstances collect: [:each | each getSource] ] timeToRun
>
>
> With caching: 17344
> Without caching:  25721
>
> Cheers,
> Henry
>

but beware...

On Tue, Dec 8, 2009 at 12:09 PM, Henrik Johansen <
henrik.s.johansen at veloxit.no> wrote:

> [snip]
>
> I just noticed that for some reason, it seems to screw up accepting new
> versions of old methods...
>
> Need more time to check out why, yay.
>


>
>
>  Making something simple out of current MultiByteFileStream mess is a
>>>> challenge I don't even want to take, but you seem a but tougher than
>>>> me.
>>>>
>>>>
>>> I think the current performance of MultiByteFileStream is acceptable for
>>> general use. According to my measurements the greatest bottleneck is
>>> WriteStream >> #nextPut: for typical operations.
>>>
>>>
>>> Levente
>>>
>>>
>>>  Cheers
>>>>
>>>> Nicolas
>>>>
>>>>
>>>>> Levente
>>>>>
>>>>>  Cheers
>>>>>>
>>>>>> Nicolas
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>
>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20091208/f48892f9/attachment.htm


More information about the Squeak-dev mailing list