qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RISU RFC PATCH v2 03/14] risugen_x86_emit: add module


From: Jan Bobek
Subject: Re: [Qemu-devel] [RISU RFC PATCH v2 03/14] risugen_x86_emit: add module
Date: Wed, 10 Jul 2019 14:08:47 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1

On 7/3/19 11:47 AM, Richard Henderson wrote:
> On 7/1/19 6:35 AM, Jan Bobek wrote:
>> +sub parse_emitblock($$)
>> +{
>> +    my ($rec, $insn) = @_;
>> +    my $insnname = $rec->{name};
>> +    my $opcode = $insn->{opcode}{value};
>> +
>> +    $emit_opts = {};
>> +
>> +    my $emitblock = $rec->{blocks}{"emit"};
>> +    if (defined $emitblock) {
>> +        eval_with_fields($insnname, $opcode, $rec, "emit", $emitblock);
>> +    }
> 
> And if !defined?  Silently discard?
> 
> Is this just weirdness higher in the risugen stack,
> such that this might be called maybe_parse_emitblock?

If !defined, there _is_ no emit block, and we treat that as an empty
block. The caller gets an empty hash, and it's up to them to decide
what that means. I could rename it, but the difference doesn't seem
that important to me...?

-Jan

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]