lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20141215034822.GH17575@thunk.org>
Date:	Sun, 14 Dec 2014 22:48:22 -0500
From:	Theodore Ts'o <tytso@....edu>
To:	"Darrick J. Wong" <darrick.wong@...cle.com>
Cc:	linux-ext4@...r.kernel.org
Subject: Re: [PATCH 13/47] libext2fs: add a way to check the theoretical
 maximum extent tree depth

On Sat, Dec 13, 2014 at 07:11:11PM -0800, Darrick J. Wong wrote:
> > But if you look at the above code, there is nothing which is inode or
> > handle specific.  The value is only dependent on fs->blocksize.  But
> > to calculate this value the function calls ul_log2 three times, which
> > is implemented using a looping construct.  So we will be recalculating
> > what is effectively a constant value every single inode in an ext4
> > file system, which seems very unfortunate.
> 
> How about I save the last fs->blocksize and the last result, and return the
> cached last result if fs->blocksize == lastblocksize?

That sounds like a plan.  BTW, it looks like I had accidentally
included this in the next branch, but adding a cache won't disturb the
API, so that's fine.

						- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ