Compare commits

...

2 Commits

Author SHA1 Message Date
Vitaly Provodin
7129b40bfe update exclude list on results of 21.0.5_b675.11 test runs 2024-11-05 13:08:20 +04:00
Maxim Kartashev
795da93714 JBR-7835 macOS: raised NOFILE ulimit breaks interaction with gdb
(cherry picked from commit 41fbb57244f074a7ad044570a8417683cceae41b)
(cherry picked from commit c6485560ad)
2024-11-02 13:22:38 +04:00
7 changed files with 66 additions and 22 deletions

View File

@@ -1987,25 +1987,11 @@ jint os::init_2(void) {
if (status != 0) {
log_info(os)("os::init_2 getrlimit failed: %s", os::strerror(errno));
} else {
rlim_t rlim_original = nbr_files.rlim_cur;
// On macOS according to setrlimit(2), OPEN_MAX must be used instead
// of RLIM_INFINITY, but testing on macOS >= 10.6, reveals that
// we can, in fact, use even RLIM_INFINITY, so try the max value
// that the system claims can be used first, same as other BSD OSes.
// However, some terminals (ksh) will internally use "int" type
// to store this value and since RLIM_INFINITY overflows an "int"
// we might end up with a negative value, so cap the system limit max
// at INT_MAX instead, just in case, for everyone.
nbr_files.rlim_cur = MIN(INT_MAX, nbr_files.rlim_max);
// Limit the number of open files because gdb would
// stat() the entire range of [0..rlim_max] and therefore effectively hang
// if that limit is sufficiently large like INT_MAX.
nbr_files.rlim_cur = MIN(OPEN_MAX, nbr_files.rlim_max);
status = setrlimit(RLIMIT_NOFILE, &nbr_files);
if (status != 0) {
// If that fails then try lowering the limit to either OPEN_MAX
// (which is safe) or the original limit, whichever was greater.
nbr_files.rlim_cur = MAX(OPEN_MAX, rlim_original);
status = setrlimit(RLIMIT_NOFILE, &nbr_files);
}
if (status != 0) {
log_info(os)("os::init_2 setrlimit failed: %s", os::strerror(errno));
}

View File

@@ -12,7 +12,7 @@ jb/applications/ctw/plugins_keymap_visualStudio_lib_keymap_visualStudio.java JBR
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_annotations_jvm_sources.java JBR-7360 linux-all,windows-all,macosx-all
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_compiler.java JBR-7374 generic-all
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_reflect_sources.java JBR-7360 linux-all,windows-all,macosx-all
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_runner.java JBR-7361 JBR-7361 linux-all,windows-all,macosx-all
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_runner.java JBR-7361 linux-all,windows-all,macosx-all
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_script_runtime_sources.java JBR-7360 linux-all,windows-all,macosx-all
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_stdlib_jdk7_sources.java JBR-7360 linux-all,windows-all,macosx-all
jb/applications/ctw/plugins_Kotlin_kotlinc_lib_kotlin_stdlib_jdk7.java JBR-7360 linux-all,windows-all,macosx-all

View File

@@ -0,0 +1,53 @@
/*
* Copyright 2024 JetBrains s.r.o.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
import jdk.test.lib.process.OutputAnalyzer;
import jdk.test.lib.process.ProcessTools;
/**
* @test
* @summary Verifies that the "soft" limit for the number of open files
* does not exceed 10240, an acceptable number that was
* the default on macOS for a long time.
* @library /test/lib
* @requires os.family == "mac"
* @run main OpenFilesLimit
*/
public class OpenFilesLimit {
private static final String ULIMIT_GET_CMD = "ulimit -n";
private static final int MACOS_DEFAULT_LIMIT = 10240;
public static void main(String[] args) throws Exception {
OutputAnalyzer oa = ProcessTools.executeCommand("sh", "-c", ULIMIT_GET_CMD)
.shouldHaveExitValue(0);
String s = oa.getStdout().strip();
System.out.println("ulimit returned :'" + s + "'");
int i = Integer.parseInt(s);
System.out.println("ulimit -n is " + i);
System.out.println("Expecting " + MACOS_DEFAULT_LIMIT + " or less");
if (i > MACOS_DEFAULT_LIMIT) {
throw new RuntimeException("ulimit -n returned " + i + " that is higher than expected " + MACOS_DEFAULT_LIMIT);
}
}
}

View File

@@ -3,7 +3,7 @@ java/awt/image/multiresolution/MultiresolutionIconTest.java JBR-7146 macosx-12.7
java/awt/image/multiresolution/MultiResolutionJOptionPaneIconTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
java/awt/Paint/PaintNativeOnUpdate.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
java/awt/Robot/HiDPIScreenCapture/ScreenCaptureTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
java/awt/Window/BackgroundIsNotUpdated/BackgroundIsNotUpdated.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
java/awt/Window/BackgroundIsNotUpdated/BackgroundIsNotUpdated.java JBR-7146 macosx-all
java/awt/Window/FullWindowContentTest/FullWindowContentRenderTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
java/awt/Window/FullWindowContentTest/FullWindowContentTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
java/awt/Window/MultiWindowApp/ChildAlwaysOnTopTest.java JBR-7312 macosx-all
@@ -11,6 +11,7 @@ java/awt/Window/ShapedAndTranslucentWindows/TranslucentChoice.java JBR-7146 maco
java/awt/Window/WindowTitleVisibleTest/WindowTitleVisibleTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
javax/swing/JButton/8151303/PressedIconTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
javax/swing/JComponent/7154030/bug7154030.java JBR-7713 macosx-aarch64
javax/swing/JDialog/Transparency/TransparencyTest.java JBR-7554 macosx-aarch64
javax/swing/JInternalFrame/8160248/JInternalFrameDraggingTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
javax/swing/JInternalFrame/DockIconRepaint/DockIconRepaint.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
javax/swing/JSpinner/4670051/DateFieldUnderCursorTest.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
@@ -23,6 +24,7 @@ javax/swing/plaf/nimbus/TestNimbusBGColor.java JBR-6464 macosx-12.7.4,macosx-12.
javax/swing/SwingGraphics/TranslateTest.java JBR-7510 macosx-aarch64
javax/swing/system/6799345/TestShutdown.java JBR-6881 macosx-12.7.4
jb/java/awt/CustomTitleBar/FrameNativeControlsTest.java JBR-6998 macosx-all
jb/java/awt/Window/MacNativeTransparentTitlebarWithCustomHeight.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6
sun/java2d/SunGraphics2D/DrawImageBilinear.java JBR-7146 macosx-12.7.4,macosx-12.7.5,macosx-12.7.6

View File

@@ -1,4 +1,3 @@
java/awt/Choice/ChoiceGeneratesItemEvents.java JBR-6284 linux-all
java/awt/Choice/ChoicePopupLocation/ChoicePopupLocation.java JBR-6857,JBR-5398 macosx-all,linux-all,windows-all
java/awt/Choice/ChoiceStaysOpenedOnTAB.java JBR-6284 linux-all
java/awt/Debug/X11Trace.java JBR-5442 linux-all
@@ -107,6 +106,7 @@ java/awt/Window/ShapedAndTranslucentWindows/SetShape.java 8253184,JBR-5510 windo
java/awt/Window/WindowTitleVisibleTest/WindowTitleVisibleTestLinuxGnome.java nobug linux-all
javax/swing/GraphicsConfigNotifier/TestMultiScreenGConfigNotify.java nobug linux-all
javax/swing/JButton/8151303/PressedIconTest.java JBR-5210,JBR-5510 windows-all,linux-all
javax/swing/JComboBox/6559152/bug6559152.java JBR-7783 linux-x64
javax/swing/JComponent/7154030/bug7154030.java JBR-5510 linux-all
javax/swing/JDialog/Transparency/TransparencyTest.java 8253184,JBR-5510 windows-all,linux-all
javax/swing/JEditorPane/TestBrowserBGColor.java JBR-5510 linux-all

View File

@@ -183,6 +183,7 @@ java/awt/Focus/CloseDialogActivateOwnerTest/CloseDialogActivateOwnerTest.java JB
java/awt/Focus/ConsumeNextKeyTypedOnModalShowTest/ConsumeNextKeyTypedOnModalShowTest.java 6986252,JBR-5178,JBR-6750 macosx-all,windows-all,linux-all
java/awt/Focus/ConsumedTabKeyTest.java JBR-5833 windows-all
java/awt/Focus/KeyEventForBadFocusOwnerTest/KeyEventForBadFocusOwnerTest.java JBR-5210 windows-all
java/awt/Focus/ModalDialogInFocusEventTest.java JBR-7818 linux-5.18.2-arch1-1
java/awt/Focus/ModalExcludedWindowClickTest/ModalExcludedWindowClickTest.java JBR-884 windows-x64,linux-all
java/awt/Focus/MouseClickRequestFocusRaceTest/MouseClickRequestFocusRaceTest.java 8194753 linux-all,macosx-all
java/awt/Focus/NoAutotransferToDisabledCompTest/NoAutotransferToDisabledCompTest.java 7152980,JBR-5210 macosx-all,windows-all
@@ -708,6 +709,7 @@ java/awt/PopupMenu/PopupMenuLocation.java 8238720,JBR-7035 windows-all,macosx-al
java/awt/GridBagLayout/GridBagLayoutIpadXYTest/GridBagLayoutIpadXYTest.java 8253184 windows-all
java/awt/GridLayout/ChangeGridSize/ChangeGridSize.java 8238720,8324782 windows-all,macosx-all
java/awt/GridLayout/ComponentPreferredSize/ComponentPreferredSize.java 8238720,8324782 windows-all,macosx-all
java/awt/GridLayout/LayoutExtraGaps/LayoutExtraGaps.java JBR-7847 linux-aarch64
java/awt/event/MouseEvent/FrameMouseEventAbsoluteCoordsTest/FrameMouseEventAbsoluteCoordsTest.java 8238720 windows-all
java/awt/wakefield/RobotKeyboard.java JBR-5653 linux-all
@@ -1446,7 +1448,7 @@ jb/java/awt/Focus/PopupIncomingFocusTest.java JBR-5799 windows-all
jb/java/awt/Focus/TitleBarClickTest.java JBR-6394 linux-5.18.2-arch1-1,windows-all
com/sun/java/swing/plaf/gtk/TestFileChooserSingleDirectorySelection.java JBR-6749 linux-x64
java/awt/Choice/ChoiceGeneratesItemEvents.java JBR-5510 linux-5.18.2-arch1-1
java/awt/Choice/ChoiceGeneratesItemEvents.java JBR-5510,JBR-6284 linux-5.18.2-arch1-1,linux-all
java/awt/Choice/ChoiceStaysOpenedOnTAB.java JBR-5510 linux-5.18.2-arch1-1
java/awt/Graphics/XORPaint.java#id2 JBR-5510 linux-5.18.2-arch1-1
java/awt/Robot/HiDPIScreenCapture/ScreenCaptureGtkTest.java JBR-5510 linux-5.18.2-arch1-1

View File

@@ -36,6 +36,7 @@ java/awt/GridLayout/ComponentPreferredSize/ComponentPreferredSize.java 8238720,8
java/awt/Graphics/LineClipTest.java JBR-5071 linux-all
java/awt/image/VolatileImage/DrawHugeImageTest.java JBR-5071,JBR-5359 linux-all,windows-aarch64
java/awt/KeyboardFocusmanager/TypeAhead/ButtonActionKeyTest/ButtonActionKeyTest.java JBR-7780 linux-aarch64
java/awt/LightweightComponent/LightweightEventTest/LightweightEventTest.java 8159252,JBR-5050,JBR-5071 windows-all,macosx-all,linux-all
java/awt/List/ItemEventTest/ItemEventTest.java JBR-5711,JBR-6234 linux-all,windows-all,macosx-all
java/awt/List/TriggerActionEventTest.java JBR-6234 windows-all