阻止gtk FileChooserDialog在目录中的所有文件上调用stat? [英] Preventing gtk FileChooserDialog calling stat on all files in the directory?

查看:181
本文介绍了阻止gtk FileChooserDialog在目录中的所有文件上调用stat?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

打开gtk FileChooserDialog对于包含许多文件的nfs目录来说是非常慢的。 strace显示了很多时间调用stat。目录中的每个文件大约有5个调用。我们如何关闭stat的电话,只显示一个没有修改时间的文件名列表?

Opening a gtk FileChooserDialog is painfully slow for nfs directories containing many files. strace shows a lot of time calling "stat". About 5 calls for each of the files in the directory. How can we switch off the calls to 'stat' and just show a list of filenames without the modification time?

我们正在使用Redhat Enterprise 4,x86_64,Linux 2.6.9-42.0.8.ELsmp和FileChooser来自:/usr/lib64/libgtk-x11-2.0.so.0.400.13。测试程序打开一个FileChooserDialog,需要10秒钟才能出现,而'ls'列出相同目录的大约25 ms。

We're using operating Redhat enterprise 4, x86_64, Linux 2.6.9-42.0.8.ELsmp and FileChooser is coming from: /usr/lib64/libgtk-x11-2.0.so.0.400.13 . A test program opens a FileChooserDialog and takes 10 seconds to appear, compared to about 25 ms for 'ls' to list the same directory.

我们的eclipse应用程序被这个文件选择器问题...

Our eclipse application being crippled by this file selector issue...

推荐答案

gtk +和gnome团队有一个错误报告与此问题相关,至少自2005年以来。gnome核心库中的最近和将来的更改将有望提高性能。
如果您在文件选择器菜单中有网络驱动器的任何书签,则可能会加剧此问题。

The gtk+ and gnome team have a bug report related to this issue, at least since 2005. Recent and future changes in the gnome core libraries will hopefully improve the performance. This issue can be aggravated if you have any bookmarks to network drives in the filechooser menu.

这篇关于阻止gtk FileChooserDialog在目录中的所有文件上调用stat?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆