mirror of
https://github.com/openjdk/jdk.git
synced 2026-01-28 03:58:21 +00:00
8348678: [PPC64] C2: unaligned vector load/store is ok
8343906: test2 of compiler/c2/TestCastX2NotProcessedIGVN.java fails on some platforms Reviewed-by: mdoerr, amitkumar
This commit is contained in:
parent
41bdc47d71
commit
1a8212e101
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2021, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2021, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -37,10 +37,12 @@
|
||||
return false;
|
||||
}
|
||||
|
||||
// PPC implementation uses VSX load/store instructions (if
|
||||
// SuperwordUseVSX) which support 4 byte but not arbitrary alignment
|
||||
// The PPC implementation uses VSX lxvd2x/stxvd2x instructions (if
|
||||
// SuperwordUseVSX). They do not have alignment requirements.
|
||||
// Some VSX storage access instructions cannot encode arbitrary displacements
|
||||
// (e.g. lxv). None of them is currently used.
|
||||
static constexpr bool misaligned_vectors_ok() {
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
// Whether code generation need accurate ConvI2L types.
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Copyright (c) 1997, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2012, 2024 SAP SE. All rights reserved.
|
||||
* Copyright (c) 2012, 2025 SAP SE. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -131,6 +131,9 @@ void VM_Version::initialize() {
|
||||
}
|
||||
}
|
||||
MaxVectorSize = SuperwordUseVSX ? 16 : 8;
|
||||
if (FLAG_IS_DEFAULT(AlignVector)) {
|
||||
FLAG_SET_ERGO(AlignVector, false);
|
||||
}
|
||||
|
||||
if (PowerArchitecturePPC64 >= 9) {
|
||||
if (FLAG_IS_DEFAULT(UseCountTrailingZerosInstructionsPPC64)) {
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Copyright (c) 2024, Red Hat, Inc. All rights reserved.
|
||||
* Copyright (c) 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2024, 2025, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -77,7 +77,7 @@ public class TestCastX2NotProcessedIGVN {
|
||||
@Test
|
||||
@IR(counts = {IRNode.LOAD_VECTOR_I, "> 1"},
|
||||
applyIfOr = {"UseCompactObjectHeaders", "false", "AlignVector", "false"},
|
||||
applyIfPlatformOr = {"x64", "true", "aarch64", "true"})
|
||||
applyIfPlatformOr = {"x64", "true", "aarch64", "true", "ppc", "true"})
|
||||
public static int test2(int stop, int[] array) {
|
||||
int v = 0;
|
||||
stop = Math.min(stop, Integer.MAX_VALUE / 4);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user