All of lore.kernel.org
 help / color / mirror / Atom feed
* Work Queue for btrfs compression writes
@ 2014-07-30  3:54 ` Nick Krause
  0 siblings, 0 replies; 17+ messages in thread
From: Nick Krause @ 2014-07-30  3:54 UTC (permalink / raw)
  To: linux-kernel, linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

Hey Guys ,
I am new to   reading  and writing  kernel code.I got interested in
writing code for btrfs as it seems to
need more work then other file systems and this seems other then
drivers, a good use of time on my part.
I interested in helping improving the compression of btrfs by using  a
set of threads using work queues like XFS
or reads and keeping the page cache after reading compressed blocks as
these seem to be a great way to improve
on  compression performance mostly with large partitions of compressed
data. I am not asking you to write the code
for me but as I am new a little guidance and help would be greatly
appreciated as this seems like too much work for just a newbie.
Thanks A lot,
Nick

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Work Queue for btrfs compression writes
@ 2014-07-30  3:54 ` Nick Krause
  0 siblings, 0 replies; 17+ messages in thread
From: Nick Krause @ 2014-07-30  3:54 UTC (permalink / raw)
  To: linux-kernel, linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

Hey Guys ,
I am new to   reading  and writing  kernel code.I got interested in
writing code for btrfs as it seems to
need more work then other file systems and this seems other then
drivers, a good use of time on my part.
I interested in helping improving the compression of btrfs by using  a
set of threads using work queues like XFS
or reads and keeping the page cache after reading compressed blocks as
these seem to be a great way to improve
on  compression performance mostly with large partitions of compressed
data. I am not asking you to write the code
for me but as I am new a little guidance and help would be greatly
appreciated as this seems like too much work for just a newbie.
Thanks A lot,
Nick

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
       [not found] ` <CA+WRLO9HdX=PDktUci2bQNM0Wp6DsjxiiWBNAxOtvitPqWDCAg@mail.gmail.com>
@ 2014-07-30  4:54   ` Nick Krause
  2014-07-31  3:14     ` Austin S Hemmelgarn
  0 siblings, 1 reply; 17+ messages in thread
From: Nick Krause @ 2014-07-30  4:54 UTC (permalink / raw)
  To: Gareth Pye; +Cc: linux-kernel

On Wed, Jul 30, 2014 at 12:37 AM, Gareth Pye <gareth@cerberos.id.au> wrote:
> You've been replied to politely, now listen and do or shut up.
>
>
> On Wed, Jul 30, 2014 at 1:54 PM, Nick Krause <xerofoify@gmail.com> wrote:
>>
>> Hey Guys ,
>> I am new to   reading  and writing  kernel code.I got interested in
>> writing code for btrfs as it seems to
>> need more work then other file systems and this seems other then
>> drivers, a good use of time on my part.
>> I interested in helping improving the compression of btrfs by using  a
>> set of threads using work queues like XFS
>> or reads and keeping the page cache after reading compressed blocks as
>> these seem to be a great way to improve
>> on  compression performance mostly with large partitions of compressed
>> data. I am not asking you to write the code
>> for me but as I am new a little guidance and help would be greatly
>> appreciated as this seems like too much work for just a newbie.
>> Thanks A lot,
>> Nick
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
>
>
>
> --
> Gareth Pye
> Level 2 Judge, Melbourne, Australia
> Australian MTG Forum: mtgau.com
> gareth@cerberos.id.au - www.rockpaperdynamite.wordpress.com
> "Dear God, I would like to file a bug report"

Gareth
I am asking for advice on not writing the code but can someone please
test this for me as I don't have many hard drives lying around. In addition
I am new to btrfs , so I would like to known if this is a good idea or should
I just drop it?
Nick

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30  3:54 ` Nick Krause
@ 2014-07-30  9:38   ` Hugo Mills
  -1 siblings, 0 replies; 17+ messages in thread
From: Hugo Mills @ 2014-07-30  9:38 UTC (permalink / raw)
  To: Nick Krause
  Cc: linux-kernel, linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

[-- Attachment #1: Type: text/plain, Size: 2432 bytes --]

On Tue, Jul 29, 2014 at 11:54:20PM -0400, Nick Krause wrote:
> Hey Guys ,
> I am new to   reading  and writing  kernel code.I got interested in
> writing code for btrfs as it seems to
> need more work then other file systems and this seems other then
> drivers, a good use of time on my part.
> I interested in helping improving the compression of btrfs by using  a
> set of threads using work queues like XFS
> or reads and keeping the page cache after reading compressed blocks as
> these seem to be a great way to improve
> on  compression performance mostly with large partitions of compressed
> data. I am not asking you to write the code
> for me but as I am new a little guidance and help would be greatly
> appreciated as this seems like too much work for just a newbie.

 * Documentation/workqueue.txt (in general, grep in Documentation
   usually throws up something useful)

 * grep -r alloc_workqueue fs/ shows a lot of uses (including in
   btrfs), so it should be fairly easy to see how to create and manage
   a workqueue.

   I suspect that this may be a medium-sized project, rather than a
small one. My gut feeling (based on limited experience) is that the
fallocate extensions project would be considerably simpler.

   I also noticed from the public reply to the private mail (don't do
this without getting permission from the other person) that you posted
to LKML in this thread (don't switch mailing lists mid-thread) that
you anticipated having problems testing with limited disks -- what you
will find is that testing new kernel code is something that you don't
do on your main development OS installation. Instead, you will need
either a scratch machine that you can easily update, or one or more
virtual machines. qemu/kvm is good for this, because it has a mode
that bypasses the BIOS and bootloader emulation, and just directly
runs a kernel from a file on the host machine. This is fast. You can
pass large sparse files to the VM to act as scratch disks, plus keep
another smaller file for the guest OS (and a copy of it so that you
can throw one away and make another one quickly and easily).

   Hugo.

-- 
=== Hugo Mills: hugo@... carfax.org.uk | darksatanic.net | lug.org.uk ===
  PGP key: 65E74AC0 from wwwkeys.eu.pgp.net or http://www.carfax.org.uk
  --- You've read the project plan.  Forget that. We're going to Do ---  
                      Stuff and Have Fun doing it.                       

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 811 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
@ 2014-07-30  9:38   ` Hugo Mills
  0 siblings, 0 replies; 17+ messages in thread
From: Hugo Mills @ 2014-07-30  9:38 UTC (permalink / raw)
  To: Nick Krause
  Cc: linux-kernel, linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

[-- Attachment #1: Type: text/plain, Size: 2432 bytes --]

On Tue, Jul 29, 2014 at 11:54:20PM -0400, Nick Krause wrote:
> Hey Guys ,
> I am new to   reading  and writing  kernel code.I got interested in
> writing code for btrfs as it seems to
> need more work then other file systems and this seems other then
> drivers, a good use of time on my part.
> I interested in helping improving the compression of btrfs by using  a
> set of threads using work queues like XFS
> or reads and keeping the page cache after reading compressed blocks as
> these seem to be a great way to improve
> on  compression performance mostly with large partitions of compressed
> data. I am not asking you to write the code
> for me but as I am new a little guidance and help would be greatly
> appreciated as this seems like too much work for just a newbie.

 * Documentation/workqueue.txt (in general, grep in Documentation
   usually throws up something useful)

 * grep -r alloc_workqueue fs/ shows a lot of uses (including in
   btrfs), so it should be fairly easy to see how to create and manage
   a workqueue.

   I suspect that this may be a medium-sized project, rather than a
small one. My gut feeling (based on limited experience) is that the
fallocate extensions project would be considerably simpler.

   I also noticed from the public reply to the private mail (don't do
this without getting permission from the other person) that you posted
to LKML in this thread (don't switch mailing lists mid-thread) that
you anticipated having problems testing with limited disks -- what you
will find is that testing new kernel code is something that you don't
do on your main development OS installation. Instead, you will need
either a scratch machine that you can easily update, or one or more
virtual machines. qemu/kvm is good for this, because it has a mode
that bypasses the BIOS and bootloader emulation, and just directly
runs a kernel from a file on the host machine. This is fast. You can
pass large sparse files to the VM to act as scratch disks, plus keep
another smaller file for the guest OS (and a copy of it so that you
can throw one away and make another one quickly and easily).

   Hugo.

-- 
=== Hugo Mills: hugo@... carfax.org.uk | darksatanic.net | lug.org.uk ===
  PGP key: 65E74AC0 from wwwkeys.eu.pgp.net or http://www.carfax.org.uk
  --- You've read the project plan.  Forget that. We're going to Do ---  
                      Stuff and Have Fun doing it.                       

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 811 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30  9:38   ` Hugo Mills
@ 2014-07-30 14:13     ` Theodore Ts'o
  -1 siblings, 0 replies; 17+ messages in thread
From: Theodore Ts'o @ 2014-07-30 14:13 UTC (permalink / raw)
  To: Hugo Mills, Nick Krause, linux-kernel,
	linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

On Wed, Jul 30, 2014 at 10:38:21AM +0100, Hugo Mills wrote:
> qemu/kvm is good for this, because it has a mode
> that bypasses the BIOS and bootloader emulation, and just directly
> runs a kernel from a file on the host machine. This is fast. You can
> pass large sparse files to the VM to act as scratch disks, plus keep
> another smaller file for the guest OS (and a copy of it so that you
> can throw one away and make another one quickly and easily).

Nick,

The xfstests-bld/kvm-xfstests git tree I pointed out to you has an
example of a test infrastructure which does this for ext4.  It's been
on my todo list to support other file systems, and I have some plans
for how to do thi, but it's been low on my priority list.  If someone
in the btrfs development community is interested in working with me on
this, they should contact me.

Or the btrfs developers can create their own automated systems which
then gets promulgated, but either way, it's something that I strongly
recommend.  The set of test configs that ext4 developers would run
significantly increased after I cleaned up my test scripts and made it
something that other people could use, and it means that I can ask
people who are implementing new features that they run a complete
regression test run, with many different file systems features enabled
and disabled, so they find the problems before they propose a patch
for merging.

Cheers,

					- Ted



^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
@ 2014-07-30 14:13     ` Theodore Ts'o
  0 siblings, 0 replies; 17+ messages in thread
From: Theodore Ts'o @ 2014-07-30 14:13 UTC (permalink / raw)
  To: Hugo Mills, Nick Krause, linux-kernel,
	linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

On Wed, Jul 30, 2014 at 10:38:21AM +0100, Hugo Mills wrote:
> qemu/kvm is good for this, because it has a mode
> that bypasses the BIOS and bootloader emulation, and just directly
> runs a kernel from a file on the host machine. This is fast. You can
> pass large sparse files to the VM to act as scratch disks, plus keep
> another smaller file for the guest OS (and a copy of it so that you
> can throw one away and make another one quickly and easily).

Nick,

The xfstests-bld/kvm-xfstests git tree I pointed out to you has an
example of a test infrastructure which does this for ext4.  It's been
on my todo list to support other file systems, and I have some plans
for how to do thi, but it's been low on my priority list.  If someone
in the btrfs development community is interested in working with me on
this, they should contact me.

Or the btrfs developers can create their own automated systems which
then gets promulgated, but either way, it's something that I strongly
recommend.  The set of test configs that ext4 developers would run
significantly increased after I cleaned up my test scripts and made it
something that other people could use, and it means that I can ask
people who are implementing new features that they run a complete
regression test run, with many different file systems features enabled
and disabled, so they find the problems before they propose a patch
for merging.

Cheers,

					- Ted



^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30 14:13     ` Theodore Ts'o
  (?)
@ 2014-07-30 14:36     ` Peter Hurley
  2014-07-31 11:35       ` Theodore Ts'o
  -1 siblings, 1 reply; 17+ messages in thread
From: Peter Hurley @ 2014-07-30 14:36 UTC (permalink / raw)
  To: Theodore Ts'o; +Cc: Hugo Mills, Nick Krause, linux-kernel, linux-btrfs

On 07/30/2014 10:13 AM, Theodore Ts'o wrote:
> On Wed, Jul 30, 2014 at 10:38:21AM +0100, Hugo Mills wrote:
>> qemu/kvm is good for this, because it has a mode
>> that bypasses the BIOS and bootloader emulation, and just directly
>> runs a kernel from a file on the host machine. This is fast. You can
>> pass large sparse files to the VM to act as scratch disks, plus keep
>> another smaller file for the guest OS (and a copy of it so that you
>> can throw one away and make another one quickly and easily).
> 
> Nick,
> 
> The xfstests-bld/kvm-xfstests git tree I pointed out to you has an
> example of a test infrastructure which does this for ext4.  It's been
> on my todo list to support other file systems, and I have some plans
> for how to do thi, but it's been low on my priority list.  If someone
> in the btrfs development community is interested in working with me on
> this, they should contact me.

Ted,

Where is that git tree? I've been planning to set up a unit test and
regression suite for tty/serial, and wouldn't mind cribbing the
infrastructure from someone's existing work.

Regards,
Peter Hurley


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30  9:38   ` Hugo Mills
  (?)
  (?)
@ 2014-07-30 15:36   ` ashford
  2014-07-30 17:19     ` Nick Krause
  -1 siblings, 1 reply; 17+ messages in thread
From: ashford @ 2014-07-30 15:36 UTC (permalink / raw)
  To: Hugo Mills, Nick Krause,
	linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

> On Tue, Jul 29, 2014 at 11:54:20PM -0400, Nick Krause wrote:
>> Hey Guys ,
>> I interested in helping improving the compression of btrfs by using  a
>> set of threads using work queues like XFS
>> or reads and keeping the page cache after reading compressed blocks as
>> these seem to be a great way to improve
>> on  compression performance mostly with large partitions of compressed
>> data.
>
>    I suspect that this may be a medium-sized project, rather than a
> small one. My gut feeling (based on limited experience) is that the
> fallocate extensions project would be considerably simpler.
>
>    Hugo.

I may be in error, but I believe this may be a bit more complex than just
routing all reads and writes through a decompression/compression work
queue.  On the write side, it might be better to compress the synchronous
requests in-line, instead of going through a work queue.  Similarly, on
the read side, it might be better to decompress user-requested data (and
metadata) in-line, and have any system-generated read-ahead data be
decompressed in a work queue (the same work queue?).

I believe that one of the significant concerns of the above is that the
compression and decompression routines will have to be verified to be
thread-safe.  If BTRFS is using the same compression/decompression
routines that other file-systems use, then the core code is almost
certainly thread-safe.  Any BTRFS wrapper code will have to be verified.

Peter Ashford


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30 15:36   ` ashford
@ 2014-07-30 17:19     ` Nick Krause
  2014-07-30 18:31       ` ashford
  0 siblings, 1 reply; 17+ messages in thread
From: Nick Krause @ 2014-07-30 17:19 UTC (permalink / raw)
  To: ashford; +Cc: Hugo Mills, linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

On Wed, Jul 30, 2014 at 11:36 AM,  <ashford@whisperpc.com> wrote:
>> On Tue, Jul 29, 2014 at 11:54:20PM -0400, Nick Krause wrote:
>>> Hey Guys ,
>>> I interested in helping improving the compression of btrfs by using  a
>>> set of threads using work queues like XFS
>>> or reads and keeping the page cache after reading compressed blocks as
>>> these seem to be a great way to improve
>>> on  compression performance mostly with large partitions of compressed
>>> data.
>>
>>    I suspect that this may be a medium-sized project, rather than a
>> small one. My gut feeling (based on limited experience) is that the
>> fallocate extensions project would be considerably simpler.
>>
>>    Hugo.
>
> I may be in error, but I believe this may be a bit more complex than just
> routing all reads and writes through a decompression/compression work
> queue.  On the write side, it might be better to compress the synchronous
> requests in-line, instead of going through a work queue.  Similarly, on
> the read side, it might be better to decompress user-requested data (and
> metadata) in-line, and have any system-generated read-ahead data be
> decompressed in a work queue (the same work queue?).
>
> I believe that one of the significant concerns of the above is that the
> compression and decompression routines will have to be verified to be
> thread-safe.  If BTRFS is using the same compression/decompression
> routines that other file-systems use, then the core code is almost
> certainly thread-safe.  Any BTRFS wrapper code will have to be verified.
>
> Peter Ashford
>


Peter ,
Seems that the code from my reading is that the code is using the same
compression
routines as the other file systems. You seem to have some ideas on how
to write this
or improve it at least, if you want you can send me a list of ideas
that you have.
Cheers Nick

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30 17:19     ` Nick Krause
@ 2014-07-30 18:31       ` ashford
  2014-07-30 19:40         ` Nick Krause
  0 siblings, 1 reply; 17+ messages in thread
From: ashford @ 2014-07-30 18:31 UTC (permalink / raw)
  To: Nick Krause
  Cc: ashford, Hugo Mills, linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

Nick,

> On Wed, Jul 30, 2014 at 11:36 AM,  <ashford@whisperpc.com> wrote:
>>> On Tue, Jul 29, 2014 at 11:54:20PM -0400, Nick Krause wrote:
>>>> Hey Guys ,
>>>> I interested in helping improving the compression of btrfs by using  a
>>>> set of threads using work queues like XFS
>>>> or reads and keeping the page cache after reading compressed blocks as
>>>> these seem to be a great way to improve
>>>> on  compression performance mostly with large partitions of compressed
>>>> data.
>>>
>>>    I suspect that this may be a medium-sized project, rather than a
>>> small one. My gut feeling (based on limited experience) is that the
>>> fallocate extensions project would be considerably simpler.
>>>
>>>    Hugo.
>>
>> I may be in error, but I believe this may be a bit more complex than
>> just
>> routing all reads and writes through a decompression/compression work
>> queue.  On the write side, it might be better to compress the
>> synchronous
>> requests in-line, instead of going through a work queue.  Similarly, on
>> the read side, it might be better to decompress user-requested data (and
>> metadata) in-line, and have any system-generated read-ahead data be
>> decompressed in a work queue (the same work queue?).
>>
>> I believe that one of the significant concerns of the above is that the
>> compression and decompression routines will have to be verified to be
>> thread-safe.  If BTRFS is using the same compression/decompression
>> routines that other file-systems use, then the core code is almost
>> certainly thread-safe.  Any BTRFS wrapper code will have to be verified.
>
> Seems that the code from my reading is that the code is using the same
> compression
> routines as the other file systems. You seem to have some ideas on how
> to write this
> or improve it at least, if you want you can send me a list of ideas
> that you have.

Sorry.  It's been almost 20 years since I did any serious kernel work, and
that kernel (not Linux) didn't even know how to page.  There have been too
many changes since then for me to be able to climb back in with under a
year of hard work.  Even then, I would select a simpler task than this to
start on.

What I DO remember is that the layer you're working on is fairly low in
the stack.  The application, kernel and file-system have already had a
chance to prioritize the I/O requests as synchronous or asynchronous. 
That prioritization must be properly handled, or the overall stability of
BTRFS will be at risk.

Good luck.

Peter Ashford


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30 18:31       ` ashford
@ 2014-07-30 19:40         ` Nick Krause
  0 siblings, 0 replies; 17+ messages in thread
From: Nick Krause @ 2014-07-30 19:40 UTC (permalink / raw)
  To: ashford; +Cc: Hugo Mills, linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

On Wed, Jul 30, 2014 at 2:31 PM,  <ashford@whisperpc.com> wrote:
> Nick,
>
>> On Wed, Jul 30, 2014 at 11:36 AM,  <ashford@whisperpc.com> wrote:
>>>> On Tue, Jul 29, 2014 at 11:54:20PM -0400, Nick Krause wrote:
>>>>> Hey Guys ,
>>>>> I interested in helping improving the compression of btrfs by using  a
>>>>> set of threads using work queues like XFS
>>>>> or reads and keeping the page cache after reading compressed blocks as
>>>>> these seem to be a great way to improve
>>>>> on  compression performance mostly with large partitions of compressed
>>>>> data.
>>>>
>>>>    I suspect that this may be a medium-sized project, rather than a
>>>> small one. My gut feeling (based on limited experience) is that the
>>>> fallocate extensions project would be considerably simpler.
>>>>
>>>>    Hugo.
>>>
>>> I may be in error, but I believe this may be a bit more complex than
>>> just
>>> routing all reads and writes through a decompression/compression work
>>> queue.  On the write side, it might be better to compress the
>>> synchronous
>>> requests in-line, instead of going through a work queue.  Similarly, on
>>> the read side, it might be better to decompress user-requested data (and
>>> metadata) in-line, and have any system-generated read-ahead data be
>>> decompressed in a work queue (the same work queue?).
>>>
>>> I believe that one of the significant concerns of the above is that the
>>> compression and decompression routines will have to be verified to be
>>> thread-safe.  If BTRFS is using the same compression/decompression
>>> routines that other file-systems use, then the core code is almost
>>> certainly thread-safe.  Any BTRFS wrapper code will have to be verified.
>>
>> Seems that the code from my reading is that the code is using the same
>> compression
>> routines as the other file systems. You seem to have some ideas on how
>> to write this
>> or improve it at least, if you want you can send me a list of ideas
>> that you have.
>
> Sorry.  It's been almost 20 years since I did any serious kernel work, and
> that kernel (not Linux) didn't even know how to page.  There have been too
> many changes since then for me to be able to climb back in with under a
> year of hard work.  Even then, I would select a simpler task than this to
> start on.
>
> What I DO remember is that the layer you're working on is fairly low in
> the stack.  The application, kernel and file-system have already had a
> chance to prioritize the I/O requests as synchronous or asynchronous.
> That prioritization must be properly handled, or the overall stability of
> BTRFS will be at risk.
>
> Good luck.
>
> Peter Ashford
>
Peter,
Seems like a challenge and I like challenges.
Regards Nick

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30  4:54   ` Nick Krause
@ 2014-07-31  3:14     ` Austin S Hemmelgarn
  2014-07-31  3:32       ` Nick Krause
  0 siblings, 1 reply; 17+ messages in thread
From: Austin S Hemmelgarn @ 2014-07-31  3:14 UTC (permalink / raw)
  To: Nick Krause; +Cc: linux-kernel

[-- Attachment #1: Type: text/plain, Size: 2357 bytes --]

On 07/30/2014 12:54 AM, Nick Krause wrote:
> On Wed, Jul 30, 2014 at 12:37 AM, Gareth Pye <gareth@cerberos.id.au> wrote:
>> You've been replied to politely, now listen and do or shut up.
>>
>>
>> On Wed, Jul 30, 2014 at 1:54 PM, Nick Krause <xerofoify@gmail.com> wrote:
>>>
>>> Hey Guys ,
>>> I am new to   reading  and writing  kernel code.I got interested in
>>> writing code for btrfs as it seems to
>>> need more work then other file systems and this seems other then
>>> drivers, a good use of time on my part.
>>> I interested in helping improving the compression of btrfs by using  a
>>> set of threads using work queues like XFS
>>> or reads and keeping the page cache after reading compressed blocks as
>>> these seem to be a great way to improve
>>> on  compression performance mostly with large partitions of compressed
>>> data. I am not asking you to write the code
>>> for me but as I am new a little guidance and help would be greatly
>>> appreciated as this seems like too much work for just a newbie.
>>> Thanks A lot,
>>> Nick
>>> --
>>> To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
>>> the body of a message to majordomo@vger.kernel.org
>>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>
>>
>>
>>
>> --
>> Gareth Pye
>> Level 2 Judge, Melbourne, Australia
>> Australian MTG Forum: mtgau.com
>> gareth@cerberos.id.au - www.rockpaperdynamite.wordpress.com
>> "Dear God, I would like to file a bug report"
> 
> Gareth
> I am asking for advice on not writing the code but can someone please
> test this for me as I don't have many hard drives lying around. In addition
> I am new to btrfs , so I would like to known if this is a good idea or should
> I just drop it?
> Nick
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
> 
I would look into using usermode linux (linux built with ARCH=um) for at
least the initial debugging, it is marginally more efficient than
virtualization, doesn't need root privileges, and allows you to run the
kernel under GDB without needing separate hardware with a serial console
or PS/2 keyboard.


[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 2967 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-31  3:14     ` Austin S Hemmelgarn
@ 2014-07-31  3:32       ` Nick Krause
  0 siblings, 0 replies; 17+ messages in thread
From: Nick Krause @ 2014-07-31  3:32 UTC (permalink / raw)
  To: Austin S Hemmelgarn; +Cc: linux-kernel

On Wed, Jul 30, 2014 at 11:14 PM, Austin S Hemmelgarn
<ahferroin7@gmail.com> wrote:
> On 07/30/2014 12:54 AM, Nick Krause wrote:
>> On Wed, Jul 30, 2014 at 12:37 AM, Gareth Pye <gareth@cerberos.id.au> wrote:
>>> You've been replied to politely, now listen and do or shut up.
>>>
>>>
>>> On Wed, Jul 30, 2014 at 1:54 PM, Nick Krause <xerofoify@gmail.com> wrote:
>>>>
>>>> Hey Guys ,
>>>> I am new to   reading  and writing  kernel code.I got interested in
>>>> writing code for btrfs as it seems to
>>>> need more work then other file systems and this seems other then
>>>> drivers, a good use of time on my part.
>>>> I interested in helping improving the compression of btrfs by using  a
>>>> set of threads using work queues like XFS
>>>> or reads and keeping the page cache after reading compressed blocks as
>>>> these seem to be a great way to improve
>>>> on  compression performance mostly with large partitions of compressed
>>>> data. I am not asking you to write the code
>>>> for me but as I am new a little guidance and help would be greatly
>>>> appreciated as this seems like too much work for just a newbie.
>>>> Thanks A lot,
>>>> Nick
>>>> --
>>>> To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
>>>> the body of a message to majordomo@vger.kernel.org
>>>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>>
>>>
>>>
>>>
>>> --
>>> Gareth Pye
>>> Level 2 Judge, Melbourne, Australia
>>> Australian MTG Forum: mtgau.com
>>> gareth@cerberos.id.au - www.rockpaperdynamite.wordpress.com
>>> "Dear God, I would like to file a bug report"
>>
>> Gareth
>> I am asking for advice on not writing the code but can someone please
>> test this for me as I don't have many hard drives lying around. In addition
>> I am new to btrfs , so I would like to known if this is a good idea or should
>> I just drop it?
>> Nick
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>> Please read the FAQ at  http://www.tux.org/lkml/
>>
> I would look into using usermode linux (linux built with ARCH=um) for at
> least the initial debugging, it is marginally more efficient than
> virtualization, doesn't need root privileges, and allows you to run the
> kernel under GDB without needing separate hardware with a serial console
> or PS/2 keyboard.
>

That's what I am thinking the only issue is I am going to start my
reading on work queues first.
Regards Nick

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30 14:36     ` Peter Hurley
@ 2014-07-31 11:35       ` Theodore Ts'o
  0 siblings, 0 replies; 17+ messages in thread
From: Theodore Ts'o @ 2014-07-31 11:35 UTC (permalink / raw)
  To: Peter Hurley; +Cc: Hugo Mills, Nick Krause, linux-kernel, linux-btrfs

On Wed, Jul 30, 2014 at 10:36:57AM -0400, Peter Hurley wrote:
> 
> Where is that git tree? I've been planning to set up a unit test and
> regression suite for tty/serial, and wouldn't mind cribbing the
> infrastructure from someone's existing work.

https://git.kernel.org/cgit/fs/ext2/xfstests-bld.git/

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
  2014-07-30  3:54 ` Nick Krause
@ 2014-08-04 13:29   ` Chris Mason
  -1 siblings, 0 replies; 17+ messages in thread
From: Chris Mason @ 2014-08-04 13:29 UTC (permalink / raw)
  To: Nick Krause, linux-kernel,
	linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

On 07/29/2014 11:54 PM, Nick Krause wrote:
> Hey Guys ,
> I am new to   reading  and writing  kernel code.I got interested in
> writing code for btrfs as it seems to
> need more work then other file systems and this seems other then
> drivers, a good use of time on my part.
> I interested in helping improving the compression of btrfs by using  a
> set of threads using work queues like XFS
> or reads and keeping the page cache after reading compressed blocks as
> these seem to be a great way to improve
> on  compression performance mostly with large partitions of compressed
> data. I am not asking you to write the code
> for me but as I am new a little guidance and help would be greatly
> appreciated as this seems like too much work for just a newbie.

[ Back from vacation ]

Reading through the thread, I don't see anyone mentioning that btrfs
already funnels most compression through helper threads in the kernel
workqueues.

There is also an ordering component that submits the compressed bios to
disk (for writes) in the same order they were created.  This lets us
scatter compression across N cpus, but not introduce seeks if they make
progress at different rates.

-chris


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: Work Queue for btrfs compression writes
@ 2014-08-04 13:29   ` Chris Mason
  0 siblings, 0 replies; 17+ messages in thread
From: Chris Mason @ 2014-08-04 13:29 UTC (permalink / raw)
  To: Nick Krause, linux-kernel,
	linux-btrfs@vger.kernel.org SYSTEM list:BTRFS FILE

On 07/29/2014 11:54 PM, Nick Krause wrote:
> Hey Guys ,
> I am new to   reading  and writing  kernel code.I got interested in
> writing code for btrfs as it seems to
> need more work then other file systems and this seems other then
> drivers, a good use of time on my part.
> I interested in helping improving the compression of btrfs by using  a
> set of threads using work queues like XFS
> or reads and keeping the page cache after reading compressed blocks as
> these seem to be a great way to improve
> on  compression performance mostly with large partitions of compressed
> data. I am not asking you to write the code
> for me but as I am new a little guidance and help would be greatly
> appreciated as this seems like too much work for just a newbie.

[ Back from vacation ]

Reading through the thread, I don't see anyone mentioning that btrfs
already funnels most compression through helper threads in the kernel
workqueues.

There is also an ordering component that submits the compressed bios to
disk (for writes) in the same order they were created.  This lets us
scatter compression across N cpus, but not introduce seeks if they make
progress at different rates.

-chris


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2014-08-04 13:29 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-30  3:54 Work Queue for btrfs compression writes Nick Krause
2014-07-30  3:54 ` Nick Krause
     [not found] ` <CA+WRLO9HdX=PDktUci2bQNM0Wp6DsjxiiWBNAxOtvitPqWDCAg@mail.gmail.com>
2014-07-30  4:54   ` Nick Krause
2014-07-31  3:14     ` Austin S Hemmelgarn
2014-07-31  3:32       ` Nick Krause
2014-07-30  9:38 ` Hugo Mills
2014-07-30  9:38   ` Hugo Mills
2014-07-30 14:13   ` Theodore Ts'o
2014-07-30 14:13     ` Theodore Ts'o
2014-07-30 14:36     ` Peter Hurley
2014-07-31 11:35       ` Theodore Ts'o
2014-07-30 15:36   ` ashford
2014-07-30 17:19     ` Nick Krause
2014-07-30 18:31       ` ashford
2014-07-30 19:40         ` Nick Krause
2014-08-04 13:29 ` Chris Mason
2014-08-04 13:29   ` Chris Mason

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.