gpt4 book ai didi

java - Control-Break 在使用 cygwin 的 java 中不起作用

转载 作者:行者123 更新时间:2023-12-01 15:41:11 26 4
gpt4 key购买 nike

我希望这是问这个问题的正确地方,我正在运行适用于 Windows 64 位的 JAVA 7。我使用 cygwin 作为终端。每次我尝试停止正在进行的程序时,我都会按 control-break,通常这会将作业发送到后台,但我却得到以下线程转储。

Full thread dump Java HotSpot(TM) 64-Bit Server VM (21.0-b17 mixed mode):

"Service Thread" daemon prio=6 tid=0x0000000007504800 nid=0x7c5c runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"C2 CompilerThread1" daemon prio=10 tid=0x00000000074ff800 nid=0xd66c waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"C2 CompilerThread0" daemon prio=10 tid=0x00000000074f9000 nid=0x5ce8 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"Attach Listener" daemon prio=10 tid=0x00000000074f8000 nid=0x45ec runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"Signal Dispatcher" daemon prio=10 tid=0x00000000074f7000 nid=0x40a8 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"Finalizer" daemon prio=8 tid=0x0000000007472000 nid=0xd978 in Object.wait() [0x000000000809e000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x0000000788760dc0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:135)
- locked <0x0000000788760dc0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:151)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:177)

"Reference Handler" daemon prio=10 tid=0x0000000007469800 nid=0x6db8 in Object.wait() [0x0000000007d3e000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x0000000788760720> (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:503)
at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:133)
- locked <0x0000000788760720> (a java.lang.ref.Reference$Lock)

"main" prio=6 tid=0x000000000046b800 nid=0x1b68 runnable [0x00000000021ef000]
java.lang.Thread.State: RUNNABLE
at java.io.FileInputStream.readBytes(Native Method)
at java.io.FileInputStream.read(FileInputStream.java:242)
at java.io.BufferedInputStream.read1(BufferedInputStream.java:273)
at java.io.BufferedInputStream.read(BufferedInputStream.java:334)
- locked <0x0000000780413290> (a java.io.BufferedInputStream)
at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:283)
at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:325)
at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:177)
- locked <0x00000007804153a8> (a java.io.InputStreamReader)
at java.io.InputStreamReader.read(InputStreamReader.java:184)
at java.io.BufferedReader.fill(BufferedReader.java:154)
at java.io.BufferedReader.readLine(BufferedReader.java:317)
- locked <0x00000007804153a8> (a java.io.InputStreamReader)
at java.io.BufferedReader.readLine(BufferedReader.java:382)
at ReadSim.DoJAligner(ReadSim.java:280)
at ReadSim.getFullSimRead(ReadSim.java:91)
at ReadSim.main(ReadSim.java:44)

"VM Thread" prio=10 tid=0x0000000007460800 nid=0xe610 runnable

"GC task thread#0 (ParallelGC)" prio=6 tid=0x0000000001d4f000 nid=0x7bd4 runnable

"GC task thread#1 (ParallelGC)" prio=6 tid=0x0000000001d51000 nid=0xde18 runnable

"GC task thread#2 (ParallelGC)" prio=6 tid=0x0000000001d52800 nid=0xe1e8 runnable

"GC task thread#3 (ParallelGC)" prio=6 tid=0x0000000001d54000 nid=0x3490 runnable

"GC task thread#4 (ParallelGC)" prio=6 tid=0x0000000001d57800 nid=0x9ab0 runnable

"GC task thread#5 (ParallelGC)" prio=6 tid=0x0000000001d59000 nid=0x2dc0 runnable

"GC task thread#6 (ParallelGC)" prio=6 tid=0x0000000001d5a000 nid=0x9384 runnable

"GC task thread#7 (ParallelGC)" prio=6 tid=0x0000000001d5c800 nid=0x6f58 runnable

"VM Periodic Task Thread" prio=10 tid=0x0000000007517800 nid=0x10378 waiting on condition

JNI global references: 124

Heap
PSYoungGen total 135552K, used 40883K [0x00000007800b0000, 0x000000078b2b0000, 0x0000000800000000)
eden space 93568K, 4% used [0x00000007800b0000,0x000000078045b9a0,0x0000000785c10000)
from space 41984K, 88% used [0x0000000788760000,0x000000078aba1298,0x000000078b060000)
to space 44352K, 0% used [0x0000000785c10000,0x0000000785c10000,0x0000000788760000)
PSOldGen total 262080K, used 65712K [0x0000000680200000, 0x00000006901f0000, 0x00000007800b0000)
object space 262080K, 25% used [0x0000000680200000,0x000000068422c000,0x00000006901f0000)
PSPermGen total 21248K, used 3452K [0x000000067b000000, 0x000000067c4c0000, 0x0000000680200000)
object space 21248K, 16% used [0x000000067b000000,0x000000067b35f398,0x000000067c4c0000)

是否需要更改某些内容才能中断控制以将作业发送到后台。

非常感谢

最佳答案

如果您使用 CYGWIN=tty 运行或使用 xterm/rxvt,那么您将获得 Cygwin Control-Break 处理。如果您使用标准 Cygwin 或 CMD.EXE shell,那么您将获得 Java Control-Break 处理。

关于java - Control-Break 在使用 cygwin 的 java 中不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8014916/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com