Java问题:MAC OS中的内存和CPU使用率 [英] Java Issue: Memory and CPU usage in MAC OS

查看:738
本文介绍了Java问题:MAC OS中的内存和CPU使用率的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发用于MAC和Windows的javaFx应用程序,发现与Windows相比,该应用程序在MAC中使用的内存和CPU使用量非常大.

当我在Windows任务管理器中看到我的应用程序的活动时,它显示平均80MB内存和1-2%CPU的使用率,最大使用量为150MB和12-15%CPU.另一方面,在"MAC活动监视器"中,同一应用程序在启动时显示150MB和12-15%的CPU,并不断增加,超过1GB和90%CPU.

这是我在JavaFX应用程序中发现的一个非常奇怪的问题.

我什至针对简单的Java应用程序进行了测试,发现MAC和Windows中内存和CPU的行为类似.

为什么Java在MAC中使用更多的内存和CPU?有什么原因可以解决这个问题?

解决方案

由于安全漏洞(网守阻止了它或不起作用),Java启动了最初不支持的新版本时,我遇到了很多问题.

这是链接,如果有帮助的话,它可以提供更多支持,

旧帖子

我会说MAC的安全性功能会在一段时间内成为bug,因为它明确不更新任何插件,因此请检查JAVA的版本,以及插件是否工作正常. apple.com/kb/HT5559"rel =" nofollow noreferrer>发布较旧,我不知道可能需要哪些插件,但这是插件无法正常工作的主要问题.

也请检查此内容,如果您的系统也正在访问以前的JAVA 6,请删除以避免相同的引用 解决方案

I have seen many problems when the Java launched new version that was not supported initially, due to security flaw(gatekeeper was blocking it/or not working)

this is the link if that help make it supporting more,

Old Post

I will say the securty feature of MAC will become bug some time as it explicitly do not update any plugin, so check the version of JAVA, and plugins if working fine.. post as old I don't know which plugins may be required but this is main concern of problems where plugins don't work properly..

also check this, if your system are accessing JAVA 6 also which was previously there please remove to avoid the same refer Discussion on apple

JAVAFX and JDK must be installed in same directory structure Oracle MAC FAQ question 2

I am not regular user of MAC, as not much required,(once a while)..

But do keep track of the versions and updates. :)

I hope this will solve..

My main focus is of old java 6 is also there please remove the directories of the same..

这篇关于Java问题:MAC OS中的内存和CPU使用率的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
其他开发最新文章
热门教程
热门工具
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆