lua-users home
lua-l archive

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


> 2)
> The file *lopcodes.h* from Lua@Github (as of Jan 30 2019) contains
> descriptions of VM instructions in comments.
> Some descriptions don't agree with the implementation of these
> instructions.
> 
> (first line is "currently is:", second line is "should be:")
> 
> OP_SHRI,/* A B C   R(A) := R(B) >> C */
> OP_SHRI,/* A B sC  R(A) := R(B) >> C */
> 
> OP_SHLI,/* A B C   R(A) := C << R(B) */
> OP_SHLI,/* A B sC  R(A) := C << R(B) */
> 
> OP_TESTSET,/* A B   if (not R(B) == k) then R(A) := R(B) else pc++ */
> OP_TESTSET,/* A B   if (not R(B) ~= k) then R(A) := R(B) else pc++ */

Thanks for the feedback.

-- Roberto