From: Richard Henderson <richard.henderson@linaro.org>
To: Nick Renieris <makren67@gmail.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] AVX support for TCG
Date: Sun, 30 Dec 2018 07:24:23 +1100 [thread overview]
Message-ID: <aeeb8c50-0293-e37b-9f9f-5d392b7e10f6@linaro.org> (raw)
In-Reply-To: <CAObpvQmejWBh+RNz2vhk16-kcY_QveM_pSmM5ZeWqWv1d8AJzQ@mail.gmail.com>
On 12/29/18 12:43 AM, Nick Renieris wrote:
>>> Do you think this could work as a GSoC project? I'm potentially
>>> interested in working on it this summer.
>
>> Could be. My first guess is something like 4 months work for this.
>
> Four months full-time? If so I would say it's not viable for a GSoC
> project (it's 3 months), I've done the 12-hours-a-day-crunch thing for
> a week or so in GSoC 2017 and it was _not_ fun.
> Also, I hope you meant four months for me, not for you - I'm
> completely new to the QEMU codebase. I expect it will take me weeks
> just to understand x86's 'translate.c' (who thought it'd be a good
> idea to put all this stuff in _one_ file?).
I did have a beginner in mind when guessing 4 months. Don't take that as a
fully speced out answer, but it may well be that full avx2 support cannot be
done within the 3 months of gsoc. I would certainly expect avx512 to take even
longer.
> Another question, are there existing discussions about this
> refactoring effort or specifically AVX? I asked a similar question on
> IRC a few days ago and got no answers.
Not that I recall. I have some code at
https://github.com/rth7680/qemu/commits/i386-avx
that attempts to remove the sse_op_table(s). However, it also splits up the
sse operations into units of uint64_t. Which seemed sort of reasonable at the
time, considering that a lot of sse is 2*mmx.
But in the intervening 2.5 years since I worked on that branch, we have learned
that calls to helpers dominate. It's better to have a single call that does 4x
the work than 4 separate calls.
The tcg-op-gvec.h infrastructure allows for the different modes that avx+mmx
allows:
(1) 64-bit operations,
(2) 128-bit operations, modifying only the low 128 bits,
(3) 128-bit operations, zeroing bits beyond the first 128,
(4) N*128-bit operations, zeroing bits beyond the first N*128.
so we should not need a great proliferation of helper functions, merely a
re-organization of what we have now.
r~
next prev parent reply other threads:[~2018-12-29 20:27 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-25 23:43 [Qemu-devel] AVX support for TCG Nick Renieris
2018-12-26 1:07 ` Richard Henderson
2018-12-26 1:28 ` Nick Renieris
2018-12-26 2:12 ` Richard Henderson
2018-12-28 13:43 ` Nick Renieris
2018-12-28 14:13 ` Peter Maydell
2018-12-28 14:28 ` Nick Renieris
2018-12-28 14:38 ` Peter Maydell
2018-12-28 17:19 ` Nick Renieris
2018-12-28 21:15 ` Alex Bennée
2018-12-29 20:24 ` Richard Henderson [this message]
2018-12-30 20:51 ` Nick Renieris
2018-12-31 1:58 ` Richard Henderson
2019-01-04 21:43 ` Nick Renieris
2019-01-04 21:51 ` Richard Henderson
2019-01-04 22:09 ` Nick Renieris
2019-01-04 22:14 ` Richard Henderson
2019-01-04 22:33 ` Nick Renieris
2019-01-04 22:38 ` Richard Henderson
2019-01-04 22:42 ` Nick Renieris
2019-01-17 9:29 ` Stefan Hajnoczi
2019-01-17 13:57 ` Nick Renieris
2019-01-18 9:57 ` Stefan Hajnoczi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aeeb8c50-0293-e37b-9f9f-5d392b7e10f6@linaro.org \
--to=richard.henderson@linaro.org \
--cc=makren67@gmail.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).