[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RISU PATCH v3 05/18] risugen_x86_memory: add module
From: |
Jan Bobek |
Subject: |
Re: [Qemu-devel] [RISU PATCH v3 05/18] risugen_x86_memory: add module |
Date: |
Mon, 22 Jul 2019 09:53:36 -0400 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 |
On 7/20/19 9:58 PM, Richard Henderson wrote:
> On 7/11/19 3:32 PM, Jan Bobek wrote:
>> +sub load(%)
>> +{
>> + my (%args) = @_;
>> +
>> + @memory_opts{keys %args} = values %args;
>> + $memory_opts{is_write} = 0;
>> +}
>> +
>> +sub store(%)
>> +{
>> + my (%args) = @_;
>> +
>> + @memory_opts{keys %args} = values %args;
>> + $memory_opts{is_write} = 1;
>> +}
>
> I was thinking maybe we should add a mem() that allows a "store => $d", which
> would simplify the "$d ? store(size => x) : load(size => x)" pattern.
>
> Anyway, that's incremental improvement.
It's possible. I suppose the reason why I did it like I did was that I
wanted the config file to be more descriptive: if you specify a
constraint like mem(store => 0, ...), it might not be immediately
clear that it actually means a load. It's not an issue when you know
the code, but if somebody were just browsing the x86.risu without
prior knowledge of anything, they might find it more cryptic.
Anyway, so much for my reasoning; I agree that it would make the
conditions simpler, so feel free to change it if you like.
-Jan
signature.asc
Description: OpenPGP digital signature
- [Qemu-devel] [RISU PATCH v3 16/18] x86.risu: add AES and PCLMULQDQ instructions, (continued)
- [Qemu-devel] [RISU PATCH v3 16/18] x86.risu: add AES and PCLMULQDQ instructions, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 08/18] risugen: add command-line flag --x86_64, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 10/18] x86.risu: add MMX instructions, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 06/18] risugen_x86: add module, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 05/18] risugen_x86_memory: add module, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 11/18] x86.risu: add SSE instructions, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 01/18] risugen_common: add helper functions insnv, randint, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 07/18] risugen: allow all byte-aligned instructions, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 02/18] risugen_common: split eval_with_fields into extract_fields and eval_block, Jan Bobek, 2019/07/11
- [Qemu-devel] [RISU PATCH v3 04/18] risugen_x86_constraints: add module, Jan Bobek, 2019/07/11