lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


BTW, this is "until true" :-)
I just rechecked with a simple example (which generates a compiled
trace), the code is the same actually.
Ben


On Wed, Jul 20, 2011 at 7:26 AM, Benjamin Segovia
<segovia.benjamin@gmail.com> wrote:
> Actually, I naturally tried this one before the while true do {...} end
> Same result unfortunately :-)
> Ben
>
>
> On Wed, Jul 20, 2011 at 7:21 AM, David Kastrup <dak@gnu.org> wrote:
>> Benjamin Segovia <segovia.benjamin@gmail.com> writes:
>>
>>> Hello all,
>>> still in the context of asm-from-one-machine to lua translation, I am
>>> facing some difficulties.
>>> For various reasons (mostly because the machine I am simulating is a
>>> SIMD vector machine), I need to handle forward jumps with the idiom:
>>>
>>> while true do
>>> {... a lot of compute ...}
>>> if some_condition_on_the_lane_of_the_simd_vector then break end
>>> {... a lot of compute ...}
>>> break -- this one is to exit anyway
>>> end
>>>
>>> So, basic blocks are handled with these idioms.
>>
>> That's not a nice idiom.  Perhaps
>>
>> repeat
>> ...
>> until false
>>
>> is better recognizable to luajit?  That way the fall-through exit is
>> more conspicuous.  And since it is more idiomatic, chances are better
>> that Mike caters for this...
>>
>> --
>> David Kastrup
>>
>>
>>
>