Re: Auto-vectorization speeds up multiplication of large-precision numerics
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: Amit Khandekar <amitdkhan.pg@gmail.com>,
PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2020-07-10T13:32:10Z
Lists: pgsql-hackers
Peter Eisentraut <peter.eisentraut@2ndquadrant.com> writes: > We normally don't compile with -O3, so very few users would get the > benefit of this. Yeah. I don't think changing that baseline globally would be a wise move. > We have CFLAGS_VECTOR for the checksum code. I > suppose if we are making the numeric code vectorizable as well, we > should apply this there also. > I think we need a bit of a policy decision from the group here. I'd vote in favor of applying CFLAGS_VECTOR to specific source files that can benefit. We already have experience with that and we've not detected any destabilization potential. (I've not looked at this patch, so don't take this as a +1 for this specific patch.) regards, tom lane
Commits
-
Use plain memset() in numeric.c, not MemSet and friends.
- 3438c988fd75 14.0 landed
-
Frob numeric.c loop so that clang will auto-vectorize it too.
- 9c79e646c6f0 14.0 landed
-
Apply auto-vectorization to the inner loop of numeric multiplication.
- 88709176236c 14.0 landed
-
Split Makefile symbol CFLAGS_VECTOR into two symbols.
- 695de5d1eda6 14.0 landed