• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:]


  • Subject: Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:]
  • From: Will Mason <email@hidden>
  • Date: Tue, 11 Apr 2006 09:56:17 -0700 (PDT)

Hi, Ondra,
 Yes, I see your point. However, everyone is going to be at least one layer removed from HFS+ calls, because there's no way to know in advance the type of file system in use. What if the directory is mounted over NFS? Then, if Carbon weren't abstracted off of that, it would fail to work at all. My guess is that the BSD calls are using kernel calls directly. It's just a guess, though; I'd be the first start eating my hat if I were wrong.

 I'll stop talking because I don't have time to test all the options and compare them.

 Cheers,
 Will

----- Original Message ----
From: Ondra Cada <email@hidden>
To: Will Mason <email@hidden>
Cc: email@hidden
Sent: Tuesday, April 11, 2006 11:22:56 AM
Subject: Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:]

Will,

On 11.4.2006, at 18:14, Will Mason wrote:

> There's also nothing wrong with using BSD calls: opendir(3), readdir
> (3), closedir(3). I'd be willing to bet (without empirical data)
> that those are actually the fastest of any of the proposed options.

In pure theory, Carbon should be faster (for it can exploit the fact
its calls are HFS-native, whilst posix has to be at least one level
higher).

In practice it might not be so--I haven't profiled them.

Anyway, myself, I would use the posix level only if truly needed for
portability, but YMMV.
---
Ondra Čada
OCSoftware:     email@hidden               http://www.ocs.cz
private         email@hidden             http://www.ocs.cz/oc





 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:]
      • From: Paul Forgey <email@hidden>
References: 
 >Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:] (From: Ondra Cada <email@hidden>)

  • Prev by Date: Re: Cocoa Dock Manager Functions
  • Next by Date: Re: Distributed Objects - setting protocol crashing GCC 4.0
  • Previous by thread: Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:]
  • Next by thread: Re: SLOW -[NSFileManager directoryContentsAtPath:matchingExtension:options:keepExtension:]
  • Index(es):
    • Date
    • Thread