Project

General

Profile

Actions

Bug #9314

closed

Undesired behavior of situation('random', :size => 32, :sign_extend => true)

Added by Alexander Kamkin over 5 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Category:
Test Engine
Target version:
Start date:
10/08/2018
Due date:
% Done:

0%

Estimated time:
Detected in build:
svn
Platform:
Published in build:
2.4.44

Description

The following construct generates 32-bit values, not sign-extended 64-bit ones (as it is implied).

    # Generator of 32-bit random values which will be sign-extended to fit the target register.
    random_word = situation('random', :size => 32, :sign_extend => true)

    # Input arguments of all instructions listed below are random words.
    set_default_situation 'add'   do random_word end
    set_default_situation 'addi'  do random_word end
    set_default_situation 'addiu' do random_word end
    set_default_situation 'addu'  do random_word end
    set_default_situation 'sub'   do random_word end
    set_default_situation 'subu'  do random_word end
Actions

Also available in: Atom PDF