Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-05-06 Thread erifan
On Thu, 1 May 2025 07:32:22 GMT, erifan wrote: >> Yes, this discussion is down to `requires` vs `applyIf`. This is my argument >> for `applyIf`, quoted from above, I have not yet seen an argument against it: >> >>> If you use @require, then the person does not realize there is a test AND >>>

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-05-01 Thread erifan
On Tue, 29 Apr 2025 10:22:22 GMT, Emanuel Peter wrote: >> erifan has updated the pull request with a new target base due to a merge or >> a rebase. The incremental webrev excludes the unrelated changes brought in >> by the merge/rebase. The pull request contains four additional commits since >

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-29 Thread erifan
On Tue, 29 Apr 2025 10:22:22 GMT, Emanuel Peter wrote: > Yes, this discussion is down to `requires` vs `applyIf`. This is my argument > for `applyIf`, quoted from above, I have not yet seen an argument against it: > > > If you use @require, then the person does not realize there is a test AND

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-29 Thread Emanuel Peter
On Fri, 25 Apr 2025 07:24:15 GMT, erifan wrote: >> This patch optimizes the following patterns: >> For integer types: >> >> (XorV (VectorMaskCmp src1 src2 cond) (Replicate -1)) >> => (VectorMaskCmp src1 src2 ncond) >> (XorVMask (VectorMaskCmp src1 src2 cond) (MaskAll m1)) >> => (VectorMa

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread erifan
On Mon, 28 Apr 2025 14:13:43 GMT, Emanuel Peter wrote: > > > > > Just a drive-by comment for now, I may review this later more fully. > > > > > > I would also prefer if you added the IR restrictions rather than > > > > > > the JTREG requires. > > > > > > The benefit is that we can still run the

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread erifan
On Mon, 28 Apr 2025 14:10:40 GMT, Emanuel Peter wrote: >> test/hotspot/jtreg/compiler/vectorapi/VectorMaskCompareNotTest.java line 237: >> >>> 235: public static void testCompareEQMaskNotByte() { >>> 236: testCompareMaskNotByte(VectorOperators.EQ); >>> 237: } >> >> Another comme

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread Emanuel Peter
On Mon, 28 Apr 2025 14:06:49 GMT, Emanuel Peter wrote: >> erifan has updated the pull request with a new target base due to a merge or >> a rebase. The incremental webrev excludes the unrelated changes brought in >> by the merge/rebase. The pull request contains four additional commits since >

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread Emanuel Peter
On Mon, 28 Apr 2025 09:51:10 GMT, erifan wrote: > > > > Just a drive-by comment for now, I may review this later more fully. > > > > > I would also prefer if you added the IR restrictions rather than the > > > > > JTREG requires. > > > > > The benefit is that we can still run the tests on all pl

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread Emanuel Peter
On Fri, 25 Apr 2025 07:24:15 GMT, erifan wrote: >> This patch optimizes the following patterns: >> For integer types: >> >> (XorV (VectorMaskCmp src1 src2 cond) (Replicate -1)) >> => (VectorMaskCmp src1 src2 ncond) >> (XorVMask (VectorMaskCmp src1 src2 cond) (MaskAll m1)) >> => (VectorMa

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread erifan
On Mon, 28 Apr 2025 09:17:58 GMT, Emanuel Peter wrote: > > > Just a drive-by comment for now, I may review this later more fully. > > > > I would also prefer if you added the IR restrictions rather than the > > > > JTREG requires. > > > > The benefit is that we can still run the tests on all pla

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread Emanuel Peter
On Mon, 28 Apr 2025 07:48:58 GMT, erifan wrote: > > Just a drive-by comment for now, I may review this later more fully. > > > I would also prefer if you added the IR restrictions rather than the > > > JTREG requires. > > > The benefit is that we can still run the tests on all platforms, at leas

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-28 Thread erifan
On Mon, 28 Apr 2025 06:47:38 GMT, Emanuel Peter wrote: > Just a drive-by comment for now, I may review this later more fully. > > > I would also prefer if you added the IR restrictions rather than the JTREG > > requires. > > The benefit is that we can still run the tests on all platforms, at le

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-27 Thread Emanuel Peter
On Fri, 25 Apr 2025 07:24:15 GMT, erifan wrote: >> This patch optimizes the following patterns: >> For integer types: >> >> (XorV (VectorMaskCmp src1 src2 cond) (Replicate -1)) >> => (VectorMaskCmp src1 src2 ncond) >> (XorVMask (VectorMaskCmp src1 src2 cond) (MaskAll m1)) >> => (VectorMa

Re: RFR: 8354242: VectorAPI: combine vector not operation with compare [v3]

2025-04-25 Thread erifan
> This patch optimizes the following patterns: > For integer types: > > (XorV (VectorMaskCmp src1 src2 cond) (Replicate -1)) > => (VectorMaskCmp src1 src2 ncond) > (XorVMask (VectorMaskCmp src1 src2 cond) (MaskAll m1)) > => (VectorMaskCmp src1 src2 ncond) > > cond can be eq, ne, le, ge, l